Redian新闻
>
anyone can check my ASP code about pulldown menu?
avatar
anyone can check my ASP code about pulldown menu?# Database - 数据库
h*r
1
. I have a table named users. I want to set the first one as a menu list
page, once someone select a username from the drop down list, the second asp
page will retrieve information about the user from the users table, but my asp
page does not show anything. need help.
// the first html page//




avatar
h*e
2
ft, u didn't set anything for the QueryString, how can u use it?

asp

【在 h****r 的大作中提到】
: . I have a table named users. I want to set the first one as a menu list
: page, once someone select a username from the drop down list, the second asp
: page will retrieve information about the user from the users table, but my asp
: page does not show anything. need help.
: // the first html page//
:
:
:

:

avatar
h*r
3
But how to set it? pls.thanks

asp

【在 h****r 的大作中提到】
: . I have a table named users. I want to set the first one as a menu list
: page, once someone select a username from the drop down list, the second asp
: page will retrieve information about the user from the users table, but my asp
: page does not show anything. need help.
: // the first html page//
:
:
:

:

avatar
o*z
4

'try add this:
username=Request("username")
if (username <> "") then response.write username
'see what you get
'were you using 1,2... as the usernames?

【在 h****r 的大作中提到】
: But how to set it? pls.thanks
:
: asp

avatar
h*r
5
it still does not work. No, I set the username as the real name, not number.
wuwu

【在 o***z 的大作中提到】
:
: 'try add this:
: username=Request("username")
: if (username <> "") then response.write username
: 'see what you get
: 'were you using 1,2... as the usernames?

avatar
o*z
6
really? the output should be numbers
have you tried something like
test.asp?username=Lindsey

【在 h****r 的大作中提到】
: it still does not work. No, I set the username as the real name, not number.
: wuwu

avatar
k*d
7
Try this in the first page:
Should work. Good luck





avatar
h*r
8
none of them works.

number.

【在 o***z 的大作中提到】
: really? the output should be numbers
: have you tried something like
: test.asp?username=Lindsey

avatar
k*d
9
???!!!
Did you try to make some changes in the first page?
Change the values of the options to the usernames instead of numbers
Also see my TZ above

【在 h****r 的大作中提到】
: none of them works.
:
: number.

avatar
h*r
10
ya, i tried all suggestions, but none of works. that is ok. i have sent my
code to an expert of ASP. hope can solve this problem finally
thanks

【在 k*******d 的大作中提到】
: ???!!!
: Did you try to make some changes in the first page?
: Change the values of the options to the usernames instead of numbers
: Also see my TZ above

avatar
o*z
11
then i think the problem lies in your asp page
how about this?
Set objDC = Server.CreateObject("ADODB.Connection")
objdc.open "dsn=users;pwd=letmein"
sqltext="SELECT * FROM users WHERE (username = '" & request("username") &"')"
Response.Write "

"&sqltext&"
"
Set objRS=objdc.Execute(sqltext)
if NOT ...
......

【在 h****r 的大作中提到】
: none of them works.
:
: number.

avatar
h*e
12
HTML 4.0 好象不再支持这种 selected value
所以你想显示这个东西是显示不出来的
可以用onchange event来active 个javascript记录
avatar
k*d
13
Not really. Drop down box is implemented by syntax of


【在 h****e 的大作中提到】
: HTML 4.0 好象不再支持这种 selected value
: 所以你想显示这个东西是显示不出来的
: 可以用onchange event来active 个javascript记录

avatar
h*r
14
It works. hahha
the problem is very funny.
cause I set autonumber for my table records, and later i deleted the first
five records, so the autonumbre begins from 6, that is why i cannot get the
value shown up. because my option value passed to asp begins from 1 to 3.
whatever. thanks all.
btw, why do I always make this kind of stupic mistake. too careless.
在 huster (huster) 的大作中提到: 】
avatar
k*d
15
Usually, it will take 3 times longer time for debugging and maintaining the
code than writting the code. Which will let programmers always have work to do
number.
相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。