Open URL based on current URL

I would like to after opening an URL (manually), open another one in another tab based on that one.

Starting point:
Result URL after searching for (manually), “TP” “237” for today:
Automated URL based on this one (because I don’t always want to check it):

I thought of 2 choices:

  • Find a way for the second url to grab some variables from the 1st and join with the value grabbed from Html (“LIS”)
  • Store some variables of the first URL (like departure “LIS” and the date - although I’m not sure how could I transform “Oct” into “10”) and then go through the all process of going to the website, insert these values and then get the results (using kantu of course, not manually)

Not sure how to accomplish the 1st one at all and also not sure what would be the best approach in general.
Am I seeing this wrong?

  1. Get the current URL with the ${!url} variable

  2. Apply some Javascript and maybe regular expressions to extract the values you need from the URL. Use the execute script (sandbox) command for this.

  3. Build the new URL, and use OPEN | ${newurl}