Greenguy's Board


Go Back   Greenguy's Board > Chit Chat
Register FAQ Calendar Today's Posts

Reply
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 2019-08-11, 01:10 AM   #1
sarettah
Asleep at the switch? I wasn't asleep, I was drunk
 
Join Date: Apr 2005
Posts: 214
I spent a few hours today working out some code. It works better than I had hoped. I had my doubts that I could make it work at all but it came out pretty slick.

Client project. 2 sites on 2 different servers. They both use one admin panel on one of the sites because of the payment processor. I had written the admin panel a few years back, then when they decided to use it for the info for the 2nd site I added what needed to be added to the admin panel. They were only using the admin panel to keep track of sales for the 2nd site. They were not controlling any of the 2nd site's structure or functionality from the admin panel.

Well, now they decided that they want to have information from site 1's admin panel show up on site 2.

So, I added code so that when they add/change/delete info in the admin panel it automatically updates to the 2nd site. So, for example, if they add a model to the admin panel and the model is for the 2nd site, the model table info is stored in both site 1's database and in site 2's database so site 2 can use the info.

Then I decided I would need to run an occasional sweep through the databases to make sure they are kept in synch. That is what I wrote today. From a cron, site 2 calls for a page on site 1. That page lists all the pertinent info from several tables. The site 2 program then compares the data from site 1 to the existing data on site 2 and adds/changes/deletes as necessary. I am still working through the security concerns but it is working very nicely so far.
sarettah is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:29 PM.


Mark Read
Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
© Greenguy Marketing Inc