Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Ticket #768 (closed task: fixed)

Opened 13 years ago

Last modified 12 years ago

General: Ensure W3C standards

Reported by: roger.demetrescu Owned by: roger.demetrescu
Priority: normal Milestone: 0.9a5
Component: TG 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 Download (1.8 KB) - added by roger.demetrescu 13 years ago.
That's our motivation.. :)
1st_round.patch Download (19.1 KB) - added by roger.demetrescu 13 years ago.
1st round
2nd_round.patch Download (3.2 KB) - added by roger.demetrescu 13 years ago.
2nd round

Change History

Changed 13 years ago by roger.demetrescu

That's our motivation.. :)

Changed 13 years ago by roger.demetrescu

1st round

comment:1 Changed 13 years ago 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

comment:2 Changed 13 years ago by godoy

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

comment:3 Changed 13 years ago 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

comment:4 Changed 13 years ago 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 ;)

Changed 13 years ago by roger.demetrescu

2nd round

comment:5 Changed 13 years ago by roger.demetrescu

  • Status changed from closed to reopened
  • Resolution fixed 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

comment:6 Changed 13 years ago by kevin

  • Status changed from reopened to closed
  • Resolution set to fixed
  • Milestone set to 0.9a5

patch applied, will commit soon.

comment:7 Changed 13 years ago by andy@…

  • Status changed from closed to reopened
  • Resolution fixed 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?

comment:8 Changed 13 years ago 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

comment:9 Changed 13 years ago by andy@…

  • 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.

comment:10 Changed 13 years ago 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

comment:11 Changed 13 years ago by andy@…

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.

comment:12 Changed 13 years ago 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

comment:13 Changed 13 years ago by andy@…

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.

Note: See TracTickets for help on using tickets.