Lemonde
  • Lemonde
  • 100% (Exalted)
  • Advanced Member Topic Starter
7 years ago
I know that this is a convuluted situation but I would like to come up with a page that shows the fist google page result - i.e. the 'i'm feeling lucky' result of a seach based on the domain name of the current URL in the browser.

So imagine I am going to have to use something like request.url.host to get the domain name into a string and then send that to the google API somehow.

I would like to do this on an IIS page without PHP if possible.

Can anyone point me towards some help as I have no idea what I'm doing but would still very much like to be able to generate the page.

Can you write a script that posts the results of the current URL as search results to the current page? So that if the domain is distributioncompanies.com the page will display a list of the search results for sending distributioncompanies to a search engine using an API or similar, so that the page will show the results of the search with only the domain being browsed as the keyword, minus the suffix?

so you would need to do a url.request to get the keywords, and then post that to a search engine API

so i can point 10 domains at that page and get a different result for each domain

ideally just show the first result page rather than the SERP as in the 'im feeling lucky' page on google and it needs to get the keywords from the url no matter the domain
Sponsor

Want to thank us? Use: Patreon or PayPal or Bitcoins: bc1q4whppe29dw77rm4kv4pln0gqae4yjnxly0dny0hky6yhnafukzjsyrsqhk

All opinions expressed within these pages are sent in by members of the public or by our staff in their spare time, and as such do not represent any opinion held by sircles.net Ltd or their partners.