change VAT price with radio button using jquery and php without reloading
<p>I'm not sure if I am making this more complex then what it is... What I want to do: depending on which button the user presses $price should be calculated and displayed without the page beeing reloaded. The $price variable gets its data from a database. I cannot get this to work so if someone could help me would be fantastic, thanks linda</p>

<p>my form</p>

<pre><code>&lt;form id="f1" method="POST"&gt;
&lt;label for="r1"&gt;Exkl. moms&lt;/label&gt;&lt;input type="radio" name="radio" value="exkl" checked="checked" id="r1"/&gt;    
&lt;label for="r2"&gt;Inkl. moms&lt;/label&gt;&lt;input type="radio" name="radio" value="inkl" id="r2"/&gt;   
&lt;/form&gt;
&lt;div id="results"&gt;&lt;/div&gt;
&lt;?php
if(($_SESSION['user_info']['moms'])=="inkl"){
$price*1.25;
}
?&gt;
</code></pre>

<p>jquery</p>

<pre><code>function showValues() {
  var str = $("#f1").serialize();
     $.ajax({
  type: "POST",
  url: "momsTest2.php",
  data: str,
  success: function(html){
     $('#results').html(html);
  }
});
}
$(":radio").change(showValues);
showValues();
</code></pre>

<p>momsTest2.php page</p>

<pre><code>session_start();
$_SESSION['user_info']['moms'] = $_POST['radio'];
</code></pre>
