> When calling an AJAX function with the POST method, there is no way
> for me to edit the GET fields of the URL because they are incorrectly
> passed as POST.
>
> I would like to use this follow URL structure in my ajax requests:
> url: 'myfunction.php?fooBar'
> method: 'POST'
>
> But through firebug I can see that "myfunction.php" is being called
> and "fooBar" is instead passed as one of the post variables (with no
> value).
Are you looking at the Firebug console's "Post" tab? Here's my test:
<html><head>
<script type="text/javascript" src="jquery-1.2.1.js"></script>
<script type="text/javascript">
$(function() {
$('a').click(function() {
$.post('wait.php?foobar', { param1: 'value1'});
return false;
});
});
</script></head>
<body>
<div><a href="#">click here</a></div>
</body></html>
Firebug Console:
POST http://localhost/j/malsup/block/wait.php?foobar (2000ms)
Firebug Console Post tab:
param1 value1
Mike