2. Who is This Person? Declan O’Neill www.linkedin.com/in/declanon/ Twitter @declanon I’ve been working on websites since the mid-nineties, and working with WordPress since 2007. I moved to the US in 2006 from Ireland. I am an Account Manager for Logic by Design.
3. Scenarios? Newly-Launched WordPress Website. Google Analytics is showing results for error 404 pages. If you renamed a WordPress Category. If you renamed a WordPress Post or Page. Solution to a Common Problem: 301 Redirects.
4. A 301 redirect tells the bots and user-agents:? …that your page has been moved permanently. …to bypass the old link in the future and go directly to the new page. …to show the new URL in the searchresults.
5. .htaccess file among many other things: ...controls and overrides the Apache server configurations. …provides security measures such as using passwords to restrict access. …prevents hot linking (using images from your site). …instructs your server to rewrite URLs. …provides instructions to any redirection of URLs.
6. Old vs. New URLs Old URL = www.yoursite.com/about-us.html New WordPress URL = www.yoursite.com/about Google already knows about “about-us.html” but it does not exist anymore. So you must create a way to redirect “/about-us.html” to “/about”
8. Tools for Editing your .htaccess File You need access to the Server Files. You need FTP software to down / upload the file. You need a Text Editor to edit the .htaccess file. FTP Software: http://www.filezilla-project.org (Mac + PC) / http://fireftp.mozdev.org/ (Firefox Plugin) Text Editing Software: http://www.barebones.com/products/textwrangler/ (Mac) / http://www.pnotepad.org/ (PC)
9. Default WordPress .htaccess File This is how your WordPress .htaccess file should look like before you edit it.
10. Adding 301 Redirects Example: “redirect 301 /old.php http://www.url.com/new.php” Let’s break it down: redirect 301 (the instruction that the page has moved) /old.php (the original path and file name) http://www.url.com/new.php (new path and file name)
11. .htaccess file with 301 Redirects This is how your WordPress .htaccess file should look after you added the redirect.
12. 301 Redirect WordPress Plugins Go to: Admin > Plugins > Install Plugins Search for “301 Redirect” Look for a plugin called “Redirection” URL = http://urbangiraffe.com/plugins/redirection/
13. Adding a Page Redirect Go to: WordPress Admin -> Tools -> Redirection Add the old URL into the “Source URL” field. Add the new URL into the “Target URL” field. Click “Add Redirection”
14. Robots.txt Search Engines read your “website.com/robots.txt” file to get information on what they should and should not be looking for and where to find those files.
16. How Do I Add a robot.txt File You have two options: FTP to Server 2. WordPress Plugin
17. FTP robots.txt File to Server Open Text editor -> Add Code -> Save File -> Open FTP Software -> Add File to Root Folder -> Upload
18. robots.txt WordPress Plugin Step 1. Install the Plugin WP admin -> Install Plugins-> Search for “KB Robots.txt” -> Install Plugin Step 2. Configure the Plugin Admin -> Settings -> KB Robots.txt -> Add your Robots Rules -> Click Submit View the robots.txt http://wordpressannarbor.com/robots.txt
19. Next Talk Anothony Montalbano 4 Tips on Deeper Google Analytics for WordPress
20. Thank You Custom WordPress Web Design. www.logicbydesign.com @logicbydesign
Editor's Notes
Favorite / Book Marked Pages.You just got a website redesign and you upgraded to a WordPress CMS / Blog to manage your website content.You are wondering why Google Analytics is showing so many users landing on error 404 pages.
Editing the .htaccess file is risky; sometimes, misuse of the file can create an internal server error and make your site completely inaccessible to visitors -- or even to yourself!The .htaccess file is only applicable to Apache Linux-based server configurations; it is not applicable to IIS Windows-based servers.
You will need to add your individual 301 redirects to the .htaccess file one line for each page.
WordPress has some Plugin OptionsGo to: Admin > Plugins > Install PluginsSearch for “301 Redirect”
Specifying where search engines should look for content in high-quality directories or files you can increase the ranking of your site, and is recommended by Google and all the search engines.Ref: http://codex.wordpress.org/Search_Engine_Optimization_for_WordPress
Uploading your robots.txt file directly to the server via FTPUsing a WordPress Plugin
Step 1 : Open a text editorStep 2: add your code to the file.Step 3: Save it as “robots.txt”Step 4: Open up your FTP softwareStep 5: Add the robots.txt file to the root folder of your website.Step 6: Upload the File to the server.