|
The code to show the last comment is this: $("ul li:last", this).show(); you can modify that to show a different number.
You could find the number of comments and then subtract the number of comments you wanted to show plus 1 and show all comments greater than that.
I'm not sure how it would work if you had less comments than the number you wanted to show. It's possible that the script could break if you tried to show comments greater than a negative value so there might need to be some checking to show all comments if the number you want to show is equal or more.
|