TurnKey Linux Virtual Appliance Library

Wordpress Media Links

I am trying to use a Wordpress VM as a personal library for engineering information such as PDFs, spreadsheets, images, etc. I like the search features of Wordpress, and the fact that I can categorize information as I choose.

The Turnkey Wordpress VM resides on a USB drive.

The problem arises when I move the USB drive from one computer to another, as the IP address changes. This breaks all the links to the media files in the posts.

For example, this works fine on my home computer:

href="http://192.168.2.10/wp-content/uploads/2010/06/datasheet.pdf">datasheet

However, the network at work uses a different IP, and the link does not work. I really don't want to modify the network settings on my work machine.

If I modify the link as I am creating the post like this:

a href="../wp-content/uploads/2010/06/datasheet.pdf">datasheet

it works, but it seems clunky, and is an extra step.

Does anyone have a solution to this?

Perhaps I am using the wrong appliance. My goal is to create a portable, easily usable library of files. I tried the MediaWiki appliance, but that didn't work much better.

Any suggestions would be appreciated.

Liraz Siri's picture

You really shouldn't use absolute links...

Especially not if they point to a specific IP address. I'd recommend using relative links if possible, and if not, look into using a dynamic DNS service. I think there are a few free ones...

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)