• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
codeigniter and prototype

#1
[eluser]Unknown[/eluser]
Hello,

I am trying to integrate codeigniter with prototype and $this->validation->error_string comes empty after an ajax request.



function insertLocation()
{
var parameters = $('property_address').serialize(true) + '&' +
$('property_city').serialize(true) + '&' +
$('property_state').serialize(true) + '&' +
$('property_zip_code').serialize(true) + '&' +
$('land_area').serialize(true) + '&' +
$('number_parking_spaces').serialize(true) + '&' +
$('photo_land').serialize(true) + '&' +
$('mapquest').serialize(true) + '&' +

new Ajax.Request('<?= site_url();?>/define_location/verifydefinelocation',
{
method: 'post',
parameters: parameters,
onComplete: showResponse
});
}

function showResponse(originalRequest)
{
if (originalRequest.responseText == <?= SIGNAL_HANDLER_ERROR_VALIDATION; ?&gtWink {

$('define_location_status')[removed] = '<?= $this->validation->error_string; ?>';
}
else {
$('define_location_status')[removed] = originalRequest.responseText;
}

}


Ideas?


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.