Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Atahualpa 3 Wordpress theme (http://forum.bytesforall.com/forumdisplay.php?f=2)
-   -   How to copy settings to another blog (http://forum.bytesforall.com/showthread.php?t=2058)

Ilovethistheme Jun 16, 2009 03:04 AM

How to copy settings to another blog
 
I have customized the theme to suit my blog and now I want to copy the entire theme with all its settings to another blog. I copied the entire folder to the other blog, activated it, but seems there must be an extra step because it doesn't show all the customizations. Where are these stored? Must be somewhere in the database I am thinking? Please help!

juggledad Jun 16, 2009 04:42 AM

The theme options are stored in the database. There is an export function (see http://forum.bytesforall.com/showthr...ghlight=export) but you manually have to enter the options

fromtheranks Jun 16, 2009 01:35 PM

Interesting. I was wondering about this myself as I'm getting ready to move from my dev environment into production. I don't have a problem with re-entering Atahualpa config settings, I can have two browsers open (local and host) and bang those out pretty quickly -- dual monitors come in real handy at times.

Follow-up question: I assume the export includes all of the WP setup stuff? Like, all the plugins, settings, and so forth? I read the text in the Codex but have no experience with what works and what doesn't. It would be a flat out drag to have to do all the WP stuff too?

Thanks in advance.

juggledad Jun 16, 2009 04:03 PM

The export.php only exports the Atahualpa options.

I'm testing a step by step way to dump the Atahualpa options from one site and import them into another. You need to have knowledge of phpMyAdmin. I'll post it when it's done, but I'll give a basic rundown.
(1) in phpMyAdmin of the database you want to copy the Atahulapa options from, you will do a 'select' and export the results.
(2) in the database you want to import to, you will
(a) in phpMyAdmin, do a 'delete' of all the existing Atahualpa options, then
(b) do an import of the file created in step (1)
and that should do it.

there are a couple possible inbetween steps, like making sure the table prefix is fixed up in the export if they are different (i.e. let's say the wordpress prefix is XX- in your test bed and it is WP- in the new location, the export has to be edited) and possible changing a url in the export file. If you need more info right away, send me a PM

fromtheranks Jun 18, 2009 02:19 AM

Maybe because it's late (again) and I'm tired (again), but I'm a little bit confused.

I am literally in the middle of setting up my site on my host servers.

I've copied all of the folders under my wp directory to the new wp directory, and next I believe I need to get all the wp and atahualpa option settings into the new MySQL database (which matches the database name I have here locally, with the same file name extension as set up in wp-config.php here).

The last steps will be (should then be) pointing the virtual directory on the host site to the new wp folder and updating my DNS settings in GoDaddy.

Can't I just dump the MySQL database here and restore it there?

Or if I do the WP export, couldn't I just import that via wp-admin on the host server and do the same thing? Transferring all of the settings for WP and Atahualpa?

I saw this other thread but I don't know how that fits in, i.e. how selective it is: http://forum.bytesforall.com/showthr...xport+settings.

What am I missing? :confused:

Since we're on the subject, what would also be ideal is if I can write my posts here, load them into WP here to proof them and then somehow export them, lock stock and barrel over to the host. ?

Thanks in advance.

juggledad Jun 18, 2009 07:05 AM

IF (and that is a BIG if) the settings in wp-config.php at your testbed match the settings on your host and you want to OVERLAY what exists on your host, then yes you should be able to do a MySQL export from your testbed and a MySql import at the host. You will have to go in and change the settings WP Dashboard->Settings->General Settings->WordPress address (URL) and Blog address (URL) to reflect the new addresses.

What I was trying to address is the case where you just want to move the Atahualpa settings from one site to another. Remenber a WordPress database contains lots of info: the Users, options for widgets, options for themes, extra tables a widget or plugin might use, comments people have written.

As for your last question, why not do what you want, write the posts, edit them and then when you want to move them over, just do a cut and paste?

fromtheranks Jun 18, 2009 12:00 PM

Thank you, Juggledad, once again. :)

I think I've got it now. So a strategy would be:

1. for the very first time, since I'm not worried about stepping on users, existing widget options and so on, it would make sense to do a dump of MySQL, ftp it over and import it. A one time deal to get everything up and running. This presupposes, as you say, that the wp-config.php info is identical. Then I'll need to mod the General --> WordPress address and Blog address as noted.

2. For future changes to Atahualpa, use your approach for extracting just the ATO options. That won't step on anything else.

3. For new posts I can do a cut and paste -- Remote Desktop Control allows (should allow) me to do so. I'd just have to move any images over to the new upload folder first.

The only glitch here that I forsee is that when inserting images into a Post (or Page), I can use relative paths for the Link URL but not the Source path; ex: "http://localhost/fromtheranks/ftr-it/wp-content/uploads/image001-500x318.png" can't be (doesn't seem to be able to be) shortened to "wp-content/uploads/image001-500-318.png".

Hmmm ... if I do the cut-and-paste in HTML mode, could I edit the source link after copying it over but before doing an Update Post? That might work. Unless there is a better way?

Thanks in advance. I very much appreciate your help. :)

(another donation is on its way)

juggledad Jun 18, 2009 01:13 PM

Quote:

Originally Posted by fromtheranks (Post 8727)
The only glitch here that I forsee is that when inserting images into a Post (or Page), I can use relative paths for the Link URL but not the Source path; ex: "http://localhost/fromtheranks/ftr-it/wp-content/uploads/image001-500x318.png" can't be (doesn't seem to be able to be) shortened to "wp-content/uploads/image001-500-318.png".

try using './wp-content.....'

Quote:

Originally Posted by fromtheranks (Post 8727)
Hmmm ... if I do the cut-and-paste in HTML mode, could I edit the source link after copying it over but before doing an Update Post? That might work. Unless there is a better way?

Copy the HTML, Paste in a text editor - make the change, copy from the text editor - paste in new WordPress

One of the issues that you can run into when trying to export from one db and import in another, is if anything has 'happened' in between. Many of the tables have keys that may or may not be used in the other database.

for instance, the wp_options table (where the Atahualpa options are kept) in one person's database, the first Atahualpa option key might be 103, in another person's database it might be 234. If you export the entire row (all the columns) for an Atahualpa option and then try to import it into another database, it might fail because the 'key' might already be in the second database. Or it might be able to insert it, but if that option exsisted with another key, you would now have two different values for the same option. Just guess how that might cause problems.

fromtheranks Jun 18, 2009 01:47 PM

Juggledad,

Quote:

try using './wp-content.....'
I tried "./wp-cont/..." with some interesting results. The image "disappears" from the visual editor -- although the anchors are left in place -- but it does show up in the post itself. If I try "../wp-content/..." it shows up in the visual editor but not in the post.

After you email arrived, I did some research on WordPress (http://wordpress.org/support/topic/263962) to understand how relative paths are set (./ vs ../ etc.) and they aren't recommending it.

I don't seem to have the access issue they refer to because I use excerpts in categories, archives, etc.; a visitor has to click on the post link to go to the actual post page. So, aside from the non-display in the visual editor, relative pathing seems to be working. (Well, not sure about Feeds as these aren't turned on yet ... but then again I'm only planning on sending excerpts here too so I don't think whatever the WP folks are concerned about is an issue for me.)

Or. Am I once again missing something. ?

Quote:

Copy the HTML, Paste in a text editor - make the change, copy from the text editor - paste in new WordPress
Makes sense. Thanks.

Quote:

... it might fail because the 'key' might already be in the second database. Or it might be able to insert it, but if that option exsisted with another key, you would now have two different values for the same option. Just guess how that might cause problems.
I could see this as an issue ... unless (?) ... there is only one person setting options? And I start out with identical copies of the database via the dump method? ... If there were two or more admins (shudder at the thought) this could definitely be an issue. Yes/no?

Thanks in advance.

juggledad Jun 18, 2009 03:16 PM

Each time you activate/deactivate/update a plugin it's possible to change rows in the wp_options table so unless your sure you will replicate you moves (hmmm, did I do steps A, B, D, C or A, C, B, D?? Is that a B or an 8 I wrote there??) you could get into trouble, but hey then you do have a backup, RIGHT?

fromtheranks Jun 18, 2009 04:01 PM

Jugglehead,

Point taken. I think I'll stick to having my local copy on one monitor and my hosted copy on another and just update ATO manually. :)

As for relative paths, I'm thinking that maybe I should avoid using that "feature" altogether and do as you suggested for moving the post, just edit in the new URL in a text editor (Frontpage, etc.) then copy and paste into the Host. And if I miss one, I can always use the Post HTML editor to fix it.

Thanks again.


All times are GMT -6. The time now is 07:02 AM.

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