Welcome Guest, Not a member yet? Register   Sign In
using a link to send variables to a controller via jquery post .. how ?
#1

[eluser]winterain[/eluser]
I'm currently trying to use jquery's ajax post to send a couple of variables to a controller and then load that controller according to the variables. This is because other than using the URI to 'send' variables, this is the only other way I know, and in this case, I don't want the URI to have additional segments behind it for the resulting controller.

The problem with my ajax post request is that while it is requesting for the controller, it is not displaying the viewpage that loads from the controller unlike the prototype ajax.updater .. Can someone help me fix this to obtain the same functionality please?

Code:
$.post(base_url+"/music/test/", { ID: $id, cat: $cat });

so here's the deal,
1 - I want to load a view with extra variables via a <a > link, so no forms must be used...
2 - I don't want to append any uri segments behind that view uri to send the variables
3 - I am NOT trying to load the view in a div.

I realize the solution is probably far simpler than I'm trying to complicate it, but days of developing the other code has caused a brain freeze.. -_-

Thank you for your help, truly.




Theme © iAndrew 2016 - Forum software by © MyBB