| bio | website | |
|---|---|---|
| location | ||
| age | ||
| visits | member for | 1 year, 9 months |
| seen | Sep 4 '11 at 16:23 | |
| stats | profile views | 0 |
|
Dec 17 |
awarded | Notable Question |
|
May 11 |
awarded | Popular Question |
|
Sep 11 |
awarded | Student |
|
Aug 24 |
comment |
Selenium - Find exact text match using CSS locators I made it very clear that there is no space around Trouble. If regexp works with css, the simplified "\s*Trouble\s*" should match. Try this simple HTML code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "w3.org/TR/html4/strict.dtd" > <html lang="en"> <head> <title><!-- Insert your title here --></title> </head> <body> <div class="item"> <div class="text">Trouble</div></div> </body> </html> With Selenium IDE and see the difference: click | css=div.item > div.text:contains("Trouble") click | css=div.item > div.text:contains("\s*Trouble") |
|
Aug 24 |
comment |
Selenium - Find exact text match using CSS locators As in my original question, Firebug does not shows there is any space around Trouble. <br> It does not work and even css=div.item > div.text:contains("\s*Trouble\s*") does not work either. <br> So I would suspect if css can work together with regexp. |
|
Aug 22 |
asked | Selenium - Find exact text match using CSS locators |
|
Aug 21 |
awarded | Editor |
|
Aug 21 |
revised |
A way to match on text using CSS locators added 46 characters in body |
|
Aug 21 |
answered | A way to match on text using CSS locators |