简体   繁体   中英

redirect from one webpage to two other webpages

Actually I am using API to send SMS from a webpage from my site. The SMS gateway site just gives the feedback of delivery, doesn't return to my website. After sending SMS, I need to send emails & update database. I know JavaScript & php.

I don't want to depend on SMS gateways redirection, is there a way to go to their webpage & return back without their involvement?

使用cURL从您的服务器调用API并保持客户端体验完全在您的控制之下 - 这样您不仅可以重定向,AJAX或任何您想要的任何内容,您还可以在客户端滥用您的页面时执行一些低空飞行的子弹。

From your question, I assume that you are transferring control to the SMS gateway site by redirecting the browser to it, then no. Once the browser leaves your site and loads the gateway site, you no longer have the ability to run any code.

If you are, instead, invoking the SMS gateway API via server or client side code, then yes. Once the HTTP request that invokes the API is complete, you will be able to perform a redirect as you normally would.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM