Entries Tagged as ''

Customize WordPress Theme Add Home link To Your WordPress Blog

Adding a “Home” link on your WordPress blog can be as simple as pasting some HTML code into a text widget or a theme file. Or it can get as complex as adding a navigation bar to the header. Since I am too lazy to figure out an easy way to tell you how to code and add a navigation bar this WordPress guide will take the easy route to add a home link to your WordPress Blog.

There are any number of places you can add the Home link, and for some reason people like to have these “Home” links on their blog to keep their readers sticking around. My opinion is that most people are now smart enough to navigate a website without all this help but… well any way here you go. The first place we are going to add the link is on the sidebar, now this can be as simple as copying the code I’ve provided below and pasting it into text widget, changing the “Blog Home” part to what ever anchor text you want.

<a <?php if (is_home()) echo(’class=”current” ‘); ?>href=”<?php bloginfo(’url’); ?>”>Blog Home</a>

Or you could experiment with it and paste it directly into the sidebar.php file. If you choose this option make sure it is in an area above this code:

<?php if ( function_exists(’dynamic_sidebar’) && dynamic_sidebar(1) ) : else : ?>

So your code will look like this:

<a <?php if (is_home()) echo(’class=”current” ‘); ?>href=”<?php bloginfo(’url’); ?>”>Blog Home</a>

<?php if ( function_exists(’dynamic_sidebar’) && dynamic_sidebar(1) ) : else : ?>

You could add a background image using a simple table and specifying the location of the image. Make sure the image is always going to be available and live on the internet, I highly suggest using an image you are hosting or will upload to your website. Below is a simple table to center the “Home” link and image. Make sure you change the full image URL location so it will be visible:

<div align=”center”>

<center>

<table border=”0″ width=”100″ height=”30″>

<tr>

<td background=”http://www.ImageLocation.com/Full_Path_Of_Image” width=”112″>

<p align=”center”><a <?php if (is_home()) echo(’class=”current” ‘); ?>href=”<?php bloginfo(’url’); ?>”>Blog Home</a></p>

</td>

</tr>

</table>

</center>

</div>

The code above specifies no border, to add a border change the 0 to a greater number, and the size of the image is 100×30 you can change those numbers to make it bigger or smaller. The td background is the full path of the background image, to find the full path of an image using your Firefox browser simply right click the image and choose View Image and the image will show in its own URL, copy the URL in the address bar. If using Internet Explorer there isn’t that option available so stop using IE and switch to Firefox!

Other places to add a home link is in the bottom navigation on a single post. This is a bit trickier and you will need to edit the theme to do this. Most themes use a single.php file to show a single post, and most have the navigation to the next and previous posts. Some themes may use the index.php file if you don’t have a single.php file. You can also add a link to the blogs home in this area too. Before editing any files make a backup of it if you are new to editing WordPress theme files. Open the file to edit and look for the navigation code. Below I added the home link (in red) between the Previous and Next posts:

<div class=”navigation”>
<?php previous_post_link(’« %link’) ?>

<a <?php if (is_home()) echo(’class=”current” ‘); ?>href=”<?php bloginfo(’url’); ?>”> Blog Home</a>

<?php next_post_link(’%link »’) ?>

</div>

If the links are too close to each other or the side of the page you can add some space using the bit of code shown to space it out, if you want to add a little space between the links at the bottom of the page add a few hard breaks at the end of the code as shown. So the code used to add a space between the left side of the page and between the three links with a few spaces between it and the bottom of the page would look like below. The red code is the spaces between the links and two hard breaks creating the space at the bottom:

<div class=”navigation”>
&nbsp;  <?php previous_post_link(’« %link’) ?>  
&nbsp;       <a <?php if (is_home()) echo(’class=”current” ‘); ?>href=”<?php bloginfo(’url’); ?>”> Blog Home</a>
 
&nbsp; <?php next_post_link(’%link »’) ?>
<br /> <br />
</div>
<?php else: ?>
<div class=”post” id=”post-<?php the_ID(); ?>”>
<h2><?php _e(’Not Found’); ?></h2>
</div>

The places to add this or other links to your WordPress blog are only limited to your imagination and the time it requires to research more about editing and customizing your WordPress theme.

If you're new here, you may want to subscribe to my RSS feed. Thanks for visiting!


Tagged with , ,


Related Posts



The WordPress Upgrade Aftermath

In the previous post I talked about all the reasons to upgrade to version 2.6.+. After doing a few and researching some issues I thought I may warn you of what you may be in for.

First and foremost is backing up your files and database. Believe me this is critical because I needed it on all upgrades I performed. WordPress categories are not getting translated over in some instances and since I am still relatively “Geek Impaired” I had to manually add the categories back into the databases by hand. I researched this for quite some time and found no way import them into the database. So if any one reading this knows how to do it pelase share it with us!

Then there is the automatic upgrade options and plugins, well it seems that certain settings need to be set on the server for access to the tmp folder. If you don’t have access to or know how to make these changes then you are stuck with the same old manual upgrade process. I found that setting the file permissions to 777 on the entire blog or site may work to use these options but then you need to go back and secure your blog and change all the file permissions back. By the time I did all that I could have upgraded everything five times! Oh and one of my blogs got hacked in the short time I changed the settings to 777 throwing all kinds of porn links on a few posts. I noticed the site really crawling and then started seeing the porn posting and, oh hell it was a mess…

If you were or are using Ultimate Tag Warrior on WordPress prior to version 2.5 good news so far. With the import option, Manage, Import, Ultimate Tag Warrior in the dashboard, bringing back your tags and the post relationships was a snap. I wish there was a category option in there too! Well there is a WordPress import but I didn’t want to add duplicate content or know if it would recognize the old categories and convert them.

Some of the smaller blogs I upgraded for clients have been easier so far simply because they had only a few plugins and categories on them. But my other site took me a while to upgrade simply because it had a lot of plugin compatibility issues and way to many categories to manually add back.

All in all I guess it isn’t all that bad but if you are a complete newbie or very Geek Impaired I suggest you do your homework first or get some help!

If anyone can shed some light on the several issues I encountered on here feel free to comment, or contact me if you want to make a guest post here with the fix.

Here is short post on my other blog about the upgrade process: WordPress Upgrade Frustrations


Tagged with ,


Related Posts



Finally Time To Upgrade WordPress

post2.jpg

I have stated in the past that if you are happy with the way your WordPress blog is then there is no need to try to keep up with all the WordPress upgrades. It seemed as if a new version was coming up every week for a while there and trying to keep up manually was just a pain. Now with the use of a plugin and the integrated options in version 2.6.1 it’s much less painful keeping WordPress up to date.

It seemed as if a new version of WordPress was coming up every week for a while there and trying to keep up manually was just a pain. Other issues like plugin compatibility were also factors and will be if you are still using a version prior to 2.5. But now with the use of the WordPress Automatic Upgrade Plugin and the built-in automatic plugin upgrade it is much easier to keep your WordPress blog up to date. There may be some plugins left behind like Ultimate Tag Warrior so follow the steps below to make sure if something goes wrong you can fix it.

Download the WordPress Automatic Upgrade Plugin and follow the instructions to upload and activate it. Then just click the link on the top of your dashboard to Click Here to Automatically Upgrade WordPress to latest Version. Follow the prompts and upgrade your WordPress blog.

Next is the tricky part go to Plugins and deactivate all of them, then use the option under every out of date plugin to upgrade automatically. After all plugins are upgraded, this is critical, activate only one at a time and check your blog before going any further. If anything goes wrong and the plugin screws up your blog you will need to deactivate it or if you can’t do that you will need to delete the plugin on your hosting account. The path is YourWordPressFiles/wp-content/plugins.

Don’t bother even trying Ultimate Tag Warrior on your 2.5.+ version of WordPress and some have experienced issues with Smart Update Pinger as well. There has been known issues with comments showing on the posts but not in the dashboard if you started with version 2.3. Adding a key to the database will fix the comments issue as shown on the WordPress forum.

Yes I will offer an upgrade service but can’t set an amount because of all the different configurations and plugins out there it would be impossible to set one price for all. So Contact Me and will look over your particular blog and get you a fair price.


Tagged with , ,


Related Posts



WordPress 2.6 Write Post Guide

There has been some significant changes in WordPress since version 2.5 specifically in the write post screen. The Visual editor has some major changes as well as additional options added to the toolbar. This WordPress guide will show you some of the basics of writing and editing a WordPress post in Version 2.6.

The first thing you should do when writing a new WordPress post with the visual editor is to get familiar with the new toolbar options.Too see all the available options on the toolbar you need to click the Show/Hide Kitchen Sink button. This will show another row of options to use in the visual editor.

post1.jpg

Starting from left to right across the top of the toolbar most of these should be familiar to you if you have been using WordPress or any type of word process program. To see what an option will do just mouse over it to get a description. The big B is to make the text bold, The I to italicize text, next is to strikethrough text, or put a line trough it to look like you wanted to scribble it out like this. Dropping down to the lower toolbar is the U to underline text. To use these options just left click the text and highlight it, then click the appropriate toolbar button.

The next two are to start an unordered and ordered (or numbered) list. To start a list click the option first and the bullet or number 1 will appear. Type your text and hit the enter button to make the next list item. The large quote sign is to place the text in your particular WordPress themes styled quote box. You can either click the quote button before and after you type the text or use the highlight method after you have typed it all. To use it before you type the text click the quote button, type your text, then hit the Enter key on your keyboard once and then click the quote button to close the quote.

This is an example of a quoted line or paragraph for my particular theme, the way it looks in your theme will probably be different.

The next three buttons are to align your text left, center and right. Simply highlight the text or image you want to align and click the appropriate button to align it.

The next buttons that are sort of grayed out and look like a link of a chain is used to add links in a post. To add a link type in the anchor text that you want to be a hyperlink, highlight it and click the Insert/Edit link button. This will open a new pop up window to add the URL, choose the target to open in the same or new window, add an additional title and then the class will allow you align the link. Add the information in the window and click Insert to save it. The only option that is really needed in the Insert/Edit link window is the URL.

Next is the More tag button, this is very useful if you want only the first few sentences or paragraph to show on your blogs main or index page. I don’t use it on this site and instead use a modified index file to show the first full post and then the excerpts of all those there after. To use the More tag button simply place your mouse cursor after the text you want to show and left click. Then click the More tag button and a read more link will show on the post so the reader will need to click it read the entire post in its own page. The read more link is just a hyperlink to the posts permalink.

Next is the spellchecker that can be toggled on and off and the square button next to it is to open the full screen option. And of course the final top button is once again the Kitchen Sink option to show or hide the bottom row toolbar.

The lower toolbar starts with the Paragraph drop-down button to highlight text and make it look differently than the default text in a post. Past the underline button already covered is the Align Full button that will stretch a highlighted paragraph to take up the full content area like this paragraph is. Notice no white space on the right side of the paragraph except the last line?

The large A with drop-down will let you highlight text and make it a different color. The next two buttons are useful to paste copied text or code into a post. The T or Paste as Plain Text button can be use if you copied something from a Word document or website but don’t want to bring in any unwanted formatting or HTML code from the copied document or website. I suggest using this option if you ever copy something from one of the above mentioned. Formatting or HTML from another document or website can totally wreak your WordPress blog. The W or Paste from Word button can be used if you want to bring in the formatting from a Word document or website, but as I said some formatting can totally wreak your WordPress blog. The Paste from Word button is useful and can be used if you want to show examples of HTML code in a post. The little white eraser is used to remove any formatting you may have applied to any text. You first need to highlight the area of text to use this option.

The green Insert/edit embedded media is used to add video to a post, clicking it will open a new pop up window to choose the options. Next is the upside down looking Ω that will open another pop up window to insert special characters. Then there is the Outdent and Indent buttons and finally the ever popular Undo and Redo buttons.

One thing I suggest to look at if you are using the postname in your permalinks is at the very top of the write post box just below the title of the post. If you tent to use long post titles and use the postname in the permalink you should click the edit link on the permalink and shorten it to include just the main keywords of the posts content.

Just below that area is the new Add Media toolbar, here you can upload or add the url of images, videos and even music files. If you want to edit an image you have added to post simply left click it once and click the little image icon that will appear on the image itself. This will open the edit image window to allow you to fine tune the image’s settings.

Now scrolling down under the Write Post box are some more options. First are tags to add to the post. I usually use one or two tags that are keywords that describe the posts content. Under that are Categories, choose or add the proper category for your post in here.

Under categories are advanced options and all that really needs covered here are Excerpt and Trackbacks. As I said earlier I use the option Excerpts in all my post because my main or index page is setup to show them. This is optional and I suggest placing the first few sentences, first paragraph or a brief description in the Excerpt box. Finally are Trackbacks, these are used to reference another blog post you may be writing about. If it is a WordPress blog paste the URL of the post in the Trackback box and possibly a comment will appear on the referenced post that is an excerpt from your post. The trackbacked comment on the other blog post will also contain a link to you post, giving you an opportunity to gain traffic from the post your referenced.

Well that covers a pretty long post for today… or umm I should say for the week, I have been busy with other commitments and not posting as much as I have in the past. I do plan a pretty detailed upgrade guide to version 2.6 when I get around to upgrading myself!

An additional feature I overlooked is called Post Revisions. A new feature that automatically saves a copy of a post with each revision. Rather than go into detail I will refer you to WordPress Web 2.0 Spot-Er and Alex Sysoef’s post about this new feature and the possible drawbacks of it on this post:
WordPress 2.6 Creates Problem Under Disguise Of Feature


Tagged with , ,


Related Posts



Links List In A WordPress Sidebar Text Widget

Creating a list of links in a WordPress text widget is not hard to do if you know a little bit about HTML coding. If you don’t have any HTML knowledge you can still create a list in a WordPress text widget too, if you know where to find the right code to copy. This WordPress guide will show you how to find and copy the code to match the other lists shown on your WordPress sidebar.

First lets just create a simple list, this can be done using simple HTML code. Remember WordPress sidebar text widgets can accept HTML, plain text or scripts. Below is an example of a list of links, your theme may have a style for this type of list in its sytlesheet. If it does it will pick up the style that matches your sidebar. If not you will just have a simple list. Notice the first and third links open in the same window, the second link will open the link in a new window by using target=”_blank in the URL . The names of the sites; “Site One Name”, “Site Two Name” and “Site Three Name” are the anchor text or what will be shown as the link to be clicked.

<ul>
<li><a href=”http://www.site1.com/”>Site One Name</a></li>
<li><a href=”http://www.site2.com/” target=”_blank”>Site Two Name</a></li>
<li><a href=”http://www.site3.com/”>Site Three Name</a></li>
</ul>

Here is a little trick you can use to find the same code to use to match an existing WordPress widget list. Depending on what browser you are using, you are using Firefox right? No? Well you should be. Anyway when you are looking at your WordPress blogs main page with Firefox click View then Page Source on the tool bar and the code for your current page will show. Internet Explorer is similar click View then Source. Now you will see the source code of your blog. Next look for the area where the sidebar begins which is usually something like this: <div class=”sidebar”>. Now look for the type of widget you want to copy for your new text widget.

In the case below I used the Archives widget class to generate my list of links to look exactly like the Archives widget. Pay close attention to the code to make sure you get all the appropriate opening and closings tags. And In this case I am showing where to change the name from Archives to Change The Title Of The Widget Here. Placing all of that code in the text area will eliminate the need to use a title for the text widget, this is taken care of using “widgettitle” class. Simply copy all the code from the widget found in the souce code and change the tilte of the widget, the URLs and the anchor text.

    <li id=”archives” class=”widget widget_archives”><h2 class=”widgettitle”>Change The Title Of The Widget Here</h2>
<ul>
<ul>

<li><a href=”http://www.site1.com/”>Site One Name</a></li>
<li><a href=”http://www.site2.com/” target=”_blank”>Site Two Name</a></li>
<li><a href=”http://www.site3.com/”>Site Three Name</a></li>

</ul>
</li>

Remember it is very important to close all tags or you can really mess up the sidebar! You shouldn’t use the code here either, use the specific code from your current WordPress theme and it may need changed when changing themes. When you are done save your changes, check your blog and marvel at your handiwork! Remember if the girls don’t find you handsome they should at least find you handy!


Tagged with ,


Related Posts



Can’t Edit Sidebar Widgets In WordPress 2.6

Have you tried to edit sidebar widgets on WordPress version 2.6 and not been able to see the edit link on the current widgets? Well I have experienced this on Firefox version 3.0.1. While I don’t know of a fix yet there is no reason to panic.

Well the fix is quite simple because the edit link is still there just not quite visible. As you can see from the first image below I was not able to see the edit link in Firefox.

editwidgets.jpg

In the next image you will see the edit link image is visible in Internet Explorer version 7.0. I prefer Firefox over IE so this is a bummer.

editwidgets2.jpg

But the edit link is still there in Firefox, just mouse over the bottom right side of the widget and when your mouse finds the link your mouse cursor will change to its active link look and then you can open the widget.

editwidgets3.jpg

I haven’t researched this much but usually new versions of any applications like these tend to fix little things like this. So don’t panic and dump Firefox just click where the link should be and you can continue to use WordPress 2.6 and Firefox.


Tagged with


Related Posts



Close
E-mail It