Drain Hole Plugin

Jun 12, 2006 | Tags: , , , , | Written by Administrator

download

Download: drain-hole.zip
Version: 2.2.2
Updated: January 3, 2009
Size: 403.65 KB

Support This Plugin!

While this software is being provided free to use, it takes considerable time to develop and support. If you do find it particularly useful or want to request a feature then consider donating money as an incentive for me to carry on developing it.

Thanks!

I have other plugins too!

Drain Hole is a centralized download manager, with full monitoring and statistics, versioning, SVN support, and SEO download URLs (no more nasty query strings!).

In addition to it's monitoring abilities, Drain Hole has a run-time tag replacement feature that lets you embed special tags in your post which are replaced with information from Drain Hole. For example, you can embed download URLs, version information, last update times, and so on. Whenever you change a downloadable file it is automatically updated throughout your blog, without you needing to change anything else.

Features include:

  • SEO download URLs - a unique feature that allows files to look like real links
  • Local or remote file storage - keep your files on your own server or have them stored somewhere else such as Amazon S3 or wordpress.org
  • SVN support - attach a file directly to an SVN repository and have the contents automatically updated
  • Versioning - maintain multiple versions of a file, allowing users to download older files
  • Full download statistics, including number of downloads, access times, referrer, and download speed, available as CSV and Flash-based graphs
  • Download security - permissions can be assigned to downloads (including Flash files), restricting them to WordPress roles
  • Template tags - insert dynamic download data into posts, and into the sidebar as a Widget
  • Hot-link protection
  • Fully localized

Version History

  • 2.2.2 - Better display style
  • 2.2.1 - 2.7 styling, nonces
  • 2.2 - Using jQuery. Fix #336. Add feature #318
  • 2.1.12 - Allow for sites with open_basedir restrictions
  • 2.1.11 - Update plugin base class
  • 2.1.10 - Add file modification time
  • 2.1.9 - Fix problem with truncated URLs on some sites
  • 2.1.8 - Fix typo in mime type

Installation

Installation is like any WordPress plugin:

  • Download drain-hole.zip
  • Unzip
  • Upload drain-hole directory to /wp-content/plugins on your server
  • Activate the plugin
  • Use Drain Hole from the Manage/Drain Hole menu

You can find full details of installing a plugin on the plugin installation page. SVN access to the plugin is provided at the SVN repository.

General Concepts

The Drain Hole plugin makes use of two fundamental concepts:

  • Drain hole - a base URL and associated directory where files are stored and downloaded from
  • Files - a file belongs to a particular Drain hole

It is important to understand the mapping between a Drain Hole's URL and its associated directory. To do this you need to know two pieces of information:

  1. Where files are to be downloaded from (i.e. http://urbangiraffe.com/download/)
  2. Where files are to be stored (i.e /users/john/download/)

This is a mapping from URL to directory:

http://urbangiraffe.com/download/ => /users/john/download/

All files inside the directory will be available at the Drain Hole URL. For example:

/users/john/download/myplugin.zip => http://urbangiraffe.com/download/myplugin.zip

It is preferable that your directory is not in a public location (i.e. in public_html) as Drain Hole may not then be able to function. Your URL must be part of your WordPress installation, but you should not create a directory for it.

Creating a Drain Hole

New Drain Holes require the following information:

New Drain Hole

The URL is the URL on your website at which to make the files available. The directory is the real directory in which the files exist. These two values do not have to match up and the files do not (and ideally should not) be publicly available.

Once a Drain Hole has been created you can then edit it from the list of Drain Holes:

Drain Holes

Editing a Drain Hole will allow you to set additional options:

Edit Hole

The Access Level is the minimum user level required to download files from the hole. This allows you to restrict download access to certain types of user. If a user does not meet the required access level then they will be returned a 404 error page or will be redirected to the configured URL.

The Stop Hot-links option allows you to stop external users from downloading files in the hole. This protection is achieved by analyzing the referring page for a given download - if the referrer is not from your site then the user is sent a 404 error page or redirect to the error URL.

Files

A Drain Hole can contain any number of files and sub-directories.

Files

As with the rest of the plugin, columns are sortable, and data can be searched.

Each file allows you to:

  • Edit the file configuration
  • Manage version history (by clicking on the version number)
  • View download statistics (by clicking on the number of hits or the charts link)
  • Create a new version or update from SVN (by clicking on the branch link)

When editing a file you will be shown additional configuration details:

Edit File

The filename is the actual name of the file and this may differ from the name, which is what will be shown in a download link. If no name is given then the filename will be used. As an extra function, you can insert $version$ into the name and it will be replaced with the file's current version.

The description is a free-form field allowing you to enter further details about the download. This can be shown when the file is displayed.

The SVN field allows you to enter an SVN repository. See the SVN section later.

When displaying a file to download, an icon can be shown. You can change which icon is shown when editing a file.

The MIME type allows you to specify a custom MIME type for the file. This may be useful if you want a file to open inside the browser. If set to 'automatic' then Drain Hole will try and decide what the file is.

Forcing a download allows you to override default browser behaviour and force the file to always be downloaded. This is useful if you have a file that a browser usually tries to open (for example, a PDF), but you want it to always be downloaded.

Forcing the access level is an advanced option that is useful if you are trying to restrict files that are used inside Flash. For example, you may have a video tutorial that you want to restrict to registered users only. The flash video player requires your video file to be available, but may not provide any restriction options. Storing the video inside Drain Hole and then forcing the access level will ensure that only allowed users can access the file, even inside Flash.

Adding new files

New files can be added by any of these methods:

  • Uploading a file directly into the Drain Hole directory and 'rescanning'
  • Uploading a file through the browser
  • Creating an empty file which can be uploaded later, or which requires an SVN repository
Add File

Versions

Drain Hole allows you to retain old versions of files, either for archiving purposes or for user downloads. To modify a file's version you need to create a new branch:

Branch

You can enter details about the reason for the new version, and this will be presented to the end user. To retain an old version you must check 'retain old version'. This old version can be downloaded as follows:

http://urbangiraffe.com/download/myplugin.zip?version=1.2

SVN

Drain Hole provides simple SVN functionality that allows you to associate a file with an SVN repository. A file that uses SVN can then be 'refreshed' directly from the SVN repository, rather than requiring you to manually update the file.

SVN functionality requires that you have SVN installed on your host. You must configure the Drain Hole options and provide the full path to the svn executable. If you are in doubt you should consult your host for details.

When an SVN-based file is refreshed, Drain Hole will use SVN to retrieve the latest copy of the files. If a repository contains multiple files they will be automatically zipped.

As additional functionality, Drain Hole will detect if the SVN repository is for a WordPress plugin, and will automatically set the version according to the version information inside the plugin.

Note that no direct capabilities are provided for username and passwords. However, you can pass a username and password to SVN by including it on the SVN field:

http://svn.mysite.com/plugin/trunk/ --username=john --password=thing

Download As - Remote File Storage

With version 2.2, Drain Hole now allows you to keep your files stored on a remote server. For example, you may want to have the files stored on Amazon's S3. To achieve this you can enter the full URL of the remote file in the 'download as' field on a file.

Note that entering a filename in the 'download as' will allow you to have the file download with a name different to the original. Additionally, if you enter $version$ in this filename then Drain Hole will automatically replace it with the file's current version. This will be useful if you want one download URL that when clicked will download a versioned file.

Download Tags

The following tags can be inserted inside posts and pages to embed Drain Hole information. This information is generated dynamically, and will change whenever the underlying information changes:

  • [drain hole ID hits] - Displays the total number of hits from the specified hole ID
  • [drain hole ID show] - Show a list of all files in the specified hole (change display code by copying view/drain-hole/show_hole.php from the Drain Hole plugin directory to the same directory path in your theme's directory and editing the file)
  • [drain file ID show template] - Displays the download template for the specified file ID. 'template' is optional and can be ignored (the default template will be used)
  • [drain file ID version] - Displays the version of the specified file
  • [drain file ID versions limit] - Displays the specified number of versions from the file's history
  • [drain file ID hits] - Displays the total downloads for the specified file
  • [drain file ID url name] - Displays a URL allowing the specified file to be downloaded. 'name' is optional and is the text that will appear inside the download link (if not specified then the filename is used)
  • [drain file ID updated] - Displays the update time of the specified file
  • [drain file ID size] - Displays the size of the specified file
  • [drain file ID icon] - Displays the download icon for the specified file
  • [drain file ID href] - Displays the URL of the file

Where ID refers to the ID of the file or hole, as shown in the Drain Hole administration pages.

Download Templates & File Icons

A download template is a section of HTML code that is used to display all the information for a file download. For example, on this page in the top right corner is the download for Drain Hole itself. The icon and file information are all part of a download template that is re-used on each of the other plugin pages available from this site.

A download template is a file that is stored in your theme directory and contains standard HTML as well as special Drain Hole template tags:

  • $icon$
  • $url$
  • $version$
  • $updated$
  • $size$
  • $href$

These template tags function similar to the post & page tags, but do not require an ID to be specified.

A default template is provided with Drain Hole. Custom templates are PHP files that are stored in view/drain-hole, inside your theme directory. For example, if you are using the default WordPress theme then:

  /wp-content/themes/default/view/drain-hole/mytemplate.php

To use this template in a post you would insert the tag:

  [drain file 5 show mytemplate]

This tells Drain Hole to use 'mytemplate.php' to display file 5.

Custom icons can be stored inside your theme:

  /wp-content/themes/default/view/drain-hole/icons/

Statistics

Drain Hole provides full download statistics:

Statistics

FAQ

If you have any questions or problems then please consult the Drainhole FAQ before posting here.

Support

Please direct all support questions to the Drain Hole support forum. Any support questions left on this page may not be answered.

Bugs & New Features

A full list of all bugs can be found in the Drain Hole issue tracker.

A full list of all requested features can be found in the Drain Hole feature tracker.

Date Current requested features
14 Sep 2008 Multi-stage download
03 Nov 2008 limited access to drain hole(s)

Help me to save time by reading these instructions!

Please report bugs in the Drain Hole issue tracker.

Please make feature suggestions in the Drain Hole feature tracker.

Please direct all support questions to the Drain Hole support forum.

If you have any questions or problems then please consult the Drainhole FAQ before posting here - any duplicate questions left here will be deleted.

Share This

Comments (page 4 of 7)

  1. aantn :

    Dec 3, 2007 10:29 am | Reply

    Hello, I love the plugin.

    I have one small question. How do I add a new file for a new branch/version. Shouldn't there be a place to upload a new file when you click on "New Branch"?

  2. Sid :

    Dec 7, 2007 9:46 am | Reply

    I see there is a checkbox named "Google analytics tracking" under "Options" tab, however it does not ask me for the tracking ID. Does it work? How it does? :D
    Hey John, wonderful work!

  3. tino :

    Dec 17, 2007 10:40 am | Reply

    Is it possible to have something like that:

    Let say I have on one page 10 files. If somebody wants to download a file and he will click on it he will be redirected to the page where he has to give for example his e-mail address. After that he will be able to download this file and every other. So maybe use for that cookie.

    ??

    Great plugin.
    Tino

  4. razor :

    Dec 17, 2007 4:20 pm | Reply

    im havin some trouble, everything has installed correctly

    i placed a tag on my site but its not working

    URL is set to /downloads
    dir is set to /home/hvdesig/HV_DOWNLOADS

    when you hover over the link it says "http://hv-designs.co.uk/downloads/filename.zip" but when clicked it doesnt work i get 404 :(
    any ideas?

  5. Sid :

    Dec 17, 2007 4:49 pm | Reply

    razor, the only thing I tell you is to check if you wrote the tag [drainhole bla bla bla] in the code section and not in the wysiwyg...

  6. Sid :

    Dec 17, 2007 4:51 pm | Reply

    sorry, that was not a good hint

  7. razor :

    Dec 17, 2007 5:00 pm | Reply

    it has been wrote in the code section :)
    ive tried renaming url to URL is set to /wordpress/downloads (my wp is located in wordpress)

    also tried removing the hotlink protection as someone eles suggested and still nothing!
    :(

  8. John (author) :

    Dec 18, 2007 4:41 am | Reply

    DanyO, you can already add your own custom icons - see the above section 'Download Templates & File Icons'.

    Aantn, whenever you upload a file (via FTP or from the upload form) it overwrites the current version. Therefore if you create a new version and then upload the file it will achieve the effect you are looking for.

    Tino, you can do that if you ask the downloader to register at your site.

    Sid, the Google Analytics tracking assumes that Google Analytics is enabled on your site. It works by telling Analytics to monitor clicks to any download link

    Glenn, you can call the_drainhole_stats();

    Joel, show_hole.php should already display the name in preference to filename. The code you have for $name->file won't work. I've changed the 'hole show' tag to order by name

    Karimun, <?php echo $file->version; ?> will show the file version.

    Curtis, redirection is no longer needed so it will have no effect if you enable or disable it. Do you have permalinks enabled? Is the 'download' directory in your WordPress home?

    Curtis, the same questions for you too - is the downloads directory available inside your WordPress installation?

  9. tino :

    Dec 18, 2007 4:50 am | Reply

    "Tino, you can do that if you ask the downloader to register at your site" yes John I know that but I don't want the downloader to go to the registration page. Simply only to page where he writes his e-mail and thats it.

  10. John (author) :

    Dec 18, 2007 5:23 am | Reply

    Tino, that functionality isn't in Drain Hole and the registration step is all you can do for the moment. I'll have a think about it for the future.

  11. razor :

    Dec 18, 2007 5:56 am | Reply

    any ideas on a solution for my problem??? im desperate to get this plugin too work, ive tried others but yours is better 10 times over

  12. razor :

    Dec 18, 2007 6:05 am | Reply

    ive read throu the whole list of comments and im still non the wiser :(
    im havin some trouble, everything has installed correctly

    i placed a tag on my site but its not working

    URL is set to /wordpress/downloads
    dir is set to /home/hvdesig/HV_DOWNLOADS

    when you hover over the link it says "http://mysite.co.uk/downloads/filename.zip" but when clicked it doesnt work i get 404
    any ideas?

    help much appreciated

  13. John (author) :

    Dec 20, 2007 12:40 am | Reply

    Razor, do you have permalinks enabled? What version of WP are you using? There's not a lot I can suggest here, but if you want to send me an admin login to your site then I'll take a look and see if I can figure out what's happening.

  14. razor :

    Dec 20, 2007 1:41 pm | Reply

    using version 2.2.2
    and permalinks in options is set top default

  15. mhd zaher ghaibeh :

    Dec 24, 2007 10:31 am | Reply

    i have the same error .
    each time they order a file they got 404

  16. razor :

    Dec 24, 2007 10:53 am | Reply

    well please explain how you solved it

  17. mhd zaher ghaibeh :

    Dec 25, 2007 3:36 pm | Reply

    first you have to make sure that your permalink is set to "Date and name based" not the default one .
    and your configuration :
    URL is set to /wordpress/downloads
    dir is set to /home/hvdesig/HV_DOWNLOADS

    should stay the same ..
    in this case your gana to make sure that url mapping will work just fine

  18. razor :

    Dec 26, 2007 5:09 am | Reply

    hmm il try changing my permalinks then to see if that works!

    thx for gettin back

  19. aantn :

    Dec 26, 2007 9:39 am | Reply

    So what does retaining the old version do?

  20. razor :

    Dec 26, 2007 5:34 pm | Reply

    problem solved thanks "mhd zaher ghaibeh" much appreciated

  21. Craig :

    Dec 28, 2007 5:40 pm | Reply

    John,

    Why do you state "A default template is provided with Drain Hole." And then say that one isn't provided in the plugin's thread? You should remove the sentence, it would have saved me some time.

    Actually, it would be nice if you did provide a sample template!!! (I know ... only so many hours in a day :)

    Thanks for another great plugin. Installing on a client blog now and will leave a post about the experience.

    --Craiger

  22. razor :

    Dec 29, 2007 12:55 pm | Reply

    there is one..... its the same as the one the author has used

    default_show.php

  23. dubó :

    Jan 4, 2008 5:11 pm | Reply

    Please excuse my ignorance,but there's a few things i can't get clear:

    - to link a file, i MUST use this format to get stats??? [drain file ID url name]. if i just link it with html, what will happen? just no stats?

    - is there a way to embed a player and count this as a download? i mean, theres a plugin that uses this format:

    [audio:http://blabla.com/audio.mp3]

    i guess i cannot use something like this:

    [audio:[drain file ID url name]]

    is there a way to do this?

    thank you!

  24. dubó :

    Jan 5, 2008 1:46 pm | Reply

    i get no stats

    in this post i used the plugin:
    http://super45.cl/2008/01/04/avance-de-nuevo-disco-de-whomadewho/

    i put this tag:
    [drain file 49 url Who Made Who - New 2008 Album Teaser]

    but no statistics are registered

    i tried downloading the file a lot of times from other browsers and computers, and it works, but no hit is added in the drain hole statistics. any idea?

  25. SEO Blogger :

    Jan 6, 2008 1:00 pm | Reply

    Hmn... Sadly, I can't get this plugin to work, because I have a master domain/user (with HostGator) that is used to host multiple domain and the path to the DomainName I want to use is: /home/masterdomainuser/public_html/DomainNameForDrainHole/

    So, I'm wonder if this plugin can be used if I host at HostGator (or similar webhost with the same path as above). And if this plugin can be used, please add some "how to" documentations, as I really would like to use this plugin (instead of the current Download Counter plugin => uses similar concepts as this plugin =).

  26. Grant Novey :

    Jan 7, 2008 4:09 pm | Reply

    When I installed the drain-hole plugin, it created an icon in the visual editor to add a file to a page. This icon only appears in Firefox and not IE. I'm using version 6 of IE.

    Anyone else had this problem?

  27. Sid :

    Jan 7, 2008 6:51 pm | Reply

    Hi John,
    I've found a big (for me) bug in permalinks in your plugin. However this bug seems to appear only to me: not found on the internet!

    I think it depends on my 'access error url' or 'stop-hot-link' settings (seem to happen after I modifyed them, but not sure!). Maybe on my provider setting...
    The bug 'happens' only if permalinks are turned on (and your plugin).

    The bug is an error string appearing in the head of every page and every RSS (not in every entry, but in the entire FEED, corrupting it):
    Warning: preg_match() [function.preg-match]: Unknown modifier '.' in /.../wp-includes/classes.php on line 99
    Warning: preg_match() [function.preg-match]: Unknown modifier '.' in /.../wp-includes/classes.php on line 100

    Those lines are:
    if (preg_match("!^$match!", $request_match, $matches) ||
    preg_match("!^$match!", urldecode($request_match), $matches)) {

    These lines are executed a lot of times when loading the page, but just one time them fail. Excelly the passed parameters ($request_match and $matches) are always the same, so I don't understand of what '.' modifier parameter the error is talking about...

    Those errors persist after you disable Drainhole and disappear if you delete the rewrite_rules record in the _options table of the DB.

    I do not understand regular expressions. Maybe the bug is updating hooks to files in holes in that record (which you do in drainhole.php)...

    An example of that record which *maybe* is the reason of that bug is available here:
    http://www.sugata.eu/public/eMail/pregmatch.txt

    Cheers!
    Sid.

  28. Sid :

    Jan 7, 2008 6:53 pm | Reply

    PS) You won't see the error in my blog because I embraced those lines with ini_set('display_errors', 'x');

  29. John (author) :

    Jan 10, 2008 10:36 pm | Reply

    Sid, does the new version change anything?

    SEO Blogger, I see no reason why you shouldn't be able to use the plugin. Hopefully the documentation on this page should be sufficient - just pick a directory and a URL and that's it.

    Dubo, you can link to a file anyway you want. The Drainhole tag method is for convenience, but you can link directly. You can link directly to a file from inside another plugin:

    [audo:http://your.file.com/file.mp3]

    If you are getting no statistics then please read the Drain Hole FAQ.

    Craig, a default template is provided and is automatically used. My comment said that no template called 'mytemplate' is provided.

    Aantn, an old version is simply an older version of a file which you may want users to be able to download. For an example of this see the version history on this page where you can download older versions of the plugin.

    Razor/mhd, permalinks can be set to anything other than the default, not just 'date and name based'.

  30. Sid :

    Jan 11, 2008 8:42 am | Reply

    Yeah, it works! Great job :) What was the problem about it?

  31. Sid :

    Jan 11, 2008 8:47 am | Reply

    I see it was about the special characters :) thanks again!

  32. dubó :

    Jan 11, 2008 2:52 pm | Reply

    Thank you John! Is working perfectly!!!

  33. Tan The Man :

    Jan 13, 2008 4:52 am | Reply

    Very cool plugin. Mucho gracias.

  34. Sid :

    Jan 14, 2008 10:57 am | Reply

    Is there anyway to get only the URL of the file (not an HTML string with the a tag) inside the template file?

  35. tino :

    Jan 15, 2008 4:04 am | Reply

    When I click on downloads in the submenu I get the list:
    Downloaded At | File | IP | User | Referer

    The problem is when I wont to search thru this list.

    I get this error:

    WordPress database error: [Unknown table 'file' in where clause]
    SELECT SQL_CALC_FOUND_ROWS wp_drainhole_access.*,wp_drainhole_files.file,wp_users.user_login FROM wp_drainhole_access LEFT JOIN wp_drainhole_files ON wp_drainhole_access.file_id=wp_drainhole_files.id LEFT JOIN wp_users ON wp_drainhole_access.user_id=wp_users.ID WHERE (file.file LIKE "%exp%") ORDER BY created_at DESC LIMIT 0,25

    The where clause cause this problem. And by the way, from this query I see that search is only provided for file. Is it possible to add in this WHERE clause also argument so it will look also for IP? Where can I change it, in what file?

    I using the newest version 2.0.14

    Regards,
    Tino

  36. tino :

    Jan 16, 2008 6:06 am | Reply

    Oh and one more thing.

    What can I do to prevent opening file if someone knows the direct path. For example google shows direct path.

    The problem is that I cannot pick a directory outside of your public_html.

    Any advise?

    Thanks,
    Tino

  37. John (author) :

    Jan 16, 2008 11:24 pm | Reply

    Tino, if you can't pick a path outside of public_html then you need to create a .htaccess file in the download directory. See the FAQ for more details. I've released a new version which should fix the search problem. Currently it's not possible to search IP addresses as they are stored as decimal numbers, not strings of characters.

    Sid, the new version has $href$ which returns only the URL

  38. Mel :

    Jan 17, 2008 4:03 pm | Reply

    John:

    Great plugin! But I just ran into a problem when I upgraded to 2.0.15. The file show tag ceased to work in my pages. The Hole Show tag worked fine, and file hits and file url tags worked but not file show. I rolled back to version 2.0.14 and now everything works great again.

    THanks again for a great plug-in.

  39. Rishi :

    Jan 20, 2008 2:30 pm | Reply

    Great plugin! I just set up all my holes and got them working on my WP pages; however, the stats still aren't working. I read the FAQ section about the htaccess, and my htaccess looks like:
    RewriteEngine On
    RewriteRule ^(.*)$ /home/rishi-ku/public_html/index.php

    My directory structure is like this: My WP is installed in /home/rishi-ku/public_html and my holes are in /home/rishi-ku/public-html/wp-content/files
    Where do I need to put the htaccess file? I tried putting it in several places, but I ended up losing my theme. Thanks for your time!

  40. Sid :

    Jan 20, 2008 2:38 pm | Reply

    Rishi, it is better if you put your drainhole in a private directory. The htaccess file can be generated by the plugin if you turn on the option. Don't know if it helps.

  41. Rishi :

    Jan 20, 2008 3:08 pm | Reply

    I tried to put a test hole at /home/rishi-ku/public_html/notes (with the create htaccess option enabled before-hand) and I populated it with some random files. I added the hole to a page, clicked on numerous links, refreshed the page several times, and tried to access the stats on the admin interface. It said there were no downloads. I appreciate your prompt reply though!

  42. Christopher O'Connell :

    Jan 21, 2008 4:53 am | Reply

    First of all, allow me to say, amazing plug-in.

    I have several thoughts, however:

    [bug report moved to issue tracker (and #31 and #32)]

    ~ Christopher

  43. Rob Butler :

    Jan 21, 2008 5:25 pm | Reply

    I'm a little lost here. I've used drain hole on my blog and it looks like just what I want.

    I wanted to hide my files I'm serving in a directory that is not accessible to the public - and they all show on the list of files available. When I try to download one I get a 404 error. I've followed the advice with permalinks to no avail.

    At the moment I haven't restricted access to subscribers while I get the setup working but that is my intention. I've ready the FAQ and the comments but I'm still at a loss as to what to do next?

  44. Tim :

    Jan 21, 2008 8:25 pm | Reply

    I'm having the same 404 error as referenced by several people above (#141 and #192 and others). I can access the files from within a post, but not from within a page buried in the site. I'll try the solution mentioned above (#141 by Lee) but would love to know if there's a way to alter the plugin itself to handle this. John - is this even possible?

  45. Tim :

    Jan 21, 2008 9:45 pm | Reply

    Additional info about my 404 error:

    1. It works when the post is on the front page, but not when the post is access elsewhere on the site (i.e. when permalinks show up in the URL).

    2. The URL for my blog is in this form:
    http://12.34.56.789/~mylastname/myblogname
    ...but when I enter this as the Drain Hole URL:
    /~mylastname/myblogname/downloads/
    ...it strips out the ~ and leaves:
    /mylastname/myblogname/downloads/
    Is that the problem?

    3. If I just enter the Drain Hole URL as:
    /downloads/
    ...it works on the front page but not when that same post is accessed from anywhere else. In those situations I get the 404 and this shows up in the address bar:
    http://12.34.56.789/mylastname/myblogname/2008/01/18/postname/downloads/filename.pdf

    Is it something I'm doing wrong, or the fact that the ~ gets stripped out, or something else? Thanks, in advance, for your help.

  46. Tim :

    Jan 22, 2008 9:33 pm | Reply

    Fixed. As a workaround, I created a subdomain. So instead of having:
    http://12.34.56.789/~mylastname/myblogname

    ...I now have my WordPress site at:
    http://blog.domain.com

    It was the long-term plan anyway, but this just created some extra incentive to do it right away. And, sure enough, it fixed the problem. I'm still not sure whether it was the ~ (tildee?) symbol or something else, but it works now. I hope this info helps someone with a similar problem in the future.

  47. Grant Novey :

    Jan 23, 2008 12:29 pm | Reply

    I think it would be great to be able to move files to different drain holes. Otherwise, this plugin is great.

  48. Kat :

    Jan 25, 2008 5:39 pm | Reply

    Ok, i'm running my wordpress from domain.com/blog/

    i've got permalinks enabled: (custom structure: /%category%/%postname%/)

    RewriteEngine On
    RewriteBase /blog/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /blog/index.php [L]

    I cannot get the download link to validate. it forwards to a 404.

    my URL is set to /blog/download

  49. Joan :

    Jan 26, 2008 5:41 pm | Reply

    You missed the changelog for this new version :P. Thx for this great plugin ;).

  50. Infect The System :

    Jan 31, 2008 12:40 pm | Reply

    Is it just me, or when a file gets a hit, does it show as 7 hits? I uploaded a new file last night, and immediately tried to download it just to make sure it was working, and when i checked the hits on it, it showed 7. Any reason why?

Pings & Trackbacks

my.donews.com, my.donews.com, westblog.8866.org, wp-plugins-db.org, tuxicodine.net, david.scatigna.it, tuxicodine.net, manuelviloria.com, joelteixeira.net, foliovision.com, canalmoins.fr, joelteixeira.net, winnyspot.com, labellechev.com, birosketchbook.com, trupela.com, patronit.net, patronit.net, wp-plugin-archive.de, trupela.com, qubenzis.com, dougal.gunters.org, dougal.gunters.org, schonhose.nl, michael-wagner.org, myqute.com, schonhose.nl, startcreatemakeblog.com, bloggerdata.com,

Leave a Reply


XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Help me to save time by reading these instructions!

Please report bugs in the Drain Hole issue tracker.

Please make feature suggestions in the Drain Hole feature tracker.

Please direct all support questions to the Drain Hole support forum.

If you have any questions or problems then please consult the Drainhole FAQ before posting here - any duplicate questions left here will be deleted.

Home | Software | Terms & Conditions | Sitemap | John Godley © 2008
Close
E-mail It