Hi, you could use RegExp to replace <br> with <br/> and <img ..> with <img ... />, but tis ir really just a workaround since you would need a single RegExp for every non closed tag in HTML.
by(e) Stephan 2009/2/5 dantan <hattin...@gmail.com>: > > I am trying to parse the html out of a specific div to save it with > php into a SQL-database. > > Working good so far. > The html is valid xhtml, but html() makes <br> instead of <br /> and > <img......> instead of <img...../> > > Is there a workaround to get the xhtml? >