[Haskell-cafe] Parse HTML that is contain javascript

Andrey Chudnov achudnov at gmail.com
Tue Dec 24 22:37:26 UTC 2013


I've used HXT with the tagsoup backend for parsing HTML with embedded
JavaScript. Worked fine for me, although I don't think I've ever had to
deal with CDATA embedded in comments of scripts. You can have a look at
the source of the 'jespresso' library on hackage if interested.

On 12/24/2013 11:03 PM, akira kawata wrote:
> Hi, I am Akira.
> I want to parse HTML file that is contain javascript.
> But I cant come up with how to deal with script tag.
> Is there anyone help me?
>
> Details of probrem
> HTML code I want to parse is like following
>
> <html>
> <script>
> //<![CDATA[
> <!-- -->
> //]]>
> </script>
> </html>
>
> Because '<' is used as normal character in the script region,
> I can not use my HTML parser there.
>
>
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20131225/052760bc/attachment.html>


More information about the Haskell-Cafe mailing list