varaibles inside success function of Ajax post...


i am having a Ajax post like

var getformid;


type: "POST",
 url: "http://localhost/FormBuilder/index.php/forms/saveForm/"+user_id,
     async: false,
data: "formname="+formname+"&status="+status,
success: function(msg){
alert( "Data Saved: " + msg);
});//ajax */

Now my Formid is saved in the getformid variable , also i alert the getformid outside success function, it shows the ID.But when i tried to use that Formid that getformid variable inside another Ajax like

          $("#fb_contentarea_col1down21 div").each(function() { 
                         alert("Form id "+getformid);
					var checked="false";	 
					var id=$(this).attr("id");
					var fsize=$("#input"+id+"").width();
					var ftype=$("#input"+id+"").attr('data-attr');
                                            var finstr=$("#instr"+id+"").text();

             var fname=$("#label"+id+"").clone().html().replace(/

Now this getformid value is not reflected inside the Second Ajax to save the Field..
Why so ???

In addition i am giving here the Code inmy Controller for saveForm

   function saveForm()




And my Model saveForms is like

  function saveForms($data)//design saveForm

	return $this->id;//returns the saved Form id to the controller 


And my save_form.ctp in my views folder is like

   <?php echo $formId;?>

Please suggest me..