Set url in a scrapeable file?
Hi, I would like to ask if I can change the url for a scrapeable file.
For example, I scrape a site www.example.com which requires login.
But after logging in the site's url changes to www21.example.com.
I'm searching a way to put the number in the scrapeable's file url field, because this number changes everytime you log in the site
URL editing
Leondo,
On a scrapeable file under the properties tab you should see the URL field. Typically it has a line like: http://www.example.com/myexample.htm. However you can replace pieces of this URL with session variables like this: http://www~#NUMBER#~.example.com/myexample.htm. If you insert a session variable into the middle of the URL string then screen-scraper will recognize that variable and insert the appropriate "21" or other number.
Now all you need to do is find out where that number is coming from so you can scrape it and put it into a session variable.
Best of luck
Rich
Session variables in url
Session variables can be used in the url field. For example you put ~#SITE_URL#~ into the url field where you have saved a session variable named SITE_URL. You could also just have part of the site url as a session variable so in your example you could use www~#NUMBER#~.example.com, where you have saved number as a session variable.