The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

> Open Page as hidden, Open new page
Freshman
post Dec 25 2018, 04:46 AM
Post #1


Newbie
*

Group: Members
Posts: 12
Joined: 19-December 18
Member No.: 26,776



Hi all,

I have a line of code that sends a SMS to a Mobile number.
Problem is that it opens a page to do that, so it navigates away from the page I'm on.
So I want it to do it's thing and then come back to the page I was on.

I was wondering it there is a way to open a page "silently" or hidden or if there is a way to navigate to a site and wait a while and then come back.

Here is the code:

CODE

header('Location: http://www.mymobileapi.com/api5/http5.aspx?Type=sendparam&username=$User&password=$Pass&numto=' . $getcell . '&data1=Test123;
exit;


If I add a second line header('Location: index.php'); then it does come back to the index page but it does not send the SMS.
I tried adding a sleep command inbetween but still not sending the sms then

The other problem is that if it open the mymobileapi page it also shows the username and password in clear text. So it would have also been nice to hide that but the site is a 3rd party site so I don't have any control over it unless I can add something to the Header command to hide the URL??

Thanks a lot


User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
 
Reply to this topicStart new topic
Replies
CharlesEF
post Dec 28 2018, 11:34 AM
Post #2


Programming Fanatic
********

Group: Members
Posts: 1,672
Joined: 27-April 13
From: Edinburg, Texas
Member No.: 19,088



Ah, good old cURL. Don't know how I missed it. Anyway, glad you got it working.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Posts in this topic


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 18th October 2019 - 02:41 AM