Html 如何将Google自定义搜索引擎结果重定向到results.php页面?
我创建了一个GoogleCSE,搜索框在网站主页上。当用户搜索时,它应该将结果重定向到results.php,但是,它会将结果重定向到cse.google.com/randomurl 它被设置为两页格式,所以应该没有问题。我试着在我的表格中添加一个动作,但没有成功Html 如何将Google自定义搜索引擎结果重定向到results.php页面?,html,google-custom-search,Html,Google Custom Search,我创建了一个GoogleCSE,搜索框在网站主页上。当用户搜索时,它应该将结果重定向到results.php,但是,它会将结果重定向到cse.google.com/randomurl 它被设置为两页格式,所以应该没有问题。我试着在我的表格中添加一个动作,但没有成功 <form class="form-inline" action="results.php" method="POST"> <div class="md-form my-0"> <script
<form class="form-inline" action="results.php" method="POST">
<div class="md-form my-0">
<script async src="https://cse.google.com/cse.js?cx=983049830948390:lxzkzf8ljowm"></script>
<div class="gcse-searchbox-only"></div>
</div>
</form>
*为了匿名起见,我在这个问题中修改了我的自定义搜索引擎URL。显示如下:
<div class="gcse-searchbox-only" data-resultsUrl="YOUR_RESULTS_PAGE_URL"></div>
你有:
<div class="gcse-searchbox-only"></div>
图中是这样显示的:
<div class="gcse-searchbox-only" data-resultsUrl="YOUR_RESULTS_PAGE_URL"></div>
你有:
<div class="gcse-searchbox-only"></div>