Drop down problem

This is a discussion on "Drop down problem" within the PHP Forum section. This forum, and the thread "Drop down problem are both part of the Program Your Website category.


 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Program Your Website > PHP Forum

Notices




Reply
 
LinkBack Thread Tools
  #1  
Old Oct 11th, 2007, 09:30
New Member
Join Date: Oct 2007
Location: UK
Age: 24
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Smile Drop down problem

Hi people

Does anyone have any ideas of how i would display 6 records and give the user the option to click on a drop down menu to display all records? im using div tags and javascript, i would appreciate it if you could help?

Stuart
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Oct 11th, 2007, 10:11
Rakuli's Avatar
SuperMember

SuperMember
Join Date: Sep 2007
Location: Australia
Age: 24
Posts: 956
Blog Entries: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Drop down problem

Hi Stuart, welcome to Webforumz.

Can you explain waht you want in a bit more detail? I interpret what you're saying as something could be done with a simple HTML select box... I'm sure it's not that easy though.

Cheers,
Last Blog Entry: The wannabe juggler's quest (Oct 27th, 2007)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old Oct 11th, 2007, 10:17
New Member
Join Date: Oct 2007
Location: UK
Age: 24
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Drop down problem

Hi Rakuli

am designing a mobile phone website and we have a section called hotdeals, at the moment all the hotdeals are listed on the page, what would be good is to show 6 of the deals when the page is loaded and if the customer wants to see more deals then they click and all the deals appear. does that make more sense sorry im not sure how to explain it properly?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old Oct 11th, 2007, 10:31
Rakuli's Avatar
SuperMember

SuperMember
Join Date: Sep 2007
Location: Australia
Age: 24
Posts: 956
Blog Entries: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Drop down problem

So you're using PHP and selecting the records from a database?

You could use

PHP: Select all

$_GET['perPage'] = !empty($_GET['perPage']) && is_numeric($_GET['perPage']) ? $_GET['startFrom'] ? 6;

$_GET['startFrom'] = !empty($_GET['startFrom']) && is_numeric($_GET['startFrom']) ? $_GET['startFrom'] : 0;


$query "SELECT * FROM theTable LIMIT {$_GET['startFrom']}, $numPerPage"

// Links

echo '<a href="url.html?startFrom=0&amp;perPage=10000">Show All</a>'
This will limit the first page to 6 with a link to show all
Last Blog Entry: The wannabe juggler's quest (Oct 27th, 2007)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old Oct 11th, 2007, 10:35
New Member
Join Date: Oct 2007
Location: UK
Age: 24
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Drop down problem

could i send you my code i already have? im not sure i understand where it goes
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old Oct 11th, 2007, 10:37
Rakuli's Avatar
SuperMember

SuperMember
Join Date: Sep 2007
Location: Australia
Age: 24
Posts: 956
Blog Entries: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Drop down problem

Yeah, paste it in a message between [php ] [ /php] BBC tags.
Last Blog Entry: The wannabe juggler's quest (Oct 27th, 2007)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Thread Tools

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 On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
New to this- IE 6 drop down menu problem... rthomp87 Web Page Design 2 Jan 21st, 2008 16:27
Drop down menus drop behind flash header theGAME71135 Flash & Multimedia Forum 3 Jan 10th, 2008 09:42
XSLT Drop Down Neilson Other Programming Languages 0 May 1st, 2006 19:58
problem with css/javascript drop down menu ultimate0 Web Page Design 9 Mar 29th, 2006 14:15


All times are GMT. The time now is 16:16.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42