I'm trying to read the results of a database query into an XML document but it's only read so far and stopping. The XML document is as follows:
Expand|Select|Wrap|Line Numbers
- <?xml version="1.0" encoding="utf-8"?>
- <night>
- <name>Poontang</name>
- <homePageSummary>Launches 26th November</homePageSummary>
- <whatsOnPageSummary>Every Monday from 26th Nov Door price: £5/£4 Guestlist (07809867930)</whatsOnPageSummary
- >
- <description>Poontang is of course, a punch made from the fermented juice from the rare poonberry bush
- . It became hugely popular during colonial times, it was a favourite of the Founding Fathers, drank constantly
- by George Washington, as evedenced by his farewell address, 'I only took the job for the poontang'.
- <br />
- <br />
- The first recorded recipe was printed in Ye Boston Globe. Unfortunately, poontang's immense popularity
- was later learned to be the result of addictive qualities. <br />
- <br />
- The hunger for good quality poontang is said to have made a Bishop kick a hole in a stained glass window
- . Withdrawl will occur, leading to unappealing physical &amp; mental consequences, including blue
- balls, hairy palms &amp; lack of mental clarity. <br />
- <br />
- COME SEE THE POONTANG PANDA.... <br />
- Performing its erotic pole dance routine <br />
- Pouring free poontang punch from the stage <br />
- Giveaway baby poontang panda cuddly toys <br />
- and if your lucky he might just hump your leg! <br />
- <br />
- DRINKS <br />
- Baby Champers 70p! <br />
- Bottles of Sol &amp; Sambucca Shots &pound;1 <br />
- Double Spirit &amp; Mixer inc Red Bull &pound;2.40 <br />
- Poontang Pitchers &amp; Red Pig Pithcers &pound;5 <br />
- Bottles of House Wine &pound;7 <br />
- <br />
- MUSIC <br />
- Big Panda Party Tunes -&gt; Dance, R'n'B and Indie <br />
- <br /></description>
- <thumbnail>thumb447.jpg</thumbnail>
- <flyer>poon_flyer451.jpg</flyer>
- </night>
Expand|Select|Wrap|Line Numbers
- function html_numeric_entities($str)
- {
- return preg_replace('/[^!-%\x27-;=?-~ ]/e', '"&#".ord("$0").chr(59)', $str);
- };
- $description = html_numeric_entities(html_entity_decode($row['description']));
- $description = $night->appendChild($dom->createElement('description', $description));
Hopefully some kind soul can guide on what I'm doing wrong.
Thanks,
Sean