Ibshas25 Posted December 1, 2010 Share Posted December 1, 2010 where do i add this gif for it to work. currently i added it to the actually add button but doesnt seem to work... any ideas function useradd() { alert ("user add a geliyor"); //alert ("team add a geliyor"); var username = $("#username").attr("value"); var name = $("#name").attr("value"); var surname = $("#surname").attr("value"); var passwd1 = $("#passwd1").attr("value"); var email = $("#email").attr("value"); var phone = $("#phone").attr("value"); var mobphone = $("#mobphone").attr("value"); var issysadmin = $("#issysadmin").attr("value"); var isuseractive = $("#isuseractive").attr("value"); var data = { "operation" : "useradd", "username" : username, "name" : name, "surname" : surname, "password" : passwd1, "email" : email, "phone" : phone, "mobphone" : mobphone, "issysadmin" :issysadmin, "isuseractive" :isuseractive, "recuser" :1 } var dataString = $.toJSON(data); $.post('UserSearchPBT.php', { data: dataString}, useraddResult, "text"); } function useraddResult(res) { var obj = $.evalJSON(res); $("#successfailmessage").html(obj.SuccFailMessage); if (obj.SuccFail=="success") { $("#userid").val(""); $("#username").val(""); $("#name").val(""); $("#surname").val(""); $("#passwd1").val(""); $("#passwd2").val(""); $("#email").val(""); $("#phone").val(""); $("#mobphone").val(""); $("#issysadmin").val(""); $("#isuseractive").val(""); $("#useradd").show('<img src="indicator.gif" />'); $("#userlist").html(""); } //userlistgenerate(); } Quote Link to comment https://forums.phpfreaks.com/topic/220347-how-to-add-a-spinning-gif-to-an-add-function/ Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.