Page MenuHomePhabricator

Template's CSS code shows on page when editing
Closed, InvalidPublic

Description

picture of the bug

Template's html code shows on page when editing. I don't know should we change something with our templates on fi-wiki, or is it possible to fix in VisualEditor.

How to reproduce:

  1. go to https://fi.wikipedia.org/wiki/Australian_Grand_Prix_2014?veaction=edit
  2. see the 2 templates on the bottom of the page

If you need more information, feel free to ask.


Version: unspecified
Severity: normal

Attached:

Nimetön.png (450×1 px, 47 KB)

Details

Reference
bz63259

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 2:56 AM
bzimport added a project: VisualEditor.
bzimport set Reference to bz63259.

Well, https://fi.wikipedia.org/w/index.php?title=Malline:Australian_Grand_Prix&action=edit

lisätyylit = ...styleinfo..." cellpadding="2" cellspacing="5"

What is that, and what gave anyone the idea that that would ever work ? :D

Hi, i think that the idea of the "lisätyylit" is to add css inline rules to div and stuff after that is to end css-rules and add some table attributes. However it has never worked because there is div element and not table. It also broke resulting html-code even it seemed to work.

Reason why visual editor broke is the mismatching doublequotes in expanded template result (in lisätyyli param: '... both" cellpadding="2" cellspacing="5"':

  • Clip --

<div class="NavFrame " style=" margin: auto; background-color: #ffffff; border: 1px #aaaaaa solid; margin: 0.5em auto auto auto; width: 600px; text-align: center; font-size: 95%; clear: both;; background-color: #FFFFFF; color: #000000; width: auto;"><div class="NavHead" style="display:block;text-align:center;background-color: #F3D161;">

  • Clip --

I fixed some templates with this change and my guess that all of F1-templates can be fixed with same way:

However there seems to be little delay before change can be seen in visual editor after template is fixed and i could not find any way to purge visual editors cache.

If it ok for stryn i think that this bug can be closed.

Closed. Thanks for your investigating.