How to Store links in a portable way

Do you save web links (shortcuts) to your file system? If not, you can skip this post.

The problem we have to solve is how to store a web http link to your filesystem so that once you double click it, the URL opens.

In windows you could create url files like in this example.

In linux you could create .desktop files like in this example.

Which is the best way? None. Because both solutions are not platform independent. If you choose to change your operating system later on, none of your links would be working.

The neutral way is to create a simple html file as shown below:

<html>
<head>
<meta http-equiv="refresh" content="0; url=http://example.com/" />
</head>
</html>

Double click the html file and voila, the page will open.

Obviously, you can change to URL to whatever you like.

 

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

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

Google photo

You are commenting using your Google 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 )

Connecting to %s