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.

    weather module just shows loading?

    Scheduled Pinned Locked Moved Troubleshooting
    7 Posts 3 Posters 1.4k 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
      scumbelly @fribse
      last edited by sdetweil

      @fribse

      Are your single quotes ’ just an accident in your examples?

      {
      			module: "currentweather",
      			position: "top_right",
      			header: "my header",
      			config: {
      				location: "my village",
      //				locationID: "numbers",  //ID from http://bulk.openweathermap.org/sample/; unzip the gz file and find your city
      				appid: "wholelottanumbers",
      				appendLocationNameToHeader: false,
      				degreeLabel: true,
      				useBeaufort: false,
      				useKMPHwind: true,
      				showHumidity: true
      			}
      		},
      

      Hope this helps.

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

        @scumbelly single or double doesn’t matter as long as they are the same

        please use code markers around config info.
        there is a third kinds of quote mark used by the forum without code blocks. they are word processing type, they are curved, both single and double. they are bad.

        " and ’
        notice the difference

        " and '
        

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 Reply Last reply Reply Quote 0
        • S Offline
          scumbelly
          last edited by

          O.K.

          and… onlyTemp: ‘true’, would not have any quotes.

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

            @scumbelly right…

            general config.js rules

            thing to the left of colon (:) does not need quotes

            if the thing to the right of colon is a number or true/false,
            should NOT have quotes,
            otherwise the thing to the right needs quotes.
            single or double doesn’t matter, as long as both ends are the same

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 2
            • S Offline
              scumbelly
              last edited by

              @sdetweil

              Thanks, I always thought I needed double quotes.

              1 Reply Last reply Reply Quote 0
              • F Offline
                fribse @scumbelly
                last edited by

                Ok, I found out what was wrong, despite the confusion with the ’ or " use.
                It’s the appid, it’s called apiKey in the weather module.
                So after changing that (and also changing all ’ to " in the config), removing quotes around numbers, only have the locationID instead of both location and locationID and other cleanup stuff, it is shows properly :-)

                So I replaced both my currentweather and YrThen modules with two weather modules:

                {
                      module: "weather",
                      position: "top_right",
                      classes: "day_schedule",
                      config: {
                        weatherProvider: "openweathermap",
                        type: "current",
                        units: "metric",
                        timeFormat: 24,
                        decimalSymbol: ",",
                        initialLoadDelay: 0,
                        onlyTemp: false,
                        locationID: 2621215,
                        apiKey: "xxx"
                      }
                    },
                    {
                      module: "weather",
                      position: "top_right",
                      classes: "day_schedule",
                      config: {
                        weatherProvider: "openweathermap",
                        type: "forecast",
                        units: "metric",
                        timeFormat: 24,
                        decimalSymbol: ",",
                        initialLoadDelay: 0,
                        onlyTemp: true,
                		maxNumberOfDays: 7,
                		colored: true,
                		appendLocationNameToHeader: false,
                        locationID: 2621215,
                        apiKey: "xxx"
                      }
                    },
                

                Looks very nice indeed
                72f6ceb8-742c-4a07-8b3f-61bb47375ee4-image.png

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                • 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