Question: I am trying to use jQuery to find `<td>`s with given content (text) inside. For example:

<http://sotkra.com/btol/index.php>

From left to right, the 7th COLUMN that reads 'TIPO MONEDA' displays either PESOS or DOLARES. I'd like to be able to do the following:

1. Select `<td>`s with the text 'DOLARES' or 'PESOS' and add a class to them.
2. Select `<td>`s with the text 'DOLARES' or 'PESOS' and add a class to their parent `<tr>`s.

For #1, I tried with this:

```
$('td[innerHTML=Dolares]').addClass('highlight');

```

and also

```
$('td[html=Dolares]').addClass('highlight');

```

Neither of which worked.

Answer: 
Looking at the [jQuery selector reference](http://docs.jquery.com/Selectors), I don't think  

`$('td[innerHTML=Dolares]')` and  

`$('td[html=Dolares]')` is going to work.

I can only think of iterating through all the TDs and check the `$(tdselector).html()` content.

You can try `contains("Dolares")` as suggested by tvanfosson though. It works for your case as it's highly unlikely you will have "xxDolaresxx" in other TDs.
You're very close, just missing some ticks around the value in your selector. This should work:

```
$("td[innerHTML='Dolares']").addClass('highlight');

```

And, for the parent selector:

```
$("td[innerHTML='Dolares'][innerHTML='Pesos']").parent().addClass('someClass');

```