Results 1 to 5 of 5

Thread: Jquery library too big for website

  1. #1
    Join Date
    Mar 2014

    Jquery library too big for website

    Hey guys,

    I've got a bit of a problem that I haven't exactly come across before and I'm really hoping someone here can help.

    We're working on a Real Estate Type website for a Small Client, We've used wordpress to hold all out content together,
    The only problem we have is that there are about 20,000 drop down options. on the front end submission page. None of which can be taken away.
    The rest of the website runs fast except for the Front End Submission page and the Backend are to submit properties from the admin area.

    These 20,000 options are divided into 7 main categories. basically they select the state, then suburb.
    The website is being hosted on our server which is a shared hosting environment. We want to believe that moving the website to it's own server will help things
    but i have a reason to believe that the issue is a little more than just it's hosting environment. Is it possible to perhaps compress the Jquery files so they download to the end user a little faster?

    When you view the front end submission page it's pretty much frozen. If you're using chrome you's get a message saying the webpage isn't responding and such.
    you would need to wait about 30 seconds or more to load the page properly. even after loading everything it's still very unresponsive. if you were to scroll down a little it would take a few seconds to register before it scrolls the page down.

    Now, I know that this is a bucket load of strings. I know that. But how can we make it faster? We've already tried caching, but it's pretty useless as the end user would still experience slow and unresponsiveness on the website.

    Any idea's would be much appreciated.

  2. #2
    Join Date
    May 2006
    Somewhere behind your screen
    20,000 options - i would replace this monstrous amount of text with ajax autocompleted inputs (type="text"). this should make the page load faster.
    signature under construction

  3. #3
    Join Date
    Mar 2014
    Quote Originally Posted by Padonak View Post
    20,000 options - i would replace this monstrous amount of text with ajax autocompleter inputs (type="text"). this should make the page load faster.
    Yes I understand that this would make things faster. But what i'm trying to look for is a solution to keep things the way it is but make it faster.
    There has to be a solution for it, There are many other real estate websites with many more options that what I have, Yet they run much faster.

    Do you think Varnish would be a good solution, It seems like the same stuff other Real Estate Websites are using for their websites.

  4. #4
    Join Date
    Mar 2005
    Behind you...
    This is just a random thought (I haven't tested the functionality myself) but it seems like you could still use an AJAX solution, however if you still need to keep your <select> dropdown just as you have it on your site, you can dynamically add the values.

    Now, I haven't seen your page and how it is currently set up, but it seems there are multiple <select> dropdowns in which they select a value from the state dropdown, then can select a suburb from a second dropdown. If this is the case you could have each of your 7 categories split into separate files. This would allow you to load the data from a category as you needed it, or if anything load them in sequence to help get the page in a usable state more quickly.

    In the end, no matter how you look at it, if you have a large amount of data that needs to be loaded on to a page you are either going to load it all at once and have to wait or break the data up and understand that not all of it will be instantly available.
    "Given billions of tries, could a spilled bottle of ink ever fall into the words of Shakespeare?"

  5. #5
    Join Date
    Feb 2003
    Michigan, USA
    What is the actual slowdown on the page? Can you identify the JavaScript functions or code blocks that take the most time? If you disable JavaScript in the browser and view the page, does it perform better?

    Basically, you need to identify the actual performance problem. Is it JavaScript? Is it the shear amount of HTML that must be downloaded? Is it the backend processing time to create the page? Is it a bunch of jQuery function calls that iterate over a boatload of DOM nodes?

    Bottom line, you can't keep things as they are but make them faster. Something has to change.

    If the server is taking a long time to generate the web page, there are some easy optimizations you could make at the PHP level. The options in each dropdown are not likely to change often, so cache the Hell out of them on the server side.

    If JavaScript code is running slowly, try to identify it and optimize it. Maybe eschew jQuery for native JavaScript method calls to cut out the middle man.

    Could you post a link to the page in question?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



X vBulletin 4.2.2 Debug Information

  • Page Generation 0.09630 seconds
  • Memory Usage 2,890KB
  • Queries Executed 15 (?)
More Information
Template Usage (33):
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_global_above_footer
  • (1)ad_global_below_navbar
  • (1)ad_global_header1
  • (1)ad_global_header2
  • (1)ad_navbar_below
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)ad_thread_first_post_content
  • (1)ad_thread_last_post_content
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (5)memberaction_dropdown
  • (1)navbar
  • (5)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (5)postbit
  • (5)postbit_onlinestatus
  • (5)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available (6):
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files (26):
  • ./showthread.php
  • ./global.php
  • ./includes/class_bootstrap.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/functions_navigation.php
  • ./includes/class_friendly_url.php
  • ./includes/class_hook.php
  • ./includes/class_bootstrap_framework.php
  • ./vb/vb.php
  • ./vb/phrase.php
  • ./includes/functions_facebook.php
  • ./includes/functions_calendar.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_notice.php
  • ./packages/vbattach/attach.php
  • ./vb/types.php
  • ./vb/cache.php
  • ./vb/cache/db.php
  • ./vb/cache/observer/db.php
  • ./vb/cache/observer.php 

Hooks Called (72):
  • init_startup
  • friendlyurl_resolve_class
  • init_startup_session_setup_start
  • database_pre_fetch_array
  • database_post_fetch_array
  • init_startup_session_setup_complete
  • global_bootstrap_init_start
  • global_bootstrap_init_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • load_show_variables
  • load_forum_show_variables
  • global_state_check
  • global_bootstrap_complete
  • global_start
  • style_fetch
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • strip_bbcode
  • friendlyurl_clean_fragment
  • friendlyurl_geturl
  • forumjump
  • cache_templates
  • cache_templates_process
  • template_register_var
  • template_render_output
  • fetch_template_start
  • fetch_template_complete
  • parse_templates
  • fetch_musername
  • notices_check_start
  • notices_noticebit
  • process_templates_complete
  • friendlyurl_redirect_canonical
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • memberaction_dropdown
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • build_navigation_data
  • build_navigation_array
  • check_navigation_permission
  • process_navigation_links_start
  • process_navigation_links_complete
  • set_navigation_menu_element
  • build_navigation_menudata
  • build_navigation_listdata
  • build_navigation_list
  • set_navigation_tab_main
  • set_navigation_tab_fallback
  • navigation_tab_complete
  • fb_like_button
  • showthread_complete
  • page_templates