在不使用表单标记的情况下将文本字段的值发送到另一个窗口 [英] sending value of a textfield without using form tag to another window

查看:77
本文介绍了在不使用表单标记的情况下将文本字段的值发送到另一个窗口的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



有文本字段和按钮....现在我必须将此文本字段值发送到另一页而不使用表单标签......我必须使用javescript。 ..有没有人可以帮我解决这个问题...?...再见

Hi
there is text field and a button.... now i have to send this textfield value to another page without using form tag......i have to use javescript... is there anyone who can help me regarding this problem...?... bye

推荐答案

我正在使用这个代码.....当我点击在按钮上文本字段值出现在文本框中..没有使用表单标签.....现在任何人都可以帮助我将此值发送到asp页面......使用javescript ...实际上我不想使用表格标签..


这是代码............


< html>

< head>

< title> Untitled Document< / title>

< meta http-equiv =" Content-Type"含量=" text / html的; charset = iso-8859-1">

< script>

函数submitSearch(){

alert(document.getElementById(' 'searchString'')。值e);

}

< / script>


< / head>


< body>


< table>

< td width =" 140">< input type =" text"名称= QUOT; searchString的" ID = QUOT; searchString的"类= QUOT; smallFont" style =" width:135px;" />< / TD>

< td width =" 25" align =" right">< input type =" submit"名称= QUOT;搜索按钮" ID = QUOT;搜索按钮"的onclick = QUOT; submitSearch()" />< / td>

< / table>


< / body>

< / html>
i am using this code ..... when i click on button the textfield value is appeared in a textbox.. without using form tag..... now anyone can help me to send this value to an asp page......using javescript... actually i dont want to use form tag..

Here is the code............

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script>
function submitSearch() {
alert(document.getElementById(''searchString'').valu e);
}
</script>

</head>

<body>

<table>
<td width="140"><input type="text" name="searchString" id="searchString" class="smallFont" style="width: 135px;" /></td>
<td width="25" align="right"><input type="submit" name="searchButton" id="searchButton" onclick="submitSearch()" /></td>
</table>

</body>
</html>


嗨!

i可以在javescript函数中获取文本字段值.....不使用表单标签...现在任何人都可以帮我将这个javascript值发送到另一个页面...再见
Hi!
i can get the textfield value in a javescript function ..... without using form tag... now anyone can help me to send this javascript value to another page...Bye





将文本字段值放在cookie中


document.cookie = escape(value)

for在其他asp页面中获取值然后在身体的onload函数中

ie< body onload =" getvalue();">

< script>

函数getvalue()

{

var value = unescape(value);

}

< / script>

如果你想要任何参考资料

http://echoecho.com/jscookies.htm




place the textfield value in the cookie

document.cookie = escape(value)
for getting value in other asp page then in onload function of the body
ie <body onload="getvalue();">
<script>
function getvalue()
{
var value=unescape(value);
}
</script>
if u want any references the go to

http://echoecho.com/jscookies.htm




嗨!

i可以在jave中获取文本字段值脚本功能.....不使用表单标签...现在任何人都可以帮我将这个javascript值发送到另一个页面... Bye
Hi!
i can get the textfield value in a javescript function ..... without using form tag... now anyone can help me to send this javascript value to another page...Bye


这篇关于在不使用表单标记的情况下将文本字段的值发送到另一个窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆