WordPress Tips and Tricks

Here are some WordPress tips and tricks.

  1. Force Login to View WordPress Pages

    Using plugin Force Login

  2. Posting Source Code in WordPress

    Using plugin Crayon Syntax Highlighter

    <pre class="lang:xhtml decode:true">
    // your code snippets
    </pre>
    

    Syntax Highlighter supporting multiple languages, themes, fonts, highlighting from a URL, local file or post text.

  3. Move WordPress From Local Server to Live Site

    Developing a WordPress site locally can help speed up the development process. And migrate your locally developed WordPress site to a live server.

    Step 1: Export Local WordPress Database to SQL gzipped file (no database create option)

    Step 2: Uploading WordPress Files to Live Site

    Step 3: Creating MySQL Database on Live Site

    Step 4: Importing WordPress Database on Live Site (by phpMyAdmin)

    Step 5: Changing the Site URL. In wp_options table. Update the siteurl and home

    Step 6: Config MySQL Connection. Edit wp-config.php file. Provide the database name, username, password and hostname

    Step 7: Fixing Images and Broken Links by updating Paths

    Whenever you are moving a WordPress site from one domain to another, or from local server to a live site, you would face broken links and missing images issue. You can either use the SQL query or use the Velvet Blues WordPress plugin.

  4. Update URLs When Moving WordPress Site

    Using plugin Velvet Blues Update URLs

    Using Velvet Blues Update URLs: Tools > Update URLs

    Read more: Moving WordPress

  5. Remove Category Base in WordPress URL

    If you want to remove /category/ from the url, follow these two steps:

    Step 1: Go to Settings >> Permalinks, in Common Settings select Custom Structure and enter: /%category%/%postname%/

    Step 2: In Optional, enter your Category Base to /

    Or using plugin WP No Category Base - WPML compatible

    Or if you using plugin WordPress SEO by Yoast, SEO > Advanced > Permalinks > Change URLs and enable option Strip the category base

  6. Turn the wpautop Filter ON and OFF

    Using plugin wpautop-control

    Using wpautop control options choose default (no changes), breaks (turn off WordPress's line breaks), off (turn off WordPress's auto-formatting): Settings > wpautop control

  7. Disable post revisions (not recommended)

    Add define('WP_POST_REVISIONS', false); to wp-config.php file.

  8. Remove all revisions and draft post

    Using plugin WP-Optimize

Comments

Popular posts from this blog

Reduce TIME_WAIT Socket Connections