1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-04 13:18:00 +02:00

Add vim modelines to all files.

Signed-off-by: Edward Z. Yang <edwardzyang@thewritingpot.com>
This commit is contained in:
Edward Z. Yang
2008-12-06 04:24:59 -05:00
parent 781f9a4084
commit 12b811d749
699 changed files with 1071 additions and 107 deletions

View File

@@ -5,3 +5,4 @@ HTML.AllowedAttributes = a.href,*.id
<p>Par.</p>
<p>Para<a href="http://google.com/">gr</a>aph</p>
Text<b>Bol<i>d</i></b>
--# vim: et sw=4 sts=4

View File

@@ -5,3 +5,4 @@ HTML.AllowedAttributes = a.href,*.id
<span>Not allowed</span><a class="mef" id="foobar">Remove id too!</a>
--EXPECT--
Not allowed<a>Remove id too!</a>
--# vim: et sw=4 sts=4

View File

@@ -2,3 +2,4 @@
<b>basic</b>
--EXPECT--
<b>basic</b>
--# vim: et sw=4 sts=4

View File

@@ -3,3 +3,4 @@ HTML.ForbiddenElements = b
HTML.ForbiddenAttributes = a@href
--HTML--
<p>foo</p>
--# vim: et sw=4 sts=4

View File

@@ -5,3 +5,4 @@ HTML.ForbiddenAttributes = a@href
<b>Foo<a href="bar">bar</a></b>
--EXPECT--
Foo<a>bar</a>
--# vim: et sw=4 sts=4

View File

@@ -2,3 +2,4 @@
CSS.AllowedProperties = color,background-color
--HTML--
<div style="color:#f00;background-color:#ded;">red</div>
--# vim: et sw=4 sts=4

View File

@@ -4,3 +4,4 @@ CSS.AllowedProperties = color,background-color
<div style="color:#f00;border:1px solid #000">red</div>
--EXPECT--
<div style="color:#f00;">red</div>
--# vim: et sw=4 sts=4

View File

@@ -3,3 +3,4 @@ URI.Disable = true
--HTML--
<img src="foobar" />
--EXPECT--
--# vim: et sw=4 sts=4

View File

@@ -3,4 +3,4 @@
--HTML--
--EXPECT--
--# vim: et sw=4 sts=4

View File

@@ -2,3 +2,4 @@
<span id="moon">foobar</span>
--EXPECT--
<span>foobar</span>
--# vim: et sw=4 sts=4

View File

@@ -3,3 +3,4 @@ Attr.EnableID = true
--HTML--
<span id="moon">foobar</span>
<img id="folly" src="folly.png" alt="Omigosh!" />
--# vim: et sw=4 sts=4

View File

@@ -8,3 +8,4 @@ URI.MungeResources = true
--EXPECT--
<a href="/redirect?s=http%3A%2F%2Fexample.com&amp;t=c15354f3953dfec262c55b1403067e0d045a3059&amp;r=&amp;n=a&amp;m=href&amp;p=">Link</a>
<img src="/redirect?s=http%3A%2F%2Fexample.com&amp;t=c15354f3953dfec262c55b1403067e0d045a3059&amp;r=1&amp;n=img&amp;m=src&amp;p=" style="background-image:url(/redirect?s=http%3A%2F%2Fexample.com&amp;t=c15354f3953dfec262c55b1403067e0d045a3059&amp;r=1&amp;n=img&amp;m=style&amp;p=background-image);" alt="example.com" />
--# vim: et sw=4 sts=4

View File

@@ -3,3 +3,4 @@ Attr.EnableID = true
HTML.Doctype = "XHTML 1.0 Strict"
--HTML--
<a name="asdf"></a>
--# vim: et sw=4 sts=4

View File

@@ -7,3 +7,4 @@ URI.MungeSecretKey = "foo"
<object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/Oq3FV_zdyy0&hl=en"></param><embed src="http://www.youtube.com/v/Oq3FV_zdyy0&hl=en" type="application/x-shockwave-flash" width="425" height="344"></embed></object>
--EXPECT--
<object width="425" height="344" data="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" type="application/x-shockwave-flash"><param name="allowScriptAccess" value="never" /><param name="allowNetworking" value="internal" /><param name="movie" value="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" /><embed src="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" type="application/x-shockwave-flash" width="425" height="344" allowscriptaccess="never" allownetworking="internal" /></object>
--# vim: et sw=4 sts=4

View File

@@ -5,3 +5,4 @@ HTML.SafeEmbed = true
<object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/Oq3FV_zdyy0&hl=en"></param><embed src="http://www.youtube.com/v/Oq3FV_zdyy0&hl=en" type="application/x-shockwave-flash" width="425" height="344"></embed></object>
--EXPECT--
<object width="425" height="344" data="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" type="application/x-shockwave-flash"><param name="allowScriptAccess" value="never" /><param name="allowNetworking" value="internal" /><param name="movie" value="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" /><embed src="http://www.youtube.com/v/Oq3FV_zdyy0&amp;hl=en" type="application/x-shockwave-flash" width="425" height="344" allowscriptaccess="never" allownetworking="internal" /></object>
--# vim: et sw=4 sts=4

View File

@@ -6,3 +6,4 @@ HTML.Trusted = true
<script type="text/javascript"><!--//--><![CDATA[//><!--
alert("<This is compatible with XHTML>");
//--><!]]></script>
--# vim: et sw=4 sts=4

View File

@@ -8,3 +8,4 @@ alert("<This is compatible with XHTML>");
<script type="text/javascript"><!--//--><![CDATA[//><!--
alert("<This is compatible with XHTML>");
//--><!]]></script>
--# vim: et sw=4 sts=4

View File

@@ -8,3 +8,4 @@ alert("<This is compatible with XHTML>");
<script type="text/javascript"><!--//--><![CDATA[//><!--
alert("<This is compatible with XHTML>");
//--><!]]></script>
--# vim: et sw=4 sts=4

View File

@@ -8,3 +8,4 @@ alert("<This is compatible with XHTML>");
<script type="text/javascript"><!--//--><![CDATA[//><!--
alert("<This is compatible with XHTML>");
//--><!]]></script>
--# vim: et sw=4 sts=4

View File

@@ -8,3 +8,4 @@ alert("<This is compatible with XHTML>");
<script type="text/javascript"><!--//--><![CDATA[//><!--
alert("<This is compatible with XHTML>");
//--><!]]></script>
--# vim: et sw=4 sts=4

View File

@@ -7,3 +7,4 @@ URI.MungeSecretKey = "foo"
--EXPECT--
<a href="/redirect.php?url=http%3A%2F%2Flocalhost&amp;check=8e8223ae8fac24561104180ea549c21fbd111be7">foo</a>
<img src="http://localhost" alt="local" />
--# vim: et sw=4 sts=4

View File

@@ -5,3 +5,4 @@ Core.Encoding = "Shift_JIS"
Core.EscapeNonASCIICharacters = true
--HTML--
<b style="font-family:'&#165;';">111</b>
--# vim: et sw=4 sts=4

View File

@@ -6,3 +6,4 @@ Core.Encoding = Shift_JIS
<b style="font-family:'&#165;';">111</b>
--EXPECT--
<b style="font-family:'';">111</b>
--# vim: et sw=4 sts=4

View File

@@ -4,3 +4,4 @@ HTML.Doctype = "XHTML 1.0 Strict"
<blockquote>Illegal <b>contents</b></blockquote>
--EXPECT--
<blockquote><p>Illegal <b>contents</b></p></blockquote>
--# vim: et sw=4 sts=4

View File

@@ -4,3 +4,4 @@ HTML.Strict = true
<blockquote>Illegal contents</blockquote>
--EXPECT--
<blockquote><p>Illegal contents</p></blockquote>
--# vim: et sw=4 sts=4

View File

@@ -4,3 +4,4 @@ HTML.Strict = true
<u>Illegal underline</u>
--EXPECT--
<span style="text-decoration:underline;">Illegal underline</span>
--# vim: et sw=4 sts=4

View File

@@ -2,3 +2,4 @@
<table background="logo.png"><tr><td>asdf</td></tr></table>
--EXPECT--
<table style="background-image:url(logo.png);"><tr><td>asdf</td></tr></table>
--# vim: et sw=4 sts=4

View File

@@ -1,3 +1,3 @@
--HTML--
Foo<b> </b>bar
--# vim: et sw=4 sts=4