QWebFrame::toHtml() is encoding <> automatically!
-
wrote on 2 Apr 2013, 11:25 last edited by
Below is a testing php script,
@<?php
echo $_GET['abc'], "<br/>";
echo htmlentities($_GET['abc']);
?>@If I retrieve the contents of that page with chromium browser, showing the source code reveals contents like this:
@<><br/>& lt;& gt;@ (Remove the "space")
But with QWebFrame::toHtml(), all <> are encoded, and I got:
@<html><head></head><body>& lt;& gt;<br>& lt;& gt; </body></html>@
(Remove the space!)So clearly createMarkup encoded them, can I stop that behavior?
-
according to QWebFrame's implementation there is no way ... at least with the toHtml()-method.
1/2