Jump to content

Recommended Posts

im building function for delete rows from sql but im stuck on early stage of it and unable to solve it

 

error msg in firebug console

ReferenceError: ajaxDelete is not defined

ajaxDelete(5, "stroj", "stroj_ID");

parametars that i get in console are correct, but i cant get that alert("works")

 

code where i call function

<td><a style="cursor:pointer;" onclick="ajaxDelete('.$stroj['stroj_ID'].', \'stroj\', \'stroj_ID\');" >Deletei</a></td>

 

- jquery is included

- it is not part of document ready functions (same results if its inside of it)

//delete universal
function ajaxDelete(id, tablica, tablica_col){
$.post("ajax/ajaxDelete.php", {id: id, tablica: tablica, tablica_col: tablica_col}, function(data){
alert("works");
});
};//endof delete universal

Link to comment
https://forums.phpfreaks.com/topic/273311-another-reference-erroe/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.