webpro 31 Posted March 19, 2015 Report Share Posted March 19, 2015 Can we use a Wildcard in a conditional statement ?It was working before but i think it doesn't anymore. I'm trying to understand why lots of my bots aren't working anymore (scraping pages) ex:http://screencast.com/t/RvSsbTWZ Exemple:I want to click on the next page (link/button) if any.So it could look like this(you see this usually at the bottom of the pages)>>Next page Thanks Quote Link to post Share on other sites
Bot-Factory 602 Posted March 20, 2015 Report Share Posted March 20, 2015 Can we use a Wildcard in a conditional statement ?It was working before but i think it doesn't anymore. I'm trying to understand why lots of my bots aren't working anymore (scraping pages) ex:http://screencast.com/t/RvSsbTWZ Exemple:I want to click on the next page (link/button) if any.So it could look like this(you see this usually at the bottom of the pages)>>Next page Thanks Wildcards are working fine with 5.5.13 navigate("http://www.ubotstudio.com/playground/difficult-form","Wait")wait for element(<last name field>,"","Appear")change attribute(<id=w"lastna*">,"value","xxx") But in your screenshot, it looks like the text in "Element to find" is URL encoded. Did you generate that with the element slection wizard? Dan Quote Link to post Share on other sites
HelloInsomnia 1103 Posted March 20, 2015 Report Share Posted March 20, 2015 It works but you need to use the "w" so you need to edit the selector by clicking on the gear icon then change exact match to wildcard in the dropdown. Otherwise it won't work, for example: navigate("http://ubotsandbox.com/textboxes.php", "Wait") wait(2) if($exists(<id="fnam*">)) { then { alert("Wildcard no W working") } else { alert("Wildcard no W is not working") } } if($exists(<id=w"fnam*">)) { then { alert("Wildcard with W working") } else { alert("Wildcard with W is not working") } } Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.