Skip to main content

Home/ Drupal for Developers/ Group items tagged public

Rss Feed Group items tagged

Hans-Peter Zahno

Directory of Public Features Servers | groups.drupal.org - 3 views

  •  
    Considering the power of the Features module I'm surprised this list of public features servers is so small. Hopefully it will grow. Currently there isn't even a decent image gallery feature on any of these public features servers.
Scott Blackburn

Useful posts for configuring OG | drupal.org - 0 views

  •  
    No public posts in this group
Daniel Gregoire

Restrict specific folders from public download (via .htaccess) | drupal.org - 0 views

  • If you set "public" as the download method, you can still protect some of your folders by settings in your .htaccess file, if you have mod_rewrite enabled. For instance, if your files live in sites/default/files, and you want to protect everything in sites/default/files/protected_download_dir, then you can add the following line to your central .htaccess file: RewriteRule ^sites\/default\/files\/(protected_download_dir\/.*)$ index.php?q=system/files/$1 The files in this folder (or, all files that match the regular expression) will not be served directly by apache, but by a full drupal request using the file_download() callback. The routing for system/files is defined in system_menu(). Access Checking for File Downloads Modules can do access checking on files downloaded through file_download(), by implementing hook_file_download(). For instance, the filefield module will do access checking for all files that you upload via filefield. It will only give access to people who are allowed to see the node and the field the file belongs to. In addition, you can look for modules that restrict file downloads based on the folder name or other criteria. Access Checking built-in with Filefield The filefield module has access checking built-in. To make use of this, please Make sure to use the latest dev version of filefield (for now). The current offical release (08/2009) has a bug in access checking. Have a look into filefield issue 516104. Configure the filefield you want to protect. Use the filefield path module, to define where the files for the filefield should be stored by default. Add a line to your .htaccess to protect this folder (see above). Use whatever modules to restrict node or field access.
1 - 5 of 5
Showing 20 items per page