ready function too late?

K

Kenny

Noob here.

I have incorporated the jquery ui tab control in my web app. It works Ok
but the page comes up un-tabbed and then flashes into the desired tab
setup. The tabs capability gets in via:

<script>
$(document).ready(function(){
$("#example > ul").tabs();
});
</script>

Am I seeing the un-tabbed rendering initially because the above happens
too late? I copied that from the example here:

http://docs.jquery.com/UI/Tabs

kt
 
S

sasuke

Noob here.

I have incorporated the jquery ui tab control in my web app. It works Ok
but the page comes up un-tabbed and then flashes into the desired tab
setup. The tabs capability gets in via:

<script>
   $(document).ready(function(){
     $("#example > ul").tabs();
   });
</script>

Am I seeing the un-tabbed rendering initially because the above happens
too late? I copied that from the example here:

   http://docs.jquery.com/UI/Tabs

It would be difficult getting any library specific help in this
newsgroup; maybe try posting in a group which specifically targets
your library of choice.
<URL: http://groups.google.com/group/jquery-en>

HTH,
/sasuke
 
K

Kenny

sasuke said:
It would be difficult getting any library specific help in this
newsgroup;

Why? Doesn't anyone use JQuery? I see it is considered Unworthy around
here but religion aside I thought someone would still know it and have a
clue. Besides, I was not asking for JQuery help, I was wondering if
there is an earlier event or opportunity (directly in the DIV tag?)
where I could get the tab set up.
maybe try posting in a group which specifically targets
your library of choice.
<URL: http://groups.google.com/group/jquery-en>

I understand. I had already checked those out and was underwhelmed by
the JQ options. Besides, as I said, I figured a JS group should have
some expertise and might like to help a noob with a simple question.

kt
 
K

Kenny

David said:
Take it out.

Right, and use WordPad to edit HTML directly. :) I saw your posts
complaining about JQuery internals, sounds bad. But I am a non-Web
programmer trying to get a prototype together /fast/ for a demo so there
is not time to go to school on JS and JQuery is working for us.

Can you recommend another library? Dojo looks like an alternative, but
the first thing I tried worked on one browser but not others. So far
JQuery has worked everywhere.

kt
 
E

Evertjan.

Kenny wrote on 10 okt 2008 in comp.lang.javascript:
But I am a non-Web
programmer trying to get a prototype together /fast/ for a demo so there
is not time to go to school on JS and JQuery is working for us.

If JQuery were working for you, should you have such a Q?

JQuery is NOT usefull to overcome the inability of writing Javascript.
 
D

dhtml

Kenny said:
Right, and use WordPad to edit HTML directly. :) I saw your posts
complaining about JQuery internals, sounds bad. But I am a non-Web
programmer trying to get a prototype together /fast/ for a demo so there
is not time to go to school on JS and JQuery is working for us.

You are in the wrong place.
http://jibbering.com/faq/#onlineResources

has links to jQuery, states:

"...
No javascript libraries are endorsed by this group. If you are looking
for help using a library, visit that library's discussion group instead.
jQuery [English]
http://groups.google.com/group/jquery-en
Prototype & Scriptaculous
http://groups.google.com/group/prototype-scriptaculous

...."

Can you recommend another library?

No. That's not what this group is about anyway.

Garrett
 
D

dhtml

dhtml said:
Kenny said:
Right, and use WordPad to edit HTML directly. :) I saw your posts
complaining about JQuery internals, sounds bad. But I am a non-Web
programmer trying to get a prototype together /fast/ for a demo so
there is not time to go to school on JS and JQuery is working for us.

You are in the wrong place.
http://jibbering.com/faq/#onlineResources

has links to jQuery, states:

"...
No javascript libraries are endorsed by this group. If you are looking
for help using a library, visit that library's discussion group instead.
jQuery [English]
http://groups.google.com/group/jquery-en
Prototype & Scriptaculous
http://groups.google.com/group/prototype-scriptaculous

..."

Can you recommend another library?

No. That's not what this group is about anyway.

Garrett


kt
 
D

David Mark

Right, and use WordPad to edit HTML directly. :) I saw your posts

What do you use to edit HTML? I certainly wouldn't recommend WordPad.
complaining about JQuery internals, sounds bad. But I am a non-Web

It is bad.
programmer trying to get a prototype together /fast/ for a demo so there

Okay. For a prototype. Just realize you can't put into production
like that.

But now you are in the *very* unfortunate position of having to ask
questions of other jQuery users. Best of luck. I don't know why your
prototype has a FOUC and I don't have time to delve into it. If it
were a basic stand-alone tab script, then maybe as it would be much
simpler to spot the mistake. See where this is going?
is not time to go to school on JS and JQuery is working for us.

Sounds like it is working swimmingly. And as if you could judge what
works and what doesn't when using jQuery. Make sure you test it in
the same browser on the same box in the same configuration right
before the presentation.
Can you recommend another library? Dojo looks like an alternative, but

It's crap and general purpose browser scripting libraries are
generally a bad idea. You might look for a simple tab script for your
prototype.
the first thing I tried worked on one browser but not others. So far

The first thing you tried? Try again. The first thing the jQuery
genius tried didn't work so hot either. He apparently quit trying
too.
JQuery has worked everywhere.

Define "everywhere." My guess is you mean everywhere you thought to
try it, which means nothing.
 
T

Thomas 'PointedEars' Lahn

dhtml said:
You are in the wrong place.
Nonsense.

http://jibbering.com/faq/#onlineResources

has links to jQuery, states:

"...
No javascript libraries are endorsed by this group.

That is not even remotely true which is why this section desperately needs
rewording or removing.
No. That's not what this group is about anyway.

Given your appearance here only shortly ago, you are not exactly in a
position to make such an assessment. Incidentally, that is why I don't
think that despite your efforts (which are appreciated) you are the best
person for the job, at least not as a single FAQ maintainer.


PointedEars
 
K

Kenny

David said:
What do you use to edit HTML? I certainly wouldn't recommend WordPad.

I actually use the Lisp editor in Emacs mode. A little scary what
happens when I reflexively hit the keychord to compile a JS function. :)
It is bad.




Okay. For a prototype. Just realize you can't put into production
like that.

But now you are in the *very* unfortunate position of having to ask
questions of other jQuery users. Best of luck. I don't know why your
prototype has a FOUC and I don't have time to delve into it.

On Chrome and Safari it now works OK. I moved the tabbing script ahead
of everything else (it was after a lot of other JS). Timing is everything.
If it
were a basic stand-alone tab script, then maybe as it would be much
simpler to spot the mistake. See where this is going?




Sounds like it is working swimmingly. And as if you could judge what
works and what doesn't when using jQuery.

True, who knows what evil lurks, but aside from IE behaving badly (we
did not have time to diagnose and just went with Chrome / Safari) the
way I judge is that I have yet to get an IR and there has been quite a
bit of use along the way. Management is thrilled with it and the rapid
development made possible by me using JQuery (and Lisp and Franz
WebActions). The scary thing is a month ago I had never programmed a web
app before. Now I have survived two rounds of layoffs and I am the
junior guy (tenure, not age).

ie, It is working for us.
Make sure you test it in
the same browser on the same box in the same configuration right
before the presentation.
Yep.



It's crap and general purpose browser scripting libraries are
generally a bad idea. You might look for a simple tab script for your
prototype.

Straight JS/HTML? Ok, I'll keep an open mind on the next whiz-bang they
ask for.
The first thing you tried? Try again. The first thing the jQuery
genius tried didn't work so hot either. He apparently quit trying
too.




Define "everywhere." My guess is you mean everywhere you thought to
try it, which means nothing.

IE, Safari, FireFox, and Chrome. Safari and FireFox on both XP and OS X.

Thanks for a good laugh, guys. I respect yout passion.

kenny
 
D

David Mark

I actually use the Lisp editor in Emacs mode. A little scary what
happens when I reflexively hit the keychord to compile a JS function. :)









On Chrome and Safari it now works OK. I moved the tabbing script ahead

Those are more or less the same, despite the different JS engines
(Chrome's is supposed to much faster.)
of everything else (it was after a lot of other JS). Timing is everything..

*Not* timing. Order.
True, who knows what evil lurks, but aside from IE behaving badly (we

I do. So do a lot of people around here. Hence...
did not have time to diagnose and just went with Chrome / Safari) the
way I judge is that I have yet to get an IR and there has been quite a

Lack of an incident is no real comfort, but if it is just a
presentational prototype, then it doesn't really matter.
bit of use along the way. Management is thrilled with it and the rapid

And what do they know (other than what you tell them?)
development made possible by me using JQuery (and Lisp and Franz
WebActions). The scary thing is a month ago I had never programmed a web
app before. Now I have survived two rounds of layoffs and I am the
junior guy (tenure, not age).

That is scary.
ie, It is working for us.

Sounds more like it is working for *you* (for the moment.)

[snip]
Straight JS/HTML? Ok, I'll keep an open mind on the next whiz-bang they
ask for.

Yes, straight as opposed to crooked. An open mind is always a good
thing.
IE, Safari, FireFox, and Chrome. Safari and FireFox on both XP and OS X.

Opera? NetFront? Lynx? Your phone? See how your app looks and
works in those.
Thanks for a good laugh, guys. I respect yout passion.

The joke will be on you if you didn't listen.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,575
Members
45,053
Latest member
billing-software

Latest Threads

Top