Advertisement
Guest User

Untitled

a guest
Nov 26th, 2014
152
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. $("input").keyup(function() {
  2. $.post("../fhphp/updatetree.php",{id: $(this).closest("div").attr("id"), type:
  3. $(this).attr('name'), value: $(this).val()});
  4. });
  5.  
  6. if ($mytree!=null) {
  7. $person=$mytree->findPerson($_POST['id']);
  8. if ($person!=null) {
  9. $varFunction="change".$_POST['type'];
  10. $person->$varFunction(mysqli_real_escape_string($link,$_POST['value']));
  11. } else {
  12. $mytree->addPersonNode(new personNode($_POST['id']));
  13. }
  14. }
  15.  
  16. $mytree=new treeClass();
  17. $mytree->constructTree($_SESSION['loginusername'],$link);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement