Forum Replies Created

Viewing 15 replies - 16 through 30 (of 46 total)
  • Thread Starter tdcarp

    (@tdcarp)

    Wow! Very easy! I’ll test it right away. With this approach, do I still activate the child theme?

    Is the theme uri also important, or just the template statement?

    Now I’m confused by the enqueue codex. In non-wp sites, I’d add a style link to the Head of pages to enqueue style files. Apparently, the use of @style is no longer recommended and this js code is needed to create the effect of style links.

    Also confused because the codex recommends this for the child style:

    /*

    Theme Name: Hashi-child
    Description: Greater Maple Valley Unincorporated Area Coucil (GMVUAC) style sheet
    Version: 1.0.0
    Author: Tom Carpenter
    License: GNU General Public License v2 or any later version
    License URI: https://www.gnu.org/licenses/gpl-2.0.html
    Tags: gmvuac
    Copyright 2016 Tom Caroenter
    All of the theme’s PHP and CSS files are licensed under the GNU General Public License, version 2 or any later version:

    https://www.gnu.org/licenses/gpl-2.0.html

    Other files are licensed as follows:

    * hbg.jpg is released into the public domain;

    * bbg.png, black_list_bullet.png, blue_list_bullet.png, close_menu.png, open_menu.png, sbg.png, wbg-smaller.png and wbg.png are ineligible for copyright because they are trivial.

    */

    • This reply was modified 8 years, 5 months ago by tdcarp.
    Thread Starter tdcarp

    (@tdcarp)

    The test was only partially successful. The active theme and its child data were gone (the appearance>theme showed the theme but said it had no data). Three other themes were completely gone (no icon or data). 2014, 2015, and 2016 were there.

    Media was there but all were pointing to the old url.

    Will run another test to make sure the settings url change updates media urls.

    Thread Starter tdcarp

    (@tdcarp)

    Looks like success! Was able to install vanilla wp in the root on the new hosting account that has the domain used by the old wp site. Emptied the db tables and imported the db tables from the old site. This means the issue of domain in the db was eliminated.

    All the users, pages, and media appear to be there.

    I’ll now execute the process that changes the domain name BEFORE exporting the db. Create the new db, import that data, migrate the files, and update the config.php db connection.

    I’ve learned quite a bit. Thanks. Will post back the final, tested process.

    Thread Starter tdcarp

    (@tdcarp)

    Thought of another way to try migrate the old site. The old domain was moved, but no content had been loaded yet, so I moved the files there which should eliminate the domain name issue in the db. Created the db and imported the old site data.

    Am getting the message “Error establishing a database connection” when navigating there. Checked the config file and all the db entries looked right. Even reset the user pswd just in case.

    Read a couple articles on this error in the WP environment. Everything seems to check out file. Could be a problem with my hosting service, but haven’t checked that yet.

    I noticed that the vanilla install of WP doesn’t have a config file, nor is there a need to set up the db before logging in for the first time. Can I delete the config and the db, let WP do the initial setup of each, and then import the old site db data?

    Thread Starter tdcarp

    (@tdcarp)

    Things were in such a state that I decided to start all over re-creating the original wp site from scratch. Too many changes to config file, domain addons, db settings, etc. Not such a big deal since this is just a wp test area.

    Once recreated, I’ll run a migration test again using the method in my last post. For others’ benefit, I’ll post the result.

    Thread Starter tdcarp

    (@tdcarp)

    Since I want this to be repeatable, I’m going to test this process:

    1. Migrate the files (using FTP, this will create a backup).
    2. Change the WP setting to the new domain.
    3. Export the database; create a new db; import the db data.
    4. Update the config file to create a new db connection.

    Will post back the results.

    Thread Starter tdcarp

    (@tdcarp)

    Apparently, pages are stored in the posts table. I browsed a couple records and don’t see any domain references.

    Regardless, would all this be avoided if the domain were changed on the old site before the db export?

    Would that handle both the settings and the pages?

    Thread Starter tdcarp

    (@tdcarp)

    I’m so sorry I forgot to mention that in the original post. Big bad!

    I see where the options (settings) are. You say “each page”(?). Where’s that? I don’t see pages in the database, nor do I see any in the php files.

    For the specific migration I’m working on, the process seems to be:

    1. FTP the files (download to local; upload to new server)
    2. Change the settings for the domain
    3. Export/import the database (create a new db via cPanel)

    The config file should be right (i.e. have the new domain) because the change was made before the db export.

    OK?

    Thread Starter tdcarp

    (@tdcarp)

    Browsed the database and found a couple records in the wp-options table that point to the old domain (option_name(s) siteurl and home).

    Do I edit? Was this avoidable (e.g. different options for export/import)? Almost feels like I could have made the change from within WP on the old site (after all the files are downloaded). The export would then have the domain/url for the new server.

    • This reply was modified 8 years, 5 months ago by tdcarp.
    Thread Starter tdcarp

    (@tdcarp)

    Found the domain management in cPanel. See the A and CNAME records. I don’t see what should be changed.

    The 2 A records (@ and admin) both have the new server IP address. The CNAME www record is @.

    Does that help?

    Is it possible the MySQL export/import wasn’t right? In other words, I took all the defaults for the export except the DROP option, which appeared to be important from something I read.

    • This reply was modified 8 years, 5 months ago by tdcarp.
    Thread Starter tdcarp

    (@tdcarp)

    I didn’t do step 5 yet (e.g. DNS, A record, CNAME). Not all that familiar with the terminology.

    Are these done using cPanel?

    The domain name changed, as did the server.

    I’ll review some of the articles to see if they explain in a way I can follow.

    Line 627 of the function.php file is the last line in the file (and is blank). Looked at the 2 lines in login.php. Don’t totally understand, but the keywords “server” and “path” are in the area of the specific lines.

    Again, may be things needed in your step 5.

    Thanks for your continuing help.

    Thread Starter tdcarp

    (@tdcarp)

    Completely removed wp install from hosting account. Made sure all files and db were gone. Ran the migration again (upload all files, create db, import db data from old site).

    Modified config file to connect to new db.

    Got the same message (hashi is the active theme).

    Not sure where the error is.

    Tom

    Thread Starter tdcarp

    (@tdcarp)

    Going back to assure there is no residual from installing WP via cPanel. It still showed WP installed. Will start the test again.

    Thread Starter tdcarp

    (@tdcarp)

    Shannon

    Created a new MySQL db and imported export from old db (looked at the user table and it has the users from the old installation).

    Added dbName, user, pswd to config. Interestingly, the config file has a long host name, yet the config_sample shows that field as “localhost”. MyPHPAdmin says the host is “localhost” so I changed the host name to ‘localhost’.

    Tried to logon to WP and got this error:

    Warning: Cannot modify header information – headers already sent by (output started at /home/wizardclown/public_html/carpenter/gmvuac_wp/wp-content/themes/hashi/functions.php:627) in /home/wizardclown/public_html/carpenter/gmvuac_wp/wp-login.php on line 390

    Warning: Cannot modify header information – headers already sent by (output started at /home/wizardclown/public_html/carpenter/gmvuac_wp/wp-content/themes/hashi/functions.php:627) in /home/wizardclown/public_html/carpenter/gmvuac_wp/wp-login.php on line 403

    Thread Starter tdcarp

    (@tdcarp)

    Thanks Shannon

    If I understand, your approach does not install WP using cPanel on the new hosting account, but instead, WP gets installed by coping all the files and creating a new db. I’ll recreate the db and do the import again.

    Step 4 is where I got confused. I know the name, pass, and user, but the wp-config.php had a long host name that seemed to be from the old db.

    I’ll record the host name before and after the import to see if it changed.

    Please hang in a little bit longer while I get the process figured out.

    Thanks again!

Viewing 15 replies - 16 through 30 (of 46 total)