You are browsing a tutorial guide for Octoparse's latest version. If you are running an older version of Octoparse, we strongly recommend you upgrade because it is faster, easier and more robust! Download and upgrade here if you haven't already done so!

When searching on a website, for example, Google.com, you can either click the search button after inputting a keyword or press Enter on your keyboard directly to go to the search results page. Octoparse can easily simulate the clicking action but what if the website does not have the search button to click?

This article will illustrate how Octoparse deals with the dilemma with the "press enter" function when there is no available submit button.

You will need the below URL as an example to follow through.

https://www.mazda.com.au/find-a-dealer/

https://www.allaboutincontinence.co.uk/

There are two options for jumping over functionality limitations whenever you encounter issues.

  1. Use the Press enter function in Enter Text settings

  2. Use the search keyword as a parameter to generate a new URL


1. Use the Press enter function in Enter Text settings

When opening the Mazda webpage, it is quite obvious that there is no available submit button to conduct the search after you have entered your keywords.

1.png

You will need to set the press enter function to let the system automatically press the enter key to search when executing the workflow.

  • Click on the search box to enter a keyword

3.png

You will see an Enter Text action created in the workflow.

mceclip1.png
  • Click on Enter Text action

  • Select Hit the Enter/Return key when finishing entering

  • Set appropriate timeout

  • Set up AJAX timeouts when the website uses the AJAX technique

  • Set up scroll times when the current website requires scrolling before fully loading

settings.jpg

2. Use the search keyword as a parameter to generate a new URL

Some websites use the keyword searched as a parameter in the URL to construct new URLs. For example, the home domain of one website, https://www.allaboutincontinence.co.uk/

If you search the below keyword: id-for-men-level-3, the URL of the keyword search result is like this: https://www.allaboutincontinence.co.uk/id-for-men-level-3

You will be able to use the above URL as a starting point to set up your workflow to avoid the situation of no submit button existing on the homepage. It also saves scraping time as we don't need to enter text and click the search button.

Tip: If you need to batch generate a URL list to search a list of keywords, you can use our "Batch generate URL" function: Batch URL input

Did this answer your question?