Jump to content
DetlefM

Not valid XML text

Recommended Posts

DetlefM

I have been tried to converting EPG data from the media server. Unfortunately, the Microsoft XML parser (and all the others I've tried) has problems with the & character (for example, on the Kiss & Kiss program). Other special characters such as umlauts are processed properly.

Is anybody aware of any other incompatibilities?
Would it be possible to make a server-side change to utf-8 or take other actions like & amp; ?
At the moment I have not found a bigger or smaller character in the text but I do not know if such things are considered in the EPG text on the server side.

epg.xml

Share this post


Link to post
Griga
12 minutes ago, DetlefM said:

I have been tried to converting EPG data from the media server.

 

How? With which URL / API call?

 

Are there known programmes in the future whose EPG title or description contains the & character? Please post the channel and time.

 

Share this post


Link to post
DetlefM
19 minutes ago, Griga said:

 

How? With which URL / API call?

 

Are there known programmes in the future whose EPG title or description contains the & character? Please post the channel and time.

 

My call was http://192.168.0.102:8089/api/epg.html?lvl=2&channel=562954320954462

The result I had attached in my start post (epg.xml) in this file are 3 of &

Same call today results with (partly):

<programme channel="562954320954462" stop="20180716015500" start="20180716013100"> <eventid>45388</eventid> <charset>255</charset> <titles> <title>Eine schrecklich nette Familie</title></titles> <events> <event>Wir wollen Psycho Dad (2), Sitcom, USA 1994</event> </events> <descriptions> <description>Die Protestaktion von Al und seinen Freunden bewirkt lediglich, dass sich der Hauptdarsteller der TV-Serie "Psycho Dad" weigert, seine Rolle weiterzuspielen. Nun wollen die Demonstranten bis nach Washington gehen. Marcy bezweifelt zwar, dass sich der Kongress für das Anliegen von Al & Co. interessieren wird, doch da täuscht sie sich: Senator Furman verschiebt sogar eine wichtige Anhörung zu den Friedensgesprächen im Nahen Osten, um die "Psycho Dad"-Demonstranten zu empfangen. Regie: Gerry Cohen Drehbuch: David Castro Komponist: Sammy Cahn, James Van Heusen Kamera: Thomas W. Markle Darsteller: Ed O'Neill (Al Bundy) Katey Sagal (Peggy Bundy) Christina Applegate (Kelly Bundy) David Faustino (Bud Bundy) Amanda Bearse (Marcy) Ted McGinley (Jefferson D'Arcy) E. E. Bell (Bob Rooney) Harold Sylvester (Griff) Patrick J. McCormack (Sen. Furman) [4:3] [stereo] [deu]</description> </descriptions>

 

You can see : "Al & Co." in the description.

 


 

Share this post


Link to post
Griga
10 minutes ago, DetlefM said:

Please post the channel and time.

 

..in a human readable form. For reproducing the issue I need to know on which channel I can find such EPG data (hoping it is satellite, can't receive cable)

 

All I can see in the code is that the DMS encodes the ampersand character as &amp; in the XML EPG export.

 

Share this post


Link to post
Griga

OK, I've tried the following:

  • Searched the EPG in DVBViewer for the ampersand character, found (among others) "Panda, Gorilla & Co." on "Das Erste HD" via satellite.
  • Retrieved the EPG Channel ID for "Das Erste HD" from the DVBViewer Channel Editor (select the channel, press Ctrl + G to copy the EPG Channel ID to the clipboard).
  • Used the EPG Channel ID in the following URL (where download=1 forces the browser to download the data instead of displaying it):

http://127.0.0.1:8089/api/epg.html?lvl=2&channel=562954315180093&download=1

  • Opened the downloaded file epg.xml in Notepad++, found "Panda, Gorilla &amp; Co.". That's how it should be - correctly encoded XML.

However, if you copy the XML from the browser window you will get "Panda, Gorilla & Co." because the browser decodes the text for displaying it.

 

Please learn from this example how to provide a step by step description of how you got your results!

 

Share this post


Link to post
DetlefM
7 minutes ago, Griga said:

... however, if you copy the XML from the browser window 

 

Please learn from this example how to provide a step by step description of how you got your results!

 

Sorry für wasting your time. Was a beginner error. And thanks

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...