Theres a way to convert links like:
http://www.localhost.lh/?attachment_id=41
into:
http://www.localhost.lh/attachment/id
or:
Theres a way to convert links like:
http://www.localhost.lh/?attachment_id=41
into:
http://www.localhost.lh/attachment/id
or:
You must be logged in to post a comment.
here a simple WordPress rewrite rule to get the job done:
just add this code to your theme’s functions.php file and save.
*note: the index.php is regardless of your existing URL structure.
José Pablo
In addition to changing the permalinks settings in your dashboard to make pretty URL’s, you can create a folder named “attachments” in the root of your site to hold the files that you would like site visitors to download. In addition to uploading the files you wish to share, you should create (using notepad or any text editor) a blank file named index.html and upload it to the “attachments” directory. Adding the blank file will prevent people from browsing the directory and downloading all of the files unless you provide them with the specific URL.
Saludos
You could use a plugin like PrettyLink to create a friendly URL to redirect to the attachment. http://wordpress.org/extend/plugins/pretty-link/