I am asking about rules for using the pre tag in templates, specifically as it
pertains to the style attribute?
1.4.8 templates using the pre tag and style attribute allowed style changes
and this no longer works in 1.5rc3 without modifying parser.php to ignore pre
in the strip routine. Without modification the style attribute is removed
from a pre tag in a template.
I have been searching for the specific code that changed to disable the style
attribute. The parser appears to handle the pre tag in the same manner.
Could it be that the template is handled differently?
It is interesting that replacing pre tag with the div tag in the same template
does work, but of course the results are very different.
Why is style attribute disabled for pre and not for div?
For example,
Template:YCB (short for yellow code box)
<pre style="
margin-top: 8pt;
margin-bottom: 8pt;
background-color: #ffff80;
white-space:pre;
border-style:solid;
border-width:1px;
border-color:#999999;
color:#333333;
padding:10px;
width=100%;">{{{1}}}</pre>
DirSample
The following shows simple program execution.
{{YCB|1=<nowiki>
[atl@donald lt]$ ls
hw sw
</nowiki>}}
A little help to point me in the right direction would be greatly appreciated.
Show replies by date