0

HI,
I have two webserver and two domain and I want to share information between them.What I want to do is this to share the database between two webserver so ,if I add new information through domain 'A' that information can can be catch from domain "B" and I have that information in domain 'B'.Also the files in one server should be share between two webserver so If I add a new file or make a change in it in domain 'A' it can be retrieve from domain 'B' an I can use it in there.

I apologize if it's not so clear .My English is not good.

Thanks

4
Contributors
3
Replies
4
Views
7 Years
Discussion Span
Last Post by kireol
0

I do this a lot as my website is scattered between two web servers and the easiest way is with curl and file_get_contents(). You can retrieve contents from a database using file_get_contents('http://example.com/sql.php?key=asldfkjasldkfj&column=23') . Then it will return the contents of that mysql request and you can use the url parameters as part of the WHERE clause. On the other hand there is curl with allows you to do $_POST requests. This way you can send larger amounts of data and will be harder for people to tap into the database.

0

what you can use for this is cURL, this gives you the possibility to open a stream to an other server and write/read there.

HI,
I have two webserver and two domain and I want to share information between them.What I want to do is this to share the database between two webserver so ,if I add new information through domain 'A' that information can can be catch from domain "B" and I have that information in domain 'B'.Also the files in one server should be share between two webserver so If I add a new file or make a change in it in domain 'A' it can be retrieve from domain 'B' an I can use it in there.

I apologize if it's not so clear .My English is not good.

Thanks

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.