datarecall 0 Posted January 14, 2011 Report Share Posted January 14, 2011 I cant seem to get this to chose properly, been messing with it for 4 hours now :| Chose by attribute : inner htmlsearch string : /<INPUT class=fb_token_hidden_input value=[A-Z][A-Z] type=hidden name=UIAdTargeting_CountriesTokenizer_[0-9a-z]+\[\]>/immethod: regex inner html: <INPUT class=fb_token_hidden_input value=CA type=hidden name=UIAdTargeting_CountriesTokenizer_c4d3095647a7df1536619327[]>Canada<SPAN class=x onmouseover="CSS.setClass(this, 'x_hover');" onmouseout="CSS.setClass(this, 'x');" onclick="this.parentNode.parentNode.parentNode.parentNode.parentNode.token.remove(true); event.cancelBubble=true; return false;" value="Ireland"> </SPAN> then i just havechange chosen attribute:valuenew value: AU Quote Link to post Share on other sites
MiriamMB 63 Posted January 14, 2011 Report Share Posted January 14, 2011 I cant seem to get this to chose properly, been messing with it for 4 hours now :| Chose by attribute : inner htmlsearch string : //immethod: regex inner html: Canada then i just havechange chosen attribute:valuenew value: AU Could you add a script with the website with the elements you are trying to choose? Just a short script demonstrating all that just so I know what I'm working with and i can make changes to your regex if needed. thanks Quote Link to post Share on other sites
datarecall 0 Posted January 14, 2011 Author Report Share Posted January 14, 2011 Could you add a script with the website with the elements you are trying to choose? Just a short script demonstrating all that just so I know what I'm working with and i can make changes to your regex if needed. thanks Hey Lilly, Really hard cause it would be next to impossible to rip this form, its pretty complex i got everything handled except adding the countries. Thoughts on what I can try ? its not choosing the element properly (the hidden input) just need to change the value of it. Thanks for your help Quote Link to post Share on other sites
MiriamMB 63 Posted January 15, 2011 Report Share Posted January 15, 2011 ok, I might need to mess with it before I ca suggest something, but can you clarify somethig for me a bit? Are you trying to fill a field with a new value or are you trying to change a certain piece of fixed html on a webpage? Just a wee bit confused about what exactly you're trying to do. Quote Link to post Share on other sites
k1lv9h 76 Posted January 15, 2011 Report Share Posted January 15, 2011 This regex seems to select <INPUT to []> masking the things that change. regex: \<INPUT class=fb_token_hidden_input value=[A-Z][A-Z] type=hidden name=UIAdTargeting_CountriesTokenizer_[0-9a-z]+\[\]> The regex simulator I used did not like the "/" in front of <INPUT. I changed it to "\".The regex simulator I used did not like the "/im" after "\]>". I just removed it.For name=UIAdTargeting_CountriesTokenizer_ you may want to add upper case character check [A-Z] just in case their web developer gets creative. Just one upper case character the regex will fail to make a match. HTHKevin 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.