ここに私が開発しているサイトのリンクがあります
http://ashteldemo.com/leonardpatel/
ページの右上にある Google カスタム検索ボックスを使用しました
誰かがクエリを書いてEnterキーを押すと、別のページまたは別のタブに結果が表示されるはずですが、同じページまたは同じタブに結果が表示されています
ここにグーグルが提供するコードがあります:
<script>
(function() {
var cx = '006011017794504203273:7s66ki24jds';
var gcse = document.createElement('script');
gcse.type = 'text/javascript';
gcse.async = true;
gcse.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') +
'//www.google.com/cse/cse.js?cx=' + cx;
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(gcse, s);
})();
</script>
<gcse:searchbox-only></gcse:searchbox-only>
検索結果を別のタブに表示したい、または