Jump to content
UBot Underground

How To Check For Presence Of Text?


Recommended Posts

So I need to check the presence of some text on a page. What's the best way to do this?

 

What I've done is: set a variable (error_message) & scrape attribute (it picks up the error message ok). Do I use the IF command after I set up the variable? I tried inputting the var into IF, but nothing happens. Is this the best way to check the presence of some text?

 

Thanks.

Link to post
Share on other sites

alert($contains($document text,"some text"))
alert($contains($scrape attribute(<tagname="body">,"innertext"),"some text"))
Link to post
Share on other sites

Try this

if($exists(<innertext="We've done everything we can to make UBot Studio as easy to learn as possible">)) {
    then {
    }
    else {
    }
}

OR 

 

if($contains($document text,"We\'ve done everything we can to make UBot Studio as easy to learn as possible")) {
    then {
    }
    else {
    }
}

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...