Page MenuHomePhabricator

TemplateStyles <style> tags are again wrapped in <p> tags
Closed, InvalidPublic

Description

TemplateStyles <style> tags are again wrapped in <p> tags. This was previously solved in T186965. This happens both on pages where the <templatestyles> tag is directly in the page like https://sv.wikipedia.org/wiki/Estaci%C3%B3n_Central_(station) as well as on pages where the <templatestyles> tag is included via a template like https://sv.wikipedia.org/wiki/Ulf_Andersson_(boxare)

Note that the exact behaviour is different between them, and also different from the old issue. In Estación Central (station), there is an empty <span> tag inside the <p> tag, before the <style> tag. In Ulf Andersson (boxare), there is a <br> tag inside the <p> tag, before the <style> tag. The old issue solved in 2018 did not have any <span> or <br> tags inside the <p> tag.

Event Timeline

TheDJ subscribed.

This is because of the {{coord}} template in use on that article. It expands as:

<span><indicator name="coordinates"><span id="coordinates">[[Geografiska koordinatsystem|Koordinater]]: <span class="plainlinks nourlexpansion">[//geohack.toolforge.org/geohack.php?language=sv&pagename=Estaci%C3%B3n_Central_(station)&params=33_27_7_S_70_40_44_W_region:CL <span class="geo-default"><span class="geo-dms" title="Kartor, flygfoton och andra data för denna plats"><span class="latitude">33°27′7″S</span> <span class="longitude">70°40′44″V</span></span></span><span class="geo-multi-punct">&#xfeff; / &#xfeff;</span><span class="geo-nondefault"><span class="geo-dec" title="Kartor, flygfoton och andra data för denna plats">33.45194°S 70.67889°V</span><span style="display:none">&#xfeff; / <span class="geo">-33.45194; -70.67889</span></span></span>]</span></span></indicator></span>

which when the indicator is moved out reduces to:

<span></span>

and some line breaks which then creates the <p> and the <span> stuff. This is perfectly logical and expected, you'll have to correct the coord template.