Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme »

Can I make it so user can change theme colour scheme in 1 click at the front of site?


  #1  
Old May 31, 2011, 03:35 PM
mafgirl's Avatar
mafgirl
 
79 posts · May 2010
Brighton, United Kingdom
This is probably the most random question you have ever heard as it certainly is mine !

My client is asking me to create a website in blue and have a duplicate website exactly the same in green, linking to each other. I was wondering if I could create a link (in a widget or something) to the 'green' site and the 'blue' site, but linking it to the same url and only changing the colour scheme?

It sounds like it could be plausible, however I have no idea to do this so any help at all would be appreciated I have just started to study php, MySQL and JavaScript but am nowhere near good enough to figure this one out.. anyone have any ideas?

Thank you ever so much!!!
__________________
my website www.marolinedesign.com
  #2  
Old May 31, 2011, 04:27 PM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
Yes this is possible to do, but I would go back to the client and ask him how much he is willing to spend to do it and to maintain it in the future because it is not trivial.

you can have green.com point to one install of WP in a folder and
you can have red.com point to another folder with a WP install.

The key is to make the wp-config.php's in the wordpress roots exactly the same. now you have two installs pointing at the same database, but if you add a plugin, you must add it to both AT THE SAME TIME and before activating it. Same for wordpress upgrades - you'll need to do it manually on both sites

Next you will need to go to green,com and style it. then visit a page, grab the CSS that is created and save it. Then go to red.com and style it red., view the page and save the CSS.

you'll replace the existing style.css with the css you saved and then have to edit the code to remove the auto generated CSS. and every time there is a change to the theme, it will have to be done again, twice as much time for everything...actually more than double since you have to save the CSS each time...

but if the client is very rich....
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old May 31, 2011, 10:06 PM
mafgirl's Avatar
mafgirl
 
79 posts · May 2010
Brighton, United Kingdom
Hi Juggledad! thanks for your reply...that sounds complicated..is it possible to have two wordpress installs on the same domain though?

I should have made myself clearer and said they are actually on the same domain. He currently has it like that on his current (non-wordpress) website www.corriganbentley.co.uk if you check it out he has a splash page and 'Sales & Technical Recruitment' and 'Lo-Carbon Products Recruitment' are duplicate pages, just Sales & Technical Recruitment is blue and Lo Carbon Products Recruitment is green. At the moment if one is changed, the other needs manually changing too.
He asked me to do a complete re-design on Wordpress, but keep the same style splash page with a green and blue 'site' on the same domain name.
So I was wondering if it is possible, rather than create two separate installs of wordpress, to have one install, and both pointing to the same single pages, but for the user to change the theme colour?
Ie the links on the splash page will trigger the theme colour, but point to the same page?

Maybe I am being to complicated about it and should just create the duplicate pages, but you are right, it will be more expensive for the client - and more work for me..
__________________
my website www.marolinedesign.com
  #4  
Old Jun 1, 2011, 04:58 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
so you want to have two pages, A and B. On page A you want two links, 1 and 2. Both links go to page B, but when you press link 1, page B is red and when you press link 2 page B is green.

Without digging into the code and testing the the link that was used, there is no way to do this. When you get to page B, it's page B. There is nothing to tell where it came from. Even if you create a custom menu with two links, B-RED and B-GREEN, when you press the link, when you get to page B both links B-RED and B-GREEN will have the class of 'current-menu-item' because they ARE the current menu item.

So your choice is to add code to see if you can add a class to teh body statement depending of teh menu item selected, or have two pages.

The idea of two 'sites' doesn't work unless you point to two different DB and then you still have double the maintenance.
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #5  
Old Jun 1, 2011, 07:12 AM
lmilesw's Avatar
lmilesw
 
10,176 posts · Jul 2009
Central New York State USA
The only way I can see to do what you want is to install two separate WP instances each in a different subfolder. The root would be your first page like you have at http://www.corriganbentley.co.uk/. So you would install one WP site at http://www.corriganbentley.co.uk/sales and one at http://www.corriganbentley.co.uk/green.

This is very similar to what you currently have. You will just have two complete websites to maintain which will be cumbersome when the info in both is supposed to be the same.

I would think creating page templates with different colored backgrounds or some other way to define them would be much easier but as we all know the client is king.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #6  
Old Jun 1, 2011, 07:44 AM
GarethP
 
64 posts · Jun 2010
Could you have 2 Atahualpa themes installed - i.e. ata-green and ata-blue and then use a plugin like this?

http://wordpress.org/extend/plugins/wp-theme-switcher/

It would mean 2 upgrades of the theme when necessary but that's quite minor...
  #7  
Old Jun 1, 2011, 07:55 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
actually, looking at the existing site, it looks like they have three different sites - the home links are different, the about pages show different information.

You can install a separate version of WP in a subfolder and point it at a separate DB

mydomain.com -> database A
mydomain.com/green -> database G
mydomain.gom/red -> database R
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #8  
Old Jun 3, 2011, 02:45 AM
mafgirl's Avatar
mafgirl
 
79 posts · May 2010
Brighton, United Kingdom
wow thanks guys!

I didn't realize there were so many more replies until I just looked, must have forgotten to set up the email notification.
You have have some very good advice indeed, so I will get to work with these and let you know how I get on
Thank you SO much!!

Marjolijn
__________________
my website www.marolinedesign.com

Bookmarks

Tags
change colour, colour scheme, front edit

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Click on Author/User UnionBreeze Post-Kicker, -Byline & -Footer 2 Nov 22, 2010 10:48 PM
[SOLVED] How can I get a different color scheme for submenus ? mark_orion Page & Category Menu Bars 6 Feb 13, 2010 02:34 AM
How do I make a pop up page when I click a link in my post? sri78 Forum How-To 1 Jun 18, 2009 06:51 AM


All times are GMT -6. The time now is 03:50 AM.


Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.