如何将信息从asp.net页传递到Google [英] how to pass information from asp.net page to google

查看:65
本文介绍了如何将信息从asp.net页传递到Google的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想将信息从asp.net的文本框传递到google页面,这将在google中搜索特定的字符串并显示结果.有谁能帮助我吗?

温馨的问候,
Arshad

i want to pass the information from a text box of asp.net to google page, which will search the specific string in google and show the result. will any one kindly help me ?

Warm Regards,
Arshad

推荐答案


在codeProject专家上获取最佳示例;
Google Like搜索文本框 [
Hi,
Get a best example on codeProject expert;
Google Like Search TextBox[^]


您好,

字符串searchstr = txtSearch.Text


hi u can get by,

string searchstr=txtSearch.Text


http://lmgtfy.com/?q=searchstr


大不了?以下代码将根据您的搜索在新页面中显示Google搜索,只需尝试
Big deal? The below code will show the Google search in new page based on your search, just try that
<html>
<head>
<title>Show search results in new window</title>
<script language="javascript" type="text/javascript">
function openwin()
{
    window.open("http://www.google.com/search.aspx?q=" + document.getElementById("txtText").value ,"NewWindow","width=500,height=500");
}
</script>
</head>
<body>
<input type="text" id="txtText">
<A href="javascript: openwin()">Search</A>
</body>
</html>


这篇关于如何将信息从asp.net页传递到Google的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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