Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
Lightweight alternative to HTML Select tag?
Old 08-20-2007, 10:55 AM Lightweight alternative to HTML Select tag?
Junior Talker

Posts: 4
Trades: 0
Hi, I am looking for a lighter weight alternative to the HTML Select tag (i.e. dropdownlist). Here's why: I have a page that has to load hundreds (up to 500) of select boxes at once and it's taking forever to load them. I figure that the sheer number of dropdownlists that have to be rendered on the client-side is bogging the pageload down. Does anyone know of a lightweight alternative that I could use that might take less time to load up? I did find something at http://support.milonic.com/demos/sel...etSelected.htm that might work, but I'm not sure. Any alternative I implement still needs to be able to support the onchange dom event.

Thanks,
Dave Durose
ddurose is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-20-2007, 10:59 AM Re: Lightweight alternative to HTML Select tag?
JamieLewis's Avatar
Pretty Much a Big Deal...

Latest Blog Post:
Gooie
Posts: 385
Name: Jamie Lewis
Location: UK
Trades: 0
The select element is the select element. There is no lightweight alternitive, infact the example you posted would take longer to load since it is JavaScript .

I would suggest breaking up the page into a number of smaller sub pages, if that is a possibility. If you explained some more of the context behind why you need 500 select boxes at once in a site then perhaps I could suggest a viable alternative.

Jamie
__________________

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE
JamieLewis is offline
Reply With Quote
View Public Profile Visit JamieLewis's homepage!
 
Old 08-20-2007, 11:07 AM Re: Lightweight alternative to HTML Select tag?
tripy's Avatar
Do not try this at home!

Posts: 3,621
Name: Thierry
Location: I'm the uber Spaminator !
Trades: 0
500 select boxes !??

Man, learn about DOM scripting, and reduce your drop down quantity.
As Jamie said, there is nothing lighter than the native select box...

What you can face is the time needed either to load all the data (not much likely anyway, considering today pc and connectivity) or the time the browser takes to format and display all those infos, and this is most certainly where you have a problem.

Split your page in section, and make an AJAX request loading of the select you don't need to have at first on the page.
This will mostly be your only solution...
__________________
Only a biker knows why a dog sticks his head out the window.
tripy is offline
Reply With Quote
View Public Profile Visit tripy's homepage!
 
Old 08-20-2007, 11:15 AM Re: Lightweight alternative to HTML Select tag?
ADAM Web Design's Avatar
Canadastaninianite

Posts: 5,935
Name: Adam for web page design, not program
Location: Toronto, Ontario, Canada
Trades: 0
The only thing I can think of that might help you is to load only the row(s) of dropdown lists that you need at the time, and cycle through them using a Javascript event handler (onchange, onblur, onfocus).

Depends on ultimately what you're trying to do.
__________________

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
(my blog)


Please login or register to view this content. Registration is FREE
(with proof)
ADAM Web Design is offline
Reply With Quote
View Public Profile Visit ADAM Web Design's homepage!
 
Old 08-20-2007, 11:35 AM Re: Lightweight alternative to HTML Select tag?
Junior Talker

Posts: 4
Trades: 0
Thanks guys. I realize that it's a bad idea to try and load up 500 select boxes at once. I was handed this design by someone else and now I've got to be the "cleanup" guy and improve the performance. I like the idea of "paging" the select boxes so that I'm only showing a subset of the total number of select boxes at a time and as the user scrolls down AJAX calls happen that pull the next set of select boxes. Could anyone help me with getting started on that? I should also mentioned that I'm working with PHP files. You're right also that it'll probably take just as long to load up the javascript associated with the solution from milonic.com. I'm just trying to think of alternatives.
ddurose is offline
Reply With Quote
View Public Profile
 
Old 08-20-2007, 11:40 AM Re: Lightweight alternative to HTML Select tag?
Junior Talker

Posts: 4
Trades: 0
Trust me - I would love to not have so many darn select boxes on the page. I'm kinda limited by the design though. The client needs to be able to select 1 of 5 possible comments for each item (and there are hundreds of items). And when they change the select box, an AJAX call happens that updates their comment in the database for that item. I would love to break the pages up in subpages, but I don't think that would work based on the current design on the website. They need to be able to see everything at once.
ddurose is offline
Reply With Quote
View Public Profile
 
Old 08-20-2007, 11:42 AM Re: Lightweight alternative to HTML Select tag?
Junior Talker

Posts: 4
Trades: 0
I was just wondering if any of you guys knew of a quick and dirty alternative that would emulate a select box.
ddurose is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Lightweight alternative to HTML Select tag?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.83923 seconds with 12 queries