• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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.

xml processing

Scheduled Pinned Locked Moved Unsolved Requests
2 Posts 2 Posters 958 Views 2 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.
  • Y Offline
    yuyuyu
    last edited by yuyuyu Aug 2, 2019, 11:43 PM Aug 2, 2019, 11:40 PM

    I want to show you the scheduled time for bus arrival in Magic Mirror.
    To do that, I got a bus api.
    I entered the api URL and it was in xml format.
    I don’t know how to process the xml format in the magic mirror.
    can you tell me solution
    please

    S 1 Reply Last reply Aug 3, 2019, 3:50 AM Reply Quote 0
    • S Away
      sdetweil @yuyuyu
      last edited by sdetweil Aug 3, 2019, 12:26 PM Aug 3, 2019, 3:50 AM

      @yuyuyu easiest is to use the xlm2json conversion, then work with the json objects

      see https://stackoverflow.com/questions/52281389/convert-xml-to-json-with-nodejs

      also, check on the api, it might accept some header to return json instead of xml

      Sam

      How to add modules

      learning how to use browser developers window for css changes

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