In my wesbite, when a user submit a form, I need to update my DB and send several e-mails (to him, to admin, ...)
For now, I'm doing in inside the target page of the form.php (which in my case is also form.php). The problem is that sending e-mails takes a while. And from the user point of view, it just seems that the page takes a while to load.
Is there a way that the e-mails will be done on a separate "thread" so that I the user doesn't have to wait the emails to be sent?