click specific links

Discussions and Tech Support related to the iMacros Firefox Add-on, including the built-in Javascript scripting interface for playing .js files.
Forum rules
Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the search box (at the top of each forum page) to see if a similar problem or question has already been addressed.
3. Try searching the iMacros Wiki - it contains the complete iMacros reference as well as plenty of samples and tutorials.
4. We can respond much faster to your posts if you include the following information:CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST
Post Reply
Ruriko
Posts: 126
Joined: Sat Feb 24, 2007 5:07 am

click specific links

Post by Ruriko » Sat Feb 24, 2007 5:09 am

How do I make it click on any links that being with http://blah.com/****
User avatar
Tech Support
Posts: 4948
Joined: Tue Sep 20, 2005 7:25 pm
Contact:

Post by Tech Support » Sat Feb 24, 2007 9:49 pm

You can use the asterisk * symbol:

TAG POS=1 TYPE=A ATTR=HREF:http://blah.com/*

=> This TAG command will click every URL that starts with http://blah.com/.

If POS=1 it will click the first URL that matches, if POS=2 the second url and so on. You can use a variable with the POS statement to loop over all URLs.

TAG POS={{MyLoopVar}} TYPE=A ATTR=HREF:http://blah.com/*

For example, the * is very useful to find and click links that contain session IDs. Just replace the session ID with * :)

Instead of the URL, you can also look at the link TEXT:

TAG POS=1 TYPE=A ATTR=TXT:*LinkText*
Post Reply