How to click to reload datatable with new post parameters?

How to click to reload datatable with new post parameters?

clingcclingc Posts: 1Questions: 1Answers: 0

I have a table that I need to reload with different data depending on the user's click. Basically the two links will toggle between current and past events. When they click, I wish to re-fire the ajax with a parameter that will tell my code which query to use. My back end stuff is working fine, it takes whatever value I give it and gives me back the correct data. The problem is I can't seem to dynamically pass the parameter when using ajax reload.

Is this possible? I'm not sure if, when using ajax.reload(); if it will actually see that that variable's value has changed, or if all of the ajax options are already set from the initial load? Is there any way for me to dynamically change it?

http://jsfiddle.net/u20bkc8d/

Thank you!

This discussion has been closed.