I have a static HTML site (about ten years old) which I am going to migrate to a Wordpress site.
I have used Wordpress before but never as a migration target. From some initial background reading I have come up with the following process to perform the migration:
Check hosting provider/package for Wordpress suitability
Generate complete current site map
Make a complete backup of current site
Install Wordpress in subdirectory
Install Maintenance mode plugin and activate
Migrate content to Wordpress instance (looks like this could be
painstaking..)
Install suitable theme
Customise selected theme with Logo/fonts/colours etc.
Deactivate maintenance mode
Make Wordpress site available from domain root
Delete old static html site files
(The migration may take place over several weeks/months so I need the static HTML site to be available until step 10 is completed)
In my naivety are there any pitfalls in the above process, or additional issues I have failed to consider?
Are there any other accepted 'best practices' when performing this kind of migration?
Here's a good tutorial:
http://code.tutsplus.com/tutorials/creating-a-wordpress-theme-from-static-html-creating-template-files--wp-33939
For developers who want the theme converted from HTML in easy way (but no guarantee if it can produce the output as expected):
http://www.htmltowordpressconverter.com/
Hope this was helpful!!!!
WordPress theme styles come in all shapes and sizes. Converting from a static HTML site to something database driven like WordPress can be as easy or complicated as you want.
If you just want to integrate WordPress into an existing HTML theme it's as easy as installing WP, setup the database and config, then building in the old HTML structure using WP. This way everything will be the same but managed within WordPress i.e. Pages, Menus, Sidebars.
Here's are some useful links:
https://codex.wordpress.org/Using_Themes
https://codex.wordpress.org/Theme_Development
https://codex.wordpress.org/Stepping_Into_Templates
And here's a "Start from Scratch" theme that would be simple to start from. Just install it, activate it, then begin migrating the main content i.e. copy and images etc, and building the theme itself.
http://adopttheweb.com/start-from-scratch.zip
Related
I am a freelance developer, and I normally build sites from scratch without using any code generating sites like WordPress or Square Space. But my current client insists on using WordPress. However, I am rescuing this project from a previous developer who made a big mess because from the looks of it does not seem like they knew what they were doing.
Is there a way for me to restart everything, on a clean slate and template on WordPress? I would like to have none of what the previous developer has done. Also is there a way for me do do direct coding using HTML, CSS, JavaScript etc on a WordPress site?
Yes, you just need to look into how to create a theme, since themes are the basis of the Wordpress structure. Ultimately, if you have the code for a website, it can be broken into separate files that Wordpress can use.
See: http://www.wpexplorer.com/create-wordpress-theme-html-1/
If the previous developer has done all the work in the theme files, then simply switching the theme to a default theme (Like Twenty Sixteen) will give you a nice clean slate to dig in and jump off with. You will want to create a child theme of any existing theme if you want to make any changes. If, however, the developer has messed with other files besides the theme folder, then you will most likely want to export the content only (as a logged-in administrator, go to Tools > Export (here's a screenshot))
Then on a new environment (I prefer testing these things first on a local virtual environment like VVV, and then transition to a development subdomain on the same server that the site will eventually go live on and securing it with an htaccess user/password to block curious eyes), import the content on a fresh installation of wordpress via the same menu (Tools > Import). This will give you a fresh installation with the content that's been created, but without any of the mess.
For more information about importing content - here's the codex article.
I hope that's a good start - but if I've glossed over anything you don't understand, let me know - I'm happy to help.
I didn't know about the best practice of not skinning/modifying/working off of the core wordpress theme (twenty-ten, twenty-eleven, twenty-twelve, twenty-thirteen), and a bunch of my clients sites are running right now on the core themes with a custom/modified skin.
I've heard stories of wordpress getting hacked and sites being compromised because wordpress is out of date. The wordpress team also pretty much states that security issues are being fixed with each update. I need to update the core wordpress files on these sites to prevent this, but now I'm scared that if I update wordpress, the theme will be overwritten.
In fact, I had a client click the update button once in the wordpress admin (not really knowing what they were doing) and overwrite the theme (that was pretty disasterous). I even use a plugin now to disable that message so my other clients don't do that.
What steps should I take now to fix this? Copy the theme, rename the folder/theme name in style.css, and change the theme in admin settings? Would I be OK to update wordpress after I do this? Or are there more steps that I need to take?
You have the right idea. Copy the theme folder and rename the new copy to something else like customtheme. Then edit customtheme's theme info in the comments at the top of style.css and switch to it in the admin panel. After that you are safe to update.
Do keep in mind that it's possible WP updates will break things anyway, depending on how you implement custom functionality and what plugins you are using.
Agree with the above. Don't go anywher near the WP core or the default themes. Either create child themes or better off, build your own.
Copying and renaming and existing theme will cause you all sorts of problems as each theme uses named functions. If you just rename the stylesheet there will be more conflicts than you can fix in a week of debugging.
If you are blocking the update messages you are putting your clients at risk.
Openshift's default app generator sets Wordpress creation of sites to be a non-scalable version of their gears. I'd like to know if there is a way to set a scalable instance and install wordpress on it.
thanks!
I am working on this today actually and got a scalable wordpress site up and running on OpenShift. (www.runcloudrun.com)
I disabled the symlinks in the action_hooks and manually added my theme and plugins to the php/wp-content/themes and plugins directory. I also used a S3 plugin to store all of my media files on amazon s3 so my images and media would scale once OpenShift adds addiontal gears.
I am writing a blog post on how to do all of this and it should be posted later this week.
Edit to add the blog post: http://www.runcloudrun.com/?p=22
--
gs
You can checkout this AppFog solution. And if you visit his Github you'd find an OpenShift wrapper as well. These two might give you all the sparks it needs to think out a scalable solution on Openshift.
Just use the git source URL and create a new app with PHP. Once the app is created, add MySQL to it.
Once you've created the app, the important next step is to check in your modules directly to the Git repo.
By default, we wanted folks to be able to download plugins directly from Wordpress, but when you scale, those files aren't copied over. Also, the filesystem for each gear in a scaled app isn't shared, so modules uploaded after you scale aren't magically copied to all gears. Given that limitation, we decided to mark the QuickStart not scalable, so as to prevent unfamiliar users from getting into trouble.
If you're familiar with Wordpress just check those modules in directly to your source, and everything will scale.
I want to create a static website and use wordpress only to "compose" the website. I want to create a template that only use the same header and footer and change the content of the page (home, contact ecc dcc). My site is not a blog or any other type of site that needs CMS I only want to use Wordpress to have only one header and footer and don' t want to change it in all pages when I need some customization to it. I hope I was clear enough! Thanks!
You can create a site in WordPress (or any other CMS) on your own local computer, then save a copy using an offline browser such as HTTrack. Then upload the HTTrack saved HTML to your webhost.
This will make your site faster, as there will be no need to execute PHP on page requests, and the webserver will use its default caching headers. (Also, you get the option of using a cheaper hosting without support for PHP and MySQL.)
Any time you change the site, you'll need to edit the live WordPress version, save it again, and reupload the files.
Disclaimer: I'm dev of the WP Static HTML Output project.
It's been around for a few years and still has 5k+ active installs, but jazzing it up with some more features now and its whole purpose is to allow you to use WordPress for your site development and export to a static HTML version for speed, security and portability.
For the OP, the basic FTP publishing option may be of use. For more advanced cases, there are services like Netlify which can auto build/deploy your static site from a Git branch.
In the Settings | Reading admin page, choose a static page for your front page display. Build your site out using Pages instead of Posts. Each Page will inherit your site's standard header and footer. Create your Main Menu from the Appearance | Menu admin page to hook together your Pages. Use widgets and standard HTML links as needed. Then dress up your site with one of the many available themes.
A bit late to the table on this one but it seems that Wordpress is totally overkill for a static site. Wordpress pages can be cached with cache plugins but when any Wordpress site loads there are a number of scripts and custom php functions that run each time a page loads.
Why not just build a flat file website and simply include your header and footer with PHP? Far quicker to set up and based on your question it seems that this is simply what you need.
Added to this, you won't have an admin area for your site or a database, just the files on the server - surely this makes your site less hackable too. An added bonus is a really easy site to version control with Git or SVN.
If there's someone else out there wanting to use a static site generator over Wordpress, here's a script called WP Static which does just this: http://mossiso.com/code/make-wordpress-static
Another great solution to this problem is to use a specific software that is created exactly to do that. For Mac, for example, there's a software called Hammer that "compile" your site every time you save and includes your header and footer to the page. Is really useful.
Is it possible to have one WP instance run domain.com/articles and domain.com/tips while the rest of the site would be run by Zend Framework?
What you could do is setup a Wordpress MU site. have the install on domain.com/articles and domain.com/tips and then the rest of the site shouldn't cause any problems.
The only downside is that you basically have two sites for two sections of your site. I just did a Wordpress MU build and it got a little tricky but in the end it all worked and its pretty easy to update, just an extra click or two.
You can install Worpress in your root domain. Make the homepage of the Wordpress install the current homepage of your website with all of the links, layouts, and original site subfolders preserved. Then just have Wordpress take care of the other URLs that you defined above, making sure not to create any Wordpress directories that conflict with the current site directories.