Reply to Re: help - isolate specific xml from mySQL entry?

Your name:

Reply:


Posted by Tommy Gildseth on 02/24/06 21:29

henshu wrote:

> I wonder if its possible to "extract"/copy/parse a specific line of xml
> from my mySQL table - isolate it from the rest of the mysql entry (on
> PHP display)?
>
> example (as mySQL see's it):
> "Today is sunny <img src="/pictures/sun.gif" /> with chances of rain
> <img src="/pictures/raincloud.jpg" width="50" alt="rain" title="rain" />
> this evening. So you may want to carry your umbrella on your way to work."
>
> isolated out to:
> <img src="/pictures/sun.gif" /><img src="/pictures/raincloud.jpg"
> width="50" alt="rain" title="rain" />

I do not believe that will be possible using only SQL, and I'm not even sure
it's adviseable.
You will probably need to do some post processing with PHP. It can probably
be done using regex, or you can use XML DOM functions to parse the XML, and
extract all the child nodes using for ex. XPATH.

--
Tommy
http://design.twobarks.com/

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация