Ticket #768 (closed task: fixed)

Opened 3 years ago

Last modified 1 year ago

General: Ensure W3C standards

Reported by: roger.demetrescu Assigned to: roger.demetrescu
Priority: normal Milestone: 0.9a5
Component: Widgets Version: 0.9a5
Severity: normal Keywords:
Cc:

Description

Cleanup html warnings in all areas of Turbogears:

  • Toolbox
  • Documentation
  • Widgets
  • Quckstart templates
  • others...

This work can be made with the help of Tidy Html Validator.

Attachments

motivation.jpg (1.8 kB) - added by roger.demetrescu on 04/20/06 23:00:03.
That's our motivation.. :)
1st_round.patch (19.1 kB) - added by roger.demetrescu on 04/20/06 23:01:21.
1st round
2nd_round.patch (3.2 kB) - added by roger.demetrescu on 04/26/06 00:19:30.
2nd round

Change History

04/20/06 23:00:03 changed by roger.demetrescu

  • attachment motivation.jpg added.

That's our motivation.. :)

04/20/06 23:01:21 changed by roger.demetrescu

  • attachment 1st_round.patch added.

1st round

04/20/06 23:05:47 changed by roger.demetrescu

  • summary changed from General: Ensure W3C standards to [PATCH] General: Ensure W3C standards.

Ok, here is the first patch... After applied, this ticket can be normally closed.

I'll probably reopen it in the future to add more fixes, as needed...

[]s Roger

04/21/06 12:55:15 changed by godoy

Looks OK to me. :-) But I don't think the image should go ;-)) (Just kidding, someone with commit access should commit this)

04/21/06 14:06:54 changed by roger.demetrescu

LOL \o/ !! :))

I was thinking in suggest Kevin about replacing the TG logo (the gear) with this motivation.jpg..

See you.. :D

04/23/06 05:21:53 changed by anonymous

  • status changed from new to closed.
  • resolution set to fixed.

Comitted at [1211] Thanks! (Closing it as you suggested, waiting for you to reopen it ;)

04/26/06 00:19:30 changed by roger.demetrescu

  • attachment 2nd_round.patch added.

2nd round

04/26/06 00:22:28 changed by roger.demetrescu

  • status changed from closed to reopened.
  • resolution deleted.

Ok, I'm sending the 2nd patch...

This one fixes the last 4 warnings (all of them related to AutoCompleteField widget) that appear in Widget Browser.

Again, this ticket can be closed after the patch is applied.

Thanks !

Roger

04/28/06 20:57:25 changed by kevin

  • status changed from reopened to closed.
  • resolution set to fixed.
  • milestone set to 0.9a5.

patch applied, will commit soon.

05/02/06 03:00:48 changed by andy@groveronline.com

  • status changed from closed to reopened.
  • resolution deleted.
  • version changed from 0.9a4 to 0.9a5.
  • component changed from TurboGears to Widgets.

uh, I think we want the "autocomplete=off" attribute to disable browser-based autocomplete in favor of TG's. Do we really need to remove it to validate cleanly?

05/02/06 04:54:07 changed by roger.demetrescu

But we are setting the "autocomplete=off" ... It only moved from the 'attrs=dict(autocomplete="off"' (which generates a <INPUT ... AUTOCOMPLETE="OFF" /> to the code in JS which does this adjustment in runtime (autocompletefield.js):

        updateNodeAttributes(this.textField, { 
	                "onkeyup": this.theKeyUp, 
	                "onkeydown": this.theKeyPress, 
	                "onblur": this.lostFocus, 
	                "onfocus": this.gotFocus 
	                "onfocus": this.gotFocus, 
	                "autocomplete": "off"           <=== this one
        });

Are you having any problem with this modification ? I did a lot of tests with Firebug Extension and realized that in terms of DOM, it was completely equivalent...

Cheers

Roger

05/02/06 06:25:55 changed by andy@groveronline.com

  • status changed from reopened to closed.
  • resolution set to fixed.

doh, there's a bug in FF with autocomplete=off that only is fixed in 1.5+, and I'm still using 1.08 on Ubuntu. Sorry for the noise.

05/02/06 07:13:12 changed by roger.demetrescu

No problem... :)

Will your FF 1.08 work with the old code ? If so, maybe we should revert it (which would be sad... but it is really needed...)

Cheers

Roger

05/03/06 02:45:40 changed by andy@groveronline.com

FF 1.08 worked with the old code. However, I upgraded to FF 1.5 last night so I can no longer test. I spent some time searching bugzilla.mozilla.org trying to find which version of FF it was fixed in, with no luck.

I'd like to see someone besides me hit this issue before reverting. I don't think FF 1.0x is that popular any more, and I also don't know if it showed up on platforms besides Linux.

05/03/06 08:02:21 changed by roger.demetrescu

  • summary changed from [PATCH] General: Ensure W3C standards to General: Ensure W3C standards.

Hmmm... I asked a coworker who is using FF 1.0.4 on windows do do a test:

  1. I reverted the code.
  2. My coworker hit my toolbox (modified to have a form outside the autocomplete widget)
  3. He hitted again my toolbox, and the browser didn't show the autocomplete browser's feature (as expected)
  4. I re-reverted the code (better say: I left it setting up the autocomplete="off" using JS)
  5. He hitted the toolbox, and this time his browser showed the autocomplete browser's feature (bad, bad)
  6. He did a cache clean...
  7. It worked again, as expected...

I could't even reproduce this behavior, using FF1.5...

What does it means ? I hope you had a problem with the cache of FF 1.0.8... And maybe when you upgraded to FF 1.5, it worked.

If you have time to do some more tests, I would ask you to:

  1. Revert the code
  2. Revert the FF to 1.0.8
  3. Do tests using your project
  4. Upgrade again the code (which moves autocomplete="off" to js)
  5. Test again your project... if it shows the undesired autocomplete listbox, clean-up your browser cache and see if it works...

If it doesn't work with the cleanup, maybe we should really revert the changes....

Thanks again

Roger

05/08/06 22:42:57 changed by andy@groveronline.com

I think I was mistaken and I'm seeing another problem, which has nothing to do with browser version. I will open a separate bug.