launching a wordpress site 101 (cincinnati wordpress, august 2015)

13
Launching a WordPress Site 101 Cincinnati WordPress - August 2015 Andrew Duthie

Upload: andrew-duthie

Post on 11-Apr-2017

285 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Launching a WordPress Site 101

Cincinnati WordPress - August 2015 Andrew Duthie

Page 2: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Topics• Anatomy of a WordPress site

• Hosting requirements

• Tools

• Moving content

• Preparing to flip the switch

• Demo

Page 3: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Site Anatomy

Page 4: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Site Anatomy

The standard WordPress installation includes many

files which interpret browser requests and load the

appropriate files.

Most importantly, the configuration file defines the

settings WordPress should use to connect to a

MySQL database. You can also define security and

site settings.

WordPress Core

Configuration

/wp-admin, /wp-includes

/

Page 5: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Site Anatomy

The theme directory contains the layout and styles

for displaying your site.

Each plugin adds unique behavior to your site. The

plugin files describe the behavior, and additional

customizations are typically stored as options in the

database.

Theme

Plugins

/wp-content/themes/twentyfifteen

/wp-content/plugins/akismet

Page 6: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Site Anatomy

Media files (images, videos, documents), including

thumbnails, are stored here.

The contents of your posts and pages aren’t stored

in the WordPress site directory, but instead live in

the MySQL database.

Uploads

Content

/wp-content/uploads

mysql://localhost:3306/database

Page 7: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Hosting requirements• PHP 5.2.4 or greater

• MySQL 5.0 or greater

• Usually Apache HTTP Server or nginx

https://wordpress.org/about/requirements/

Page 8: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Tools

A FTP (File Transfer Protocol) client enables you to

move files between your computer and a remote

hosting server.

FTP Client

• Always prefer SFTP (FTP over SSH) if offered

by your host, since plain FTP can be insecure

CyberduckMac OSX

Filezilla Cross-platform

Page 9: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Tools

A database client allows you to browse the content

of your WordPress site. It usually provides export

and import options to move your content from one

place to another.

Database Client

Sequel Pro Mac OSX

HeidiSQLWindows

phpMyAdmin Web

Page 10: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Moving Files1. Find or create user credentials for both FTP and

database access. You may need to create a database if one doesn’t already exist

2. Move entire site from local directory to host

• Or, download and move WordPress core, theme, plugins, and uploads

3. Export database contents as .sql “dump” using database client, then import to host database

Page 11: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Preparing your site

Content stored in the database includes references to your site’s

previous domain. If this has changed as a result of moving from a

development site, or as a result of changing your domain, you’ll need to

replace all occurrences in the database. This is also necessary for

WordPress to recognize and use the new domain.

Replace old URLs

WP-CLI Search-Replace-DB

wp search-replace 'http://example.dev' 'http://example.com'

Page 12: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Preparing your site

If your site is hosted on a different server, you will need to update your

domain records to correctly point to the new server.

Update host records

• Tip: You can also modify a “hosts” file on your local computer

to test how your new server will respond to the domain before

making the real change

Page 13: Launching a WordPress Site 101 (Cincinnati WordPress, August 2015)

Demo