Using JQuery, The below code works perfect for me:

$.post("myphpfile.php",
{
username:"Brian"

}

And even this works:

var user = "Brian";

$.post("myphpfile.php",
{
username:user

}

But I need this to work as well
(it'll end up saving me a ton of coding and help me scale my project)

var variable1 = "username";
var user = "Brian";

$.post("myphpfile.php",
{
variable1:user

}

But I can't figure out how to make javascript or jquery make that variable to the left of the colon work..
Thanks for the help in advance!