darub Posted February 22, 2017 Share Posted February 22, 2017 When some customers send a ticket, they press a send button two times until three, thinking that the ticket wasn't sent, when the ticket are in the normal process to be send. Exist the ability to put a bar displaying the percentaje of the task, or hide the button? Awaiting replies, worm regards! 0 Quote Link to comment Share on other sites More sharing options...
darub Posted March 13, 2017 Author Share Posted March 13, 2017 Any help to fix this issue? Regards 0 Quote Link to comment Share on other sites More sharing options...
yggdrasil Posted March 14, 2017 Share Posted March 14, 2017 What exactly are you trying to achieve or avoid? Do you mean clients sending the same tickets twice? If a client hits the send ticket, the ticket is opened immediately, there is no wait time. Its instantly, its so fast that a user can't click again, similar to how you send a form online. If they are clicking the send ticket button and it takes a while to show the success message, then I would seriously check your server as there must be something wrong or terrible slow. It should take less than 1 second, actually less once you hit the button. I'm not sure if I understand what you mean but how are your users clicking the send button 2 or 3 times? If you mean they keep replying the same open ticket over and over again, that is also the expected behavior. There is no way in WHMCS as far as I know to avoid them from updating a ticket until you reply, just like there is no feature to avoid them from re-opening closed ticket. 0 Quote Link to comment Share on other sites More sharing options...
darub Posted March 14, 2017 Author Share Posted March 14, 2017 Hi Yggdrasill For example, when the customer try to send an attachment, according the internet connection when is slow, I need to prevent the customer press the button send twice. In some cases, the client can't wait the notice that a tickets has been generated and has been sent and press the button twice. Awaiting your reply. Regards Dario 0 Quote Link to comment Share on other sites More sharing options...
vbatra Posted March 14, 2017 Share Posted March 14, 2017 You can customise the code to disable the button if it is pressed once to disallow customers to press it repeatedly. 0 Quote Link to comment Share on other sites More sharing options...
yggdrasil Posted March 15, 2017 Share Posted March 15, 2017 (edited) Yes this can be done with JavaScript. This is what you are looking for: http://www.the-art-of-web.com/javascript/doublesubmit/ But I do think you must have some issue with your server. There is a reason why nobody asked this before. I never had this happen with users either. Once you hit the send button the page changes so quickly, the user has no chance to hit it again. Even on a dial up modem Internet (very slow) its less than 1 second. I would seriously advise you to check your server or installation on why its so slow if this is something happening with your users. It maybe your MySQL server that is taking a while to respond or the server, or a problem in your code. I don't think it's a speed problem with your users, what would be the chances of that? Its more likely your server or WHMCS installation that is not responding in time and so users are doing what most would do when things are slow, hit the reload button or hit the send button again. While something like this could happen in some very weird instances, did you noticed that even this forum does not have that function either when you hit send? Most forms don't disable the button once send because there is no need to that (browsers are clever enough to avoid it) unless the action is going to take a while. Submitting a ticket in WHMCS is not something that takes long at all. Its instant once you click the send button. Disabling the button could potentially cause other issues that could disable it by mistake and so disallowing your users from submitting the ticket as well, so you may consider if its worth to do that vs just fixing the problem with your server. Edited March 15, 2017 by yggdrasil 0 Quote Link to comment Share on other sites More sharing options...
darub Posted March 15, 2017 Author Share Posted March 15, 2017 Hi Yggdrasill and thanks for your help! Definitely now work. The problem occurred when the user attempted to send large files. Thanks again! 0 Quote Link to comment 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.