MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Extract parts of web pages

    Scheduled Pinned Locked Moved General Discussion
    13 Posts 3 Posters 2.5k Views 3 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • S Offline
      sdetweil @Egnos
      last edited by

      @Egnos what do you mean extract?

      you can get it’s html and then get some of that

      see the Cheerios lib

      https://cheerio.js.org/

      you can display the page using an iframe

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      1 Reply Last reply Reply Quote 0
      • karsten13K Offline
        karsten13 @Egnos
        last edited by

        @Egnos

        Maybe as an RSS Feed…or some other way…

        the newsfeed module has support for showing the articles in an iframe, but AFAIK you have to send the notitfications yourself (e.g. with another module), see official docs for the module.

        The problem (I think of all solutions) is Cors, most browsers including chromium (which is used by electron) become more and more restrictive. There is a pending bugfix to handle this better in the newsfeed module which will released with next mm release.

        But some websites set headers to avoid being used in an iframe, at this point we can do nothing at the moment.

        1 Reply Last reply Reply Quote 0
        • E Offline
          Egnos
          last edited by

          I tried to use sites that create RSS feeds from a web page but they are very inaccurate.

          Nobody knows an iframe module that allows automatic page scrolling?

          My Mirror https://forum.magicmirror.builders/topic/17262/the-raspimirror-was-born/7

          S 1 Reply Last reply Reply Quote 0
          • S Offline
            sdetweil @Egnos
            last edited by

            @Egnos its doable,

            iframe auto scrolling

            but requires some code… even on the CSS approach cause you would want to wait some time,
            then change the css style

            I am not aware of a module that does this… ( or how it would decide it NEEDS to on a page by page basis)

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            E 1 Reply Last reply Reply Quote 0
            • E Offline
              Egnos @sdetweil
              last edited by

              @sdetweil said in Extract parts of web pages:

              ( or how it would decide it NEEDS to on a page by page basis)

              Scrolling a page would be enough (the web page you set in configuration …), when it arrives at the end it comes back up.
              I speak as a non-developer, I don’t know how difficult it is …

              My Mirror https://forum.magicmirror.builders/topic/17262/the-raspimirror-was-born/7

              S 1 Reply Last reply Reply Quote 0
              • S Offline
                sdetweil @Egnos
                last edited by

                @Egnos ok, so you assume that the page always needs to be scrolled

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                E 1 Reply Last reply Reply Quote 0
                • E Offline
                  Egnos @sdetweil
                  last edited by Egnos

                  @sdetweil Yes, in any case in order to read a web page it must be scrolled. Monitors usually can’t fit the full page …

                  My Mirror https://forum.magicmirror.builders/topic/17262/the-raspimirror-was-born/7

                  1 Reply Last reply Reply Quote 0
                  • E Offline
                    Egnos
                    last edited by

                    Would it be possible to view the contents of a text file on MM view a file (such as a .js or .json)?
                    Let me explain: since I don’t have the skills to automatically extract information from a website. I was thinking, for now, of manually updating a file every month.
                    I would need a form that would print this information contained in a file in local on the MM… (in the future I could automate the writing of this file …)

                    Do you think it would be possible?
                    If so, do you know of a module that could do this?

                    Thanks guys!

                    My Mirror https://forum.magicmirror.builders/topic/17262/the-raspimirror-was-born/7

                    S 2 Replies Last reply Reply Quote 0
                    • S Offline
                      sdetweil @Egnos
                      last edited by sdetweil

                      @Egnos from the 3rd party module list

                      https://github.com/SaltyRiver/MMM-SimpleText

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        sdetweil @Egnos
                        last edited by sdetweil

                        @Egnos to get your ‘file’ content do

                        view the page in a browser, print to file(not pdf)

                        Sam

                        How to add modules

                        learning how to use browser developers window for css changes

                        E 1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 1 / 2
                        • First post
                          Last post
                        Enjoying MagicMirror? Please consider a donation!
                        MagicMirror created by Michael Teeuw.
                        Forum managed by Sam, technical setup by Karsten.
                        This forum is using NodeBB as its core | Contributors
                        Contact | Privacy Policy