elhelaly1999 Posted July 24, 2008 Share Posted July 24, 2008 Hi , Can I send variable to page without submit form or send it with URL ? Quote Link to comment Share on other sites More sharing options...
MasterACE14 Posted July 24, 2008 Share Posted July 24, 2008 you can send via URL like so... <a href="page.php?name=bob>bob</a>" then retrieve it like so... <?php if(isset($_GET['name']) && !empty($_GET['name'])) { echo $_GET['name']; // prints "bob" } ?> you can submit a hidden form to another page, using javascript also... Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 thanx MasterACE14 But as I write above I don't want URL or forms Quote Link to comment Share on other sites More sharing options...
MasterACE14 Posted July 24, 2008 Share Posted July 24, 2008 you can use session variables then. Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 thanx a lot But this page which I want send variable to it on another server so I can't use session or cookies Quote Link to comment Share on other sites More sharing options...
MasterACE14 Posted July 24, 2008 Share Posted July 24, 2008 then you'll have to use a form or GET method :-\ Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 Is there any suggestion else ? Quote Link to comment Share on other sites More sharing options...
unkwntech Posted July 24, 2008 Share Posted July 24, 2008 Sometimes where there is no answer, it's because the question was wrong. There are 4 ways to take data from one page to another: GET POST SESSION DATABASE Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 OK I will say that my question is wrong and I will explain my problem But I want to get data from Database this database in another server and I don't want to make connect to this DB from my server but I want to send a request to this other server with variable to connect to the DB and get the data this my problem and I hope u understand my problem Quote Link to comment Share on other sites More sharing options...
samshel Posted July 24, 2008 Share Posted July 24, 2008 do you have access to the "another" server ? if yes and if you dont want to use - direct db connection - GET - POST - SESSSION then i think you can go for using Web Services. Create a SOAP server on "another" server, Create a SOAP client on your server and access the data Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 thanx samshel I tried to make it web service but there are several issues so I try to make it with another way But It seems that not working thanx for every body Quote Link to comment Share on other sites More sharing options...
Entanio Posted July 24, 2008 Share Posted July 24, 2008 You can post a form automatically through PHP. That is PHP does it when the user opens the page and no-one has to press a submit button. Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 Thanx Entanio But variables will appears to every body and these variables sensitive data Quote Link to comment Share on other sites More sharing options...
elhelaly1999 Posted July 24, 2008 Author Share Posted July 24, 2008 Can I send with Get or POST without notify the user ? 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.