Jump to content
UBot Underground

Can We Use A Wildcard In A Conditional Statement ?


Recommended Posts

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

Link to post
Share on other sites

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

Link to post
Share on other sites

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")
    }
}

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...