ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 17th, 2004, 10:30 AM
mitulpatel mitulpatel is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Maryland
Posts: 85 mitulpatel User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Send a message via AIM to mitulpatel
hide drop-down box

I need to hide a drop down box. For a car search page, if the user selects "NEW" the mileage drop-down dissappears, but if the user selects "USED" than the mileage drop down appears. I need this on the server side, so I would be needing to use VBScript.

I need guidence...please help

Thank you
Dizzy

Reply With Quote
  #2  
Old February 17th, 2004, 10:52 AM
WisconsinGuy's Avatar
WisconsinGuy WisconsinGuy is offline
I thank you very little
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Aug 2003
Location: Milwaukee, WI
Posts: 1,028 WisconsinGuy User rank is Corporal (100 - 500 Reputation Level)WisconsinGuy User rank is Corporal (100 - 500 Reputation Level)WisconsinGuy User rank is Corporal (100 - 500 Reputation Level)WisconsinGuy User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 19 h 35 m 41 sec
Reputation Power: 9
Dop down boxes have a: style='visibility:hidden'. Do you want it to be dynamic or do you know if the box will be hidden/visible when the page is loaded?
__________________
PEACE!

Reply With Quote
  #3  
Old February 17th, 2004, 12:47 PM
mitulpatel mitulpatel is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Maryland
Posts: 85 mitulpatel User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Send a message via AIM to mitulpatel
Quote:
Originally Posted by WisconsinGuy
Dop down boxes have a: style='visibility:hidden'. Do you want it to be dynamic or do you know if the box will be hidden/visible when the page is loaded?


I know that it has to be only on the USED page. If u click on the NEW tab the drop down should dissappear, because logically, NEW cars dont have mileage on it.

Here is the link I am working on, hopefully that will make it easier for you to help me.

http://www.fitzmall.com/carfind/res...NEW&search=USED

This link is for USED, so the drop down should appear on this page, but if you click on the NEW tab, the drop down should dissappear.

Thanks alot...I owe you one

Reply With Quote
  #4  
Old February 17th, 2004, 01:54 PM
mpearce's Avatar
mpearce mpearce is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: NewHampshire, USA
Posts: 416 mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 19 h 30 m 44 sec
Reputation Power: 9
Send a message via AIM to mpearce
Hi,
You could disable the select when new is selected.

Something like this.

<%
Dim disabled
If newselected then
disabled = "disabled"
else
disabled = ""
End if
%>
<select name="mileage" <%=disabled%>>
.
.
.



Or..

If newselected then
%>
<select name="mileage" disabled>
<%
else
%>
<select name="mileage">
<%
End if

Hope this is what you are looking for.

Mark P.
__________________
Mark Pearce

Last edited by mpearce : February 17th, 2004 at 02:03 PM.

Reply With Quote
  #5  
Old February 17th, 2004, 02:08 PM
mitulpatel mitulpatel is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Maryland
Posts: 85 mitulpatel User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Send a message via AIM to mitulpatel
Here is the piece of code...

Here is the piece of code I have to disable/hide:


<form name="MileSearch" method="post">

<% ' =============================================== MILEAGE RANGE =============================================================== %>

<%
cSQL = "SELECT distinct miles FROM inventory ORDER BY miles asc"
set oRS = oConn.Execute(cSQL)
'Response.Write "<br>" & cSQL
%>
<%'IF SearchType="USED" THEN MileSearch.Visible=True ELSE MileSearch.Visible=False END IF%>

<select name="lstMile" size="1" onChange="GoMile()">
<%
Response.Write "<option " & mileRange("0") & " value='**'>-ALL MILEAGE-"

FOR mile = 10 to 100 step 10
IF (mile * 1000) > UMAX THEN exit FOR
Response.Write "<option value='" & mile & "'" & mileRange(mile) & ">Up to " & mile & ",000"
NEXT
%>
</select>
<br><br>
</form>

Reply With Quote
  #6  
Old February 17th, 2004, 02:21 PM
mpearce's Avatar
mpearce mpearce is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: NewHampshire, USA
Posts: 416 mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level)mpearce User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 Days 19 h 30 m 44 sec
Reputation Power: 9
Send a message via AIM to mpearce
Then why not something like this?

<% ' =============================================== MILEAGE RANGE =============================================================== %>
<%
IF SearchType="USED" THEN

cSQL = "SELECT distinct miles FROM inventory ORDER BY miles asc"
set oRS = oConn.Execute(cSQL)
'Response.Write "<br>" & cSQL
%>
<form name="MileSearch" method="post">

<select name="lstMile" size="1" onChange="GoMile()">
<%
Response.Write "<option " & mileRange("0") & " value='**'>-ALL MILEAGE-"

FOR mile = 10 to 100 step 10
IF (mile * 1000) > UMAX THEN exit FOR
Response.Write "<option value='" & mile & "'" & mileRange(mile) & ">Up to " & mile & ",000"
NEXT
%>
</select>
<br><br>
</form>
<%
End if
%>

Reply With Quote
  #7  
Old February 17th, 2004, 02:43 PM
mitulpatel mitulpatel is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2003
Location: Maryland
Posts: 85 mitulpatel User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Send a message via AIM to mitulpatel
Nevermind---i Got It

I GOT IT!! All i had to do was incase the select tag inside an IF statement.

Thanks for your help...I will definately need the code u provided me for later searches.

Thanks

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > hide drop-down box


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump



 Free IT White Papers!
 
How to Present Effectively Online
This white paper offers practical and actionable advice on the key steps that any presenter should consider as they plan and execute a Webinar or online meeting.

 
Open Source Security Myths
Open Source Software (OSS) is computer software whose source code is available to the general public with relaxed or non-existent intellectual property restrictions (or arrangement such as the public domain), and is usually developed with the input of many contributors.

 
Power and Cooling Capacity Management for Data Centers
This paper describes the principles for achieving power and cooling capacity management.

 
Scalable, Fault-Tolerant NAS for Oracle - The Next Generation
For several years NAS has been evolving as a storage alternative for Oracle databases, and for good reason: NAS is quite often the simplest, most cost-effective storage approach for Oracle. Learn about the benefits that HP's approach to scalable NAS brings to Oracle environments in this comprehensive white paper.

 
Understanding Web Application Security Challenges
This white paper discusses many common threats and preventive measures for Web application security, and explains what you can do to help protect your organization.

 

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2009 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway
Stay green...Green IT