Skip to content
New issue

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

Problem when using with jQuery 1.9.1 #4

Open
jteich opened this issue Jul 2, 2013 · 2 comments
Open

Problem when using with jQuery 1.9.1 #4

jteich opened this issue Jul 2, 2013 · 2 comments

Comments

@jteich
Copy link

jteich commented Jul 2, 2013

While using this plugin with jQuery 1.9.1, I found a problem where the code was using selectors that ended commas when it would select multiple rows as in: Uncaught Error: Syntax error, unrecognized expression: .tj_row_1,.tj_row_2,
I was able to resolve this issue by modifying the code to remove trailing commas whenever it would build the currentRows and nextRows selector strings.

@douglasmiranda
Copy link
Member

I don't get it. Why did you just use a selector ending with a comma?

Why did you not use: .tj_row_1, .tj_row_2 instead .tj_row_1, .tj_row_2,?

Or am I missing something?

@jteich
Copy link
Author

jteich commented Aug 7, 2013

Let me clarify. The problem is that the code in gridnav will try to use these selectors that end with a comma.
For example, in jquery.gridnav.js, you have a lot of lines that look similar to:
nextRows += '.tj_row_' + (config.currentRow + opts.rows + i) + ','
which leaves a trailing comma in "nextRows". The newer versions of jQuery don't like the trailing comma and cause the code to fail. as a fix, I added lines of code like so: nextRows = nextRows.substring(0, nextRows.length - 1);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants