Advertisement

04.07.2008 at 12:11PM PDT, ID: 23302363
[x]
Attachment Details

DIV visibility issue

Asked by YZlat in Active Server Pages (ASP)

Tags: ASP

I have an asp page with a select box on it with 16 options in this select box.

Also I have 16 DIVs on the page, all hidden. Each div contains an include file with a number of controls on it. Each DIV style property display set to none. I also have a javascript function that sets display style to block to make div visible.

That parts works fine.

I also have a page called teast2_preview.asp that my page posts to.

On test2_preview.asp I also have 16 DIVs that are not visible. And depending on which option was selected on my original page, one of the DIVs becomes visible and retrieves the data from original page.

It works great if option 1 through 9 are selected. If I select options 10 through 16, nothing is displayed. I viewed the source of the page and it does changes DIV's display style to block, but for soem reason the DIV is still not visible.

COuld someone help?


Here is the code for both original page and page it posts to:

Start Free Trial
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:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
150:
151:
152:
153:
154:
155:
156:
157:
158:
159:
160:
161:
162:
163:
164:
165:
166:
167:
168:
169:
170:
171:
172:
173:
174:
175:
176:
177:
178:
179:
180:
181:
182:
183:
184:
185:
186:
187:
188:
189:
190:
191:
192:
193:
194:
195:
196:
197:
198:
199:
200:
201:
202:
203:
204:
205:
206:
207:
208:
209:
210:
211:
212:
213:
214:
215:
216:
217:
218:
219:
220:
221:
222:
223:
224:
225:
226:
227:
228:
229:
230:
231:
232:
233:
234:
235:
236:
237:
<FORM name="form1" action="test2_preview.asp" method="post" ID="form1">
	<table>
	<TR>											
		<TD class="BlackText11" width="80%">
														
		<SELECT id="lstProcedure" onchange="javascript:DisplayProcedurePage();" name="lstProcedure">
				<OPTION value="" selected>Select Procedures</OPTION>
				<OPTION value="pform1">1. Test1</OPTION>
				<OPTION value="pform2">2. Test2</OPTION>
				<OPTION value="pform3">3. Test3</OPTION>
				<OPTION value="pform4">4. Test4</OPTION>
				<OPTION value="pform5">5. Test5</OPTION>
				<OPTION value="pform6">6. Test6</OPTION>
				<OPTION value="pform7">7. Test7</OPTION>
				<OPTION value="pform8">8. Test8</OPTION>
				<OPTION value="pform9">9. Test9</OPTION>
				<OPTION value="pform10">10. Test10</OPTION>
				<OPTION value="pform11">11. Test11</OPTION>
				<OPTION value="pform12">12. Test12</OPTION>
				<OPTION value="pform13">13. Test13</OPTION>
				<OPTION value="pform14">14. Test14</OPTION>
				<OPTION value="pform15">15. Test15</OPTION>
				<OPTION value="pform16">16. Test16</OPTION>
		</SELECT>
		</TD>
	</TR>
	<tr>
	<td>
	<DIV id="proc_content">
				<div id="pform1" style="display: none;">
				<!--#include file="pform1.asp"-->
				</div>
				<div id="pform2" style="display: none;">
				<!--#include file="pform2.asp"-->
																	
				</div>
				<div id="pform3" style="display: none;">
				<!--#include file="pform3.asp"-->
				</div>
				<div id="pform4" style="display: none;">
				<!--#include file="pform4.asp"-->
				</div>
				<div id="pform5" style="display: none;">
				<!--#include file="pform5.asp"-->
				</div>
				<div id="pform6" style="display: none;">
				<!--#include file="pform6.asp"-->
				</div>
				<div id="pform7" style="display: none;">
				<!--#include file="pform7.asp"-->
				</div>
				<div id="pform8" style="display: none;">
				<!--#include file="pform8.asp"-->
				</div>
				<div id="pform9" style="display: none;">
				<!--#include file="pform9.asp"-->
				</div>
				<div id="pform10" style="display: none;">
				<!--#include file="pform10.asp"-->
				</div>
				<div id="pform11" style="display: none;">
				<!--#include file="pform11.asp"-->
				</div>
				<div id="pform12" style="display: none;">
				<!--#include file="pform12.asp"-->
				</div>
				<div id="pform13" style="display: none;">
				<!--#include file="pform13.asp"-->
				</div>
				<div id="pform14" style="display: none;">
				<!--#include file="pform14.asp"-->
				</div>
				<div id="pform15" style="display: none;">
				<!--#include file="pform15.asp"-->
				</div>
				<div id="pform16" style="display: none;">
				<!--#include file="pform16.asp"-->
				</div>
				</DIV>
	</td>
	</tr>
	
	</table>
	<br>
	<INPUT class="Button" type="submit" value="Submit This Form" name="btnSubmit" ID="btnSubmit">
</form>
and here is test2_preview.asp:
 
<%@ Language=VBScript %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
	<HEAD>
		<title>preview</title>
		<meta name="GENERATOR" content="Microsoft Visual Studio .NET 7.1">
		<meta name="CODE_LANGUAGE" content="Visual Basic .NET 7.1">
		<meta name="vs_defaultClientScript" content="JavaScript">
		<meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5">
 
</HEAD>
	<body MS_POSITIONING="GridLayout">
<TABLE ID="Table1">
	<TR>
		<TD valign="top">
		<DIV id="proc_content">
	
										<div id="pform1" style="display: 
										<%
										
										if Request.Form("lstProcedure") = "pform1" then 
												response.write "block;"
										else
											response.write "none;"
										end if%>">
																	<!--#include file="pform1_preview.asp"-->
																	
																	</div>
																	<div id="pform2" style="display:<% if Request.Form("lstProcedure") = "pform2" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform2_preview.asp"-->
																	
																	</div>
																	<div id="pform3" style="display:<% if Request.Form("lstProcedure") = "pform3" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform3_preview.asp"-->
																	</div>
																	<div id="pform4" style="display:  <% if Request.Form("lstProcedure") = "pform4" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform4_preview.asp"-->
																	</div>
																	<div id="pform5" style="display: <% if Request.Form("lstProcedure") = "pform5" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform5_preview.asp"-->
																	</div>
																	<div id="pform6" style="display:  <% if Request.Form("lstProcedure") = "pform6" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform6_preview.asp"-->
																	</div>
																	<div id="pform7" style="display: <% if Request.Form("lstProcedure") = "pform7" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform7_preview.asp"-->
																	
																	</div>
																	<div id="pform8" style="display: <% if Request.Form("lstProcedure") = "pform8" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform8_preview.asp"-->
																	
																	</div>
																	<div id="pform9" style="display: <% if Request.Form("lstProcedure") = "pform9" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform9_preview.asp"-->
																	</div>
																	<div id="pform10" style="display:  <% if Request.Form("lstProcedure") = "pform10" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform10_preview.asp"-->
																	</div>
																	<div id="pform11" style="display: <% if Request.Form("lstProcedure") = "pform11" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform11_preview.asp"-->
																	</div>
																	<div id="pform12" style="display:  <% if Request.Form("lstProcedure") = "pform12" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform12_preview.asp"-->
																	</div>
																	
																	<div id="pform13" style="display: <% if Request.Form("lstProcedure") = "pform13" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform13_preview.asp"-->
																	</div>
																	<div id="pform14" style="display: <%if Request.Form("lstProcedure") = "pform14" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform14_preview.asp"-->
																	</div>
																	<div id="pform15" style="display:<%if Request.Form("lstProcedure") = "pform15" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform15_preview.asp"-->
																	</div>
																	<div id="pform16" style="display:  <% if Request.Form("lstProcedure") = "pform16" then 
																	response.write "block;"
																	else
																	 response.write "none;"
																	 end if%>">
																	<!--#include file="pform16_preview.asp"-->
																	</div>							
																	
					</DIV>
				
		</TD>
	</TR>
	
</TABLE>
	
<br>
 
</BODY>
</HTML>
 
 
[+][-]04.07.2008 at 12:37PM PDT, ID: 21299881

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 01:01PM PDT, ID: 21300082

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 01:19PM PDT, ID: 21300204

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 01:29PM PDT, ID: 21300293

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 01:40PM PDT, ID: 21300371

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 01:44PM PDT, ID: 21300396

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.07.2008 at 06:29PM PDT, ID: 21301888

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.08.2008 at 08:51AM PDT, ID: 21306459

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.08.2008 at 01:12PM PDT, ID: 21309104

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.08.2008 at 01:17PM PDT, ID: 21309151

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.08.2008 at 01:19PM PDT, ID: 21309174

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.08.2008 at 01:23PM PDT, ID: 21309208

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zone: Active Server Pages (ASP)
Tags: ASP
Sign Up Now!
Solution Provided By: YZlat
Participating Experts: 2
Solution Grade: B
 
 
[+][-]04.08.2008 at 01:46PM PDT, ID: 21309433

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.09.2008 at 08:39AM PDT, ID: 21316053

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.09.2008 at 03:53PM PDT, ID: 21319940

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.11.2008 at 07:36PM PDT, ID: 21339600

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628