Syncronise Live and Dev site

For discussion and questions related to CMS Specific templates and stylesheets (CSS), and themes. or layout issues. This is not a place for generic "I don't know CSS issues"
Post Reply
boonier
Forum Members
Forum Members
Posts: 43
Joined: Mon Feb 19, 2007 11:39 pm

Syncronise Live and Dev site

Post by boonier »

Hi

Can't seem to find any talk of this on the forum, perhaps I'm searching with the wrong terms, but...

What is the best way to synchronise my changes on a local MAMP dev site with the live version of it. I guess the main changes would be Template and CSS, and the appropriate database changes would be made on live..

Problem is, that both the templates and css are stored in the database in CMSMS. Any ideas/tricks that I'm missing?

many thanks
Si
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: Syncronise Live and Dev site

Post by staartmees »

The best way is to export the database from the DEV-site and import in into the LIVE-site.
boonier
Forum Members
Forum Members
Posts: 43
Joined: Mon Feb 19, 2007 11:39 pm

Re: Syncronise Live and Dev site

Post by boonier »

Hmm are there not going to be potential issues like differences in paths?

thanks
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: Syncronise Live and Dev site

Post by staartmees »

Normally not; it's like moving from one server to another.
boonier
Forum Members
Forum Members
Posts: 43
Joined: Mon Feb 19, 2007 11:39 pm

Re: Syncronise Live and Dev site

Post by boonier »

OK another scenario: say my client is adding content concurrently to me creating new styles on the dev site, if I upload export/import the database they'll lose all their content.. I can't ask them to stop working on their site whilst I do my bit!

In other dev environments, the CSS and Template files are separate to the database and can be synced (ftp or rsync) with the live server.

I know I can separate the CSS, but template files are another issue...

any other ideas?

thanks
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: Syncronise Live and Dev site

Post by staartmees »

I don't think syncing between two databases is possible. So you have to manually add your changes tot the LIVE-site.
User avatar
velden
Dev Team Member
Dev Team Member
Posts: 3497
Joined: Mon Nov 28, 2011 9:29 am

Re: Syncronise Live and Dev site

Post by velden »

staartmees wrote:The best way is to export the database from the DEV-site and import in into the LIVE-site.
Not a good idea under some circumstances:

for example:
webshop
formbuilder that saves into database
admin log will be overwritten
(frontend) user that changed their password
web statistic module(s)
etc.

And of course what boonier says.

Maybe you could do something with http://docs.cmsmadesimple.org/layout/ex ... r-template
boonier
Forum Members
Forum Members
Posts: 43
Joined: Mon Feb 19, 2007 11:39 pm

Re: Syncronise Live and Dev site

Post by boonier »

Or perhaps this is the simplest way:
http://www.i-do-this.com/blog/74/Template-Externalizer

I already use that module (its essential), but it didn't occur to me I could just synchronise the folders over ftp.

What do you think?

(IMO i think template externalizer should be added to CMSMS core)

thanks
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Contact:

Re: Syncronise Live and Dev site

Post by paulbaker »

boonier wrote:Any ideas/tricks that I'm missing?
Good suggestions so far, but what about a different tack?

Just develop on the live site, saving a second version of the template. Then have a test page (not shown in menu) that uses this in-development template. You and client would know the URL to your test page, no one else would. Advantages are it's dead easy to change over to the new design when you're ready and the client can easily view your work by going to the hidden page.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: Syncronise Live and Dev site

Post by Dr.CSS »

I make a new template by copying the existing one, copy style sheet or make a new one with just the changes you want and attach it to the new template as the last style sheet, then make a copy of the page it will be used on the most, not shown in menu, make all changes then switch pages to use it...

All on the same site no sync needed...
Post Reply

Return to “Layout and Design (CSS & HTML)”