Adding Links

This should be an easy thing to do. I added a page and created an unordered list of links. Done!

While looking at the WordPress admin options, I noticed a section for Links. That seemed a much better way to insert links. After all, if the functionality is already built in, why write the HTML code manually?

The problem is that the collection of links only seem to be used by the built in Links widget. This will limit it to the sidebars, which isn’t what I want. I want the list to be displayed on a page.

The solution is the wp_list_bookmarks() function. Create a page template then insert that function into the template.

Create a page and set the Links template you just created as the page template. There’s no need to put anything in the content section. Populate the Links area and WordPress will do the rest.

Another advantage of this method is that the task of keeping the links list updated can now be passed over to a non technical user as the interface is pretty simple.

Advertisements

2 thoughts on “Adding Links”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s