este es el codigo html
Código HTML:
Ver original <?php
for($v=0;$v<6;$v++)
{
?>
<div class="box" style="width: 800px; height: 250px; background: #FFFF66"> <form name="testform<?php echo $v?>" action="" id="ftest">
<input name="textN<?php echo $v?>" value="
<?php echo $v."dsdsf"?>" type="text"/>
<br> <input name="textA<?php echo $v?>" value="test" type="text"/>
<br> <?php
}
?>
<div id='area_botton'><a href="#" id="upda">Update App
</a></div> <input name="previous" id="previous" type="button" value="Previous" /> <input name="next" id="next" type="button" value="Next" />
aqui el codigo javascript
Código Javascript
:
Ver originalvar bValid = true;
allFields.removeClass( "ui-state-error" );
bValid = bValid && checkValue( textN, "Ther");
bValid = bValid && checkValue( textA, "Proc");
var TempArray = dd.toString();
var sValueT = document.pUpdate.textN.value
var sValueP = document.pUpdate.textP.value
var url = location.href
if ( bValid ) {
tips
.text( "* fields are required." )
$.ajax({
type: "GET",
url: "Main/P/p_ajax.php",
data: "op=3&therCod="+sValueT+"&proCod="+sValueP+"&desc="+sValueD+"&date="+TempArray,
success: function(Uerror1)
{ alert(Uerror1);
if(Uerror1!=0)
{
$( "#dialogo-error" ).dialog( "destroy" );
$( "#dialogo-error" ).html("<table><tr><td><img src='images/delete32.png' /></td><td>This day ("+error+ ") have an app</td></tr></table>");
$( "#dialogo-error" ).dialog({
resizable: false,
height:150,
modal: true,
show: 'drop',
buttons: {
"Close": function() {
$( this ).dialog( "close" );
}
}
});
}
else if(Uerror1==0)
{
window.location=url;
}
}
});//ajax
}
codigo php
Código PHP:
Ver original$temp = $app_obj->app_details_gral_p($_REQUEST['date'],$_SESSION['p_sess']);
if($app_obj->ther_p_update($_SESSION['p_sess'], $_REQUEST['therCod'], "0", $_REQUEST['date'],
$_SESSION['patient_sess'], $result_detail_p_app['ther_id'],
"0", $_REQUEST['date'], $_REQUEST['desc'], $_REQUEST['proCod']))
{
}