views:

153

answers:

2

I am using jeditable fairly simply and it all works fine, updates the database, etc. The only problem I have is after the user types the new value data and hits enter it doesn't update the field in the browser to show the new value - instead it puts "Click to edit..." in place of it.

Am I missing something like a return value from my php file? the php fucntion just takes the args and updates the database - and it works fine.

Enoch

the jquery\jeditable code

$('.edit').editable('update.php',{
   id: 'field',
   name: 'val',
   indicator: 'Saving...',
   tooltip: 'Click to edit...',
   select : true,
   submitdata : { db : "pers", kn : "key", rec : "?php echo $rec; ?" }
});

the div

<div class="edit" id="svc_ad1"><?php echo $row->svc_ad1; ?>< /div>

i also have a css class for pEdit

edit{    
  float:left;
  width:200px;
  height:15px;
  margin-bottom:5px;
  border-bottom:1px solid #aaaaaa;
}
A: 

Nothing like answering your questions... anyhow I figured out I was missing this from my php file:

print $_POST['val'];

Enoch
A: 

Do you perhaps know what the javascript variable for the edited field is?

Forkrul Assail