SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Guru deepM's Avatar
    Join Date
    Dec 2007
    Location
    India
    Posts
    705
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    page taking time to load with jquery

    Hello,

    I was trying to build up some modules with jquery. but it seems i found out that it takes a time to load the page as comapair to the earlier time. i was trying to build up login form using thick box. and i have done with that. but i have seen that it take lot of time to load the page. then i tried slider format. like once user clicks on login link hidden text boxes of username and passwords would be shown to fill it up. but still this jquery also takes time to load the page.

    so my questions are -
    1) why it takes time to load the page?

    2) but i have seen some sites like digg.com where if we clicks before the page is getting loaded completely still the thick box open up there. i mean how can we do that?

    3)which code is loaded first php or jquery?

    please can anyone tell me briefly, how can i optimize my code so page ll be loaded in few seconds?

    thanks in advance.

  2. #2
    SitePoint Wizard bronze trophy
    Join Date
    Jul 2008
    Posts
    5,757
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    php is a serverside language, so the browser never "loads" it. Your browser wouldnt know what to do with it. jquery is nothing more than javascript.
    http://www.sitepoint.com/article/adv...design-primer/
    http://developer.yahoo.com/performance/

  3. #3
    SitePoint Guru deepM's Avatar
    Join Date
    Dec 2007
    Location
    India
    Posts
    705
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by crmalibu View Post
    php is a serverside language, so the browser never "loads" it. Your browser wouldnt know what to do with it. jquery is nothing more than javascript.
    I agree with you.
    i think this article ll tell me what i really want to know is. i am reading it. any further query ll be back here soon.

    thanks for your reply

  4. #4
    SitePoint Wizard frank1's Avatar
    Join Date
    Oct 2005
    Posts
    1,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i dont think you are using 56kb whole jquery package rather than jquery.min.js which is around 25 kb only...

    what is jquery effect you are using?
    some effects are heavy in itself,like drag and drop

    Those js files can be compressed....

    One another technique used by some others is,get the basic jquery from google code base....they have server in many places...so will be faster...

    some big sites are based on cdn so it may be fast despite being heavy and some uses Cache

    and it is not proven but some jquery effects seems to go wild when used with php esp slide effects with big images...and only good for static content...
    i have seen one slide with start and stop crash the browser when we get images using php....
    so,hope some point may help
    thanks

  5. #5
    SitePoint Guru deepM's Avatar
    Join Date
    Dec 2007
    Location
    India
    Posts
    705
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    crmalibu,

    kevin yanks article was good. but it does not mentioned that how to minimize your loading time if you are using jquery or external JS?

    and i also found that while using IE, page gets loaded easily or immediately but it takes time while using firebox.

    can anyone please explain how can i reduce my loading time if i am using jquery?

  6. #6
    SitePoint Guru deepM's Avatar
    Join Date
    Dec 2007
    Location
    India
    Posts
    705
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    thanks for your reply frank1

    what is jquery effect you are using?
    I am using show/hide login panel using mootools.

    you can see this link.

    http://web-kreation.com/index.php/aj...g-mootools-12/


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •