asp to convert HTML to XHTML

Results 1 to 2 of 2

Thread: asp to convert HTML to XHTML

  1. #1
    Join Date
    Dec 1969

    Default asp to convert HTML to XHTML

    Does there exist a script which will take a string of html and convert it to valid xhtml?<BR><BR>It seems I have seen something like this before. The need is for a site to validate as xhtml. However, our current CMS editor uses mshtml which produces html which does not validate (upper case tags, no quoted attributes and unclosed tags for img and br etc).<BR><BR>In order to allow the site to validate, I want to include a script which contains a function xhtmlContent() which will return the xhtml for the current page, instead of returning the content "as is" in non valid html.<BR><BR>The ideal approach will be to migrate to an xhtml compliant cms editor, which we are developing now, and storing valid xhtml in the db, but this is a stop gap.<BR><BR>Any ideas appreciated.

  2. #2
    Join Date
    Dec 1969

    Default RE: asp to convert HTML to XHTML

    I&#039;ve never seen a component to do this, and given HTML4.0&#039;s structure, developing one is a non-trivial task, although the MSHTML control is consistent if nothing else. a parser based on regular expression should be able to do a decent job for you...<BR><BR><BR>j<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts