Jump to content

touchstart and click on refresh only


Recommended Posts

I have a very simple code that often only works after I get to the page, then ask for the page to reload. If I click the button without reloading, nothing happens. If I click after page refresh, it works perfect. Thank you for your help. This page has a few tables all brought in by PHP select statements etc. Could that possible have some anything to do with it?


 

	<script>
	$(document).ready(function(){
	//OPENING PRIMARY
	$('.OpenerPri').on ('touchstart click',function() {
  
    var ppNum = ($(this).val());
    var callType = 'opener_pri';
    ($(this).prop('disabled', true));
    ($(this).html('Thx'));
         $.post("reservecall.php", 
           {
           ppnum:ppNum,
           calltype:callType
          },
    function(data, status){
        alert("Data: " + data + "\nStatus: " + status);
    });
});
	
});
	</script>
	

Edited by IndianaGuy
Link to post
Share on other sites

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.   Paste as plain text instead

  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.

Loading...
×
×
  • Create New...