Plugin Directory

gengo

Opened 18 years ago

Last modified 17 years ago

#883 assigned defect

Gengo widget not theme (and xhtml) compliant

Reported by: conradoplg's profile conradoplg's profile conradoplg Owned by: pixline's profile pixline's profile pixline
Priority: normal Severity: normal
Plugin: gengo Keywords: has-patch, need-testing
Cc: supporto@…

Description

The Gengo "Language Controls" widget is not theme compliant.

Since it adds hard-coded h2 headers in each widget section header, it may break themes since their heading structure may be different.

I'm not sure which is the best way to fix this, but in the attached patch, I basically treated the widget like three distinct widgets in sequence.

I've also fixed a minor issue which prevents XHTML validation: the "Language control" ul element had the same id as the "Available languages" ul element. I've changed it, but I'm not 100% sure if this can't break something (I've tested it and found no problems)

Attachments (2)

widget_theme_compliant.diff (2.7 KB) - added by conradoplg 18 years ago.
widget_theme_compliant2.diff (5.6 KB) - added by conradoplg 18 years ago.
2nd try

Download all attachments as: .zip

Change History (7)

#1 @conradoplg
18 years ago

I've just realized that the diff breaks the "gengo_language_control" function, so it needs some tweaking...

#2 @conradoplg
18 years ago

...aaand realized that this breaks XHTML again by generating 3 ul's with the same id "gengo_command". I'm not sure how to fix this.

#3 @pixline
18 years ago

  • Owner changed from majelbstoat to pixline

The patch is invalid, but the issue stll exists.

#4 @conradoplg
18 years ago

Here is another try at a patch.

It doesn't break anything as far as I know, since now I'm using default argument parameters. Solved the repeated id issue with a hack, but I think it does the job.

Tested with widgets and template functions, works OK. XHTML compliant.

Also did some tweaking to the js code for the add/remove languages in order to display "None" on "Available Languages" when there is none. (Before it wasn't XHTML compliant due to the ul element without li's)

#5 @pixline
17 years ago

  • Cc supporto@… added
  • Keywords has-patch need-testing added
  • Status changed from new to assigned
Note: See TracTickets for help on using tickets.