← Back to team overview

registry team mailing list archive

[Branch ~pressflow/pressflow/6] Rev 98: If the URL for a file hasn't been modified by a CDN module, use the relative path. This improves ...

 

------------------------------------------------------------
revno: 98
fixes bug(s): https://launchpad.net/bugs/712923
committer: David Strauss <david@xxxxxxxxxxxxxxxx>
branch nick: 6
timestamp: Tue 2011-02-22 20:31:05 -0800
message:
  If the URL for a file hasn't been modified by a CDN module, use the relative path. This improves proxy compatibility and is closer to Drupal core behavior.
modified:
  includes/file.inc


--
lp:pressflow
https://code.launchpad.net/~pressflow/pressflow/6

Your team Registry Administrators is subscribed to branch lp:pressflow.
To unsubscribe from this branch go to https://code.launchpad.net/~pressflow/pressflow/6/+edit-subscription
=== modified file 'includes/file.inc'
--- includes/file.inc	2010-12-16 19:39:23 +0000
+++ includes/file.inc	2011-02-23 04:31:05 +0000
@@ -77,7 +77,7 @@
   else {
     switch (variable_get('file_downloads', FILE_DOWNLOADS_PUBLIC)) {
       case FILE_DOWNLOADS_PUBLIC:
-        return $GLOBALS['base_url'] . '/' . $path;
+        return base_path() . $path;
       case FILE_DOWNLOADS_PRIVATE:
         // Strip file_directory_path from $path. Private downloads' URLs are
         // rewritten to be served relatively to system/files (which is a menu