Stuff to remember during installation

  • Use a strong password for the database - as well as unobvious database name and user. Stay secure.
  • Don't use the default table prefix - choose your own 2 or 3 letter prefix. This helps protect against some established Wordpress database attacks
  • Use an obscure Wordpress username - at the configuration stage, don't choose a username like admin. Try to use something that's not obvious. This again is for security reasons.Make sure you remember it though!
  • Leave the privacy box ticked - unless you want your website to remain unknown

Essential Plugins

  • wordpress-backup-to-dropbox - backup your wordpress site to your dropbox account
  • google-analytics-for-wordpress - learn who's visiting your site and what they're doing via google analytics
  • w3-total-cache - make your site faster
  • wordpress-seo - make sure people can find your site
  • wordfence - keep the hackers out of your site
  • jetpack - an inmpressive assortment of extras for your site like carousels, publicise, spelling & grammar, etc, etc
  • sss-plugin - allow people to share your site on social media by Karol Krol ( http://karol.cc ), the author of Wordpress 4.x Complete from which I borrowed this list (thanks Karol)
  • askimet - antispam (usually installed by default)

Theme hierarchy

 style.css – the theme’s official stylesheet with theme info
 index.php – ultimately the fallback page for anything without a unique theme file
 home.php – your blog’s homepage whether static or archive content
 single.php – a single post/article layout
 page.php – a single page layout
 archive.php – used as a catch-all for archives like categories, tags, authors, and dates 
 404.php – the default 404 error page layout 

Updating a theme

Rather than directly editing a theme, the best way to update a theme is by creating a child theme from it. In this way, if the theme is updated, you don't lose your changes. You can also quickly revert back to the original theme should that be required.

Here is how to create a child theme. I am updating a theme called Simply Pure (which is the theme used for our blog)

In the themes directory do the following:

 cd wp-content/themes
 
 mkdir simply-pure-child
 
 cd simply-pure-child
 
 vi style.css
 
 /*
 Theme Name: Simply Pure child theme
 Theme URI:  http://www.best2know.info/simply-pure-wordpress-theme/
 Author: Ritesh Sanap
 Author URI: http://www.best2know.info/
 Version: 1.1.5
 Description: Child theme for a Personal blogging wordpress theme, made with Yahoo's Pure CSS. Simply Pure is a responsive WordPress theme with Two-columns and 3 widget footer.
 License: GNU General Public License v2.0
 License URI: http://www.gnu.org/licenses/gpl-2.0.html
 Tags: blue, two-columns, responsive-layout, custom-menu, featured-images
 Text Domain: simply-pure
 Domain Path: /languages
 Template:simpy-pure
 */
 @import url("../simply-pure/style.css");

The important lines are Template (tells wordpress it's a child theme) and the import of original template CSS file. BTW, simply-pure is the name of the parent theme directory. Initially I had a spaec between Template: and simply-pure and that broke it (came up with missing parent theme) so you need to be careful

Now start customising and activate the child theme when ready. I had to tweak sidebar.php and header.php to get the effects I wanted in addition to css styling in the style.css file. So I copied these files from the original theme then edited them

cp simply-pure/sidebar.php .
cp simply-pure/header.php .

I also wanted to make use of a different font so I created a fonts directory and added the font files in there. In the end my child directory contained the following:

./fonts
./fonts/Lobster_1.3.otf
./fonts/Lobster_1.3.woff
./fonts/Lobster_1.3.svg
./fonts/Lobster_1.3.ttf
./fonts/Lobster_1.3.eot
./header.php
./sidebar.php
./style.css

As an example of the kind of things you can do with style.css, here's my file:

/* 
Theme Name: Simply Pure child theme
Theme URI:  http://www.best2know.info/simply-pure-wordpress-theme/
Author: Ritesh Sanap
Author URI: http://www.best2know.info/
Version: 1.1.5
Description: Child theme for a Personal blogging wordpress theme, made with Yahoo's Pure CSS. Simply Pure is a responsive WordPress theme with Two-columns and 3 widget footer.
License: GNU General Public License v2.0
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: blue, two-columns, responsive-layout, custom-menu, featured-images
Text Domain: simply-pure
Domain Path: /languages
Template:simply-pure
*/
@import url("../simply-pure/style.css");

/* customisations */
@font-face {
    font-family: 'Lobster';
    src: url('fonts/Lobster_1.3.eot');
    src: url('fonts/Lobster_1.3.eot?#iefix') format('embedded-opentype'),
         url('fonts/Lobster_1.3.woff') format('woff'),
         url('fonts/Lobster_1.3.ttf') format('truetype'),
         url('fonts/Lobster_1.3.svg#ColaborateThinRegular') format('svg');
    font-weight: normal;
    font-style: normal;
}
.header h1 {
  font-family: 'Raleway' , sans-serif;
}
.post-header {
  font-family: 'Raleway' , sans-serif;
}
.post-body {
  font-family: 'Raleway' , sans-serif;
}
.sidebar {
  background-size: cover;
  background: #a9b6bc;
  color: #fff;
}
.sidebar .header {
  background: #a9b6bc; 
}
.sidebar .header h1 {
   font-size: 2em;
   font-family: 'Lobster';
   text-shadow: 4px 4px 2px rgba(47, 47, 47, 1);
}
.sidebar .header .pi {
   color: pink;
}
.sidebar .header .ye {
   color: yellow;
}
.sidebar .header .pi {
   color: pink;
}
.sidebar .header .ye {
   color: yellow;
}
.site_title {
  text-transform: capitalize;
}
.site_description {
  color: #fff;
}
.nav-list li:nth-child(odd) a {
  color: yellow;
}
.nav-list li:nth-child(even) a {
  color: pink;
}

Recent Changes