We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
it is found that .eq(index) selector works well as a outer selctor ,but not in filter string. Below is test function
def test_a(): s = ''' <html> <div id='ip_list'> <tr> <td>1</td> <td>2</td> <td>3</td> <td>4</td> <td>5</td> <td>6</td> </tr> <tr> <td>1</td> <td>2</td> <td>3</td> <td>4</td> <td>5</td> <td>6</td> </tr> </div> <html> ''' from pyquery import PyQuery as pq print() print(pq(s)('#ip_list tr').eq(0)) # works fine print(pq(s)('#ip_list tr').filter(':eq(0)')) #does not work print(pq(s)('#ip_list tr').filter(':eq(0), :eq(1)')) #does not work either
The text was updated successfully, but these errors were encountered:
I love to use pyquery to do html work, I have the same question, and it's still not working now.
pyquery
Sorry, something went wrong.
Maybe the translation isn't correct https://github.com/gawel/pyquery/blob/master/pyquery/cssselectpatch.py#L367
No branches or pull requests
it is found that .eq(index) selector works well as a outer selctor ,but not in filter string.
Below is test function
The text was updated successfully, but these errors were encountered: