Development

#2416 (url folders erros in sfMediaLibrary)

You must first sign up to be able to contribute.

Ticket #2416 (closed defect: fixed)

Opened 2 years ago

Last modified 2 years ago

url folders erros in sfMediaLibrary

Reported by: raphox Assigned to: francois
Priority: major Milestone: 1.0.14
Component: sfMediaLibraryPlugin Version: 1.0.0
Keywords: sfMediaLibraryPlugin sfMediaLibrary Cc:
Qualification: Unreviewed

Description

1.

In may aplication with config:

  • windows XP
  • Symfony 1.0.8
  • PHP 5.2
  • Apache 2

i have problems:

file sfMediaLibrary/modules/sfMediaLibrary/lib/BasesfMediaLibraryActions.class.php in line 51

$files = sfFinder::type('file')->maxdepth(0)->prune('.*')->discard('.*')->relative()->in($this->absCurrentDir);

return:

Array ( [0] => D:\htdocs\symfony_teste\web\uploads\assets\150_tits.gif [1] => D:\htdocs\symfony_teste\web\uploads\assets\image.png [2] => D:\htdocs\symfony_teste\web\uploads\assets\image1.png )

that the right should be (rum in my linux):

Array ( [0] => 150_tits.gif [1] => image.png [2] => image1.png )


2. In may aplication with config:

  • Ubuntu 7.04
  • Symfony 1.0.8
  • PHP 5.2
  • Apache 2

file sfMediaLibrary/modules/sfMediaLibrary/lib/BasesfMediaLibraryActions.class.php in line 140

sfConfig::get('sf_app_dir').$this->webAbsCurrentDir.'/'.$this->thumbnails_dir.'/'.$filename

return:

/var/www/symfony_teste/web/symfony_teste/web/uploads/assets/thumbnail/Paulinho_009.jpg

that the right should be:

/var/www/symfony_teste/web/uploads/assets/thumbnail/Paulinho_009.jpg

Change History

10/20/07 17:08:06 changed by raphox

  • summary changed from url folders erros in sfThumbnailPlugin to url folders erros in sfMediaLibrary.

11/07/07 10:20:29 changed by thibmonier

  • priority changed from minor to major.

11/29/07 11:23:38 changed by Nico

I have the same problem with Windows XP.

My problem is because my variable containing the url "$this->absCurrentDir" sended to sfFinder (line 59 of BasesfMediaLibraryActions?.class.php) contains '/' and '\'.

Example:

C:\dir\project\web/upload/img/



So in the in() function in sfFinder, the replace for relative url, line 342, doens't works fine...

11/29/07 11:26:04 changed by Nico

  • owner changed from fabien to francois.
  • component changed from plugins to sfMediaLibraryPlugin.

04/04/08 10:16:09 changed by noel

  • status changed from new to closed.
  • resolution set to fixed.

(In [8254]) fixed #2958, #2416, #3110 : relative file search with sfFinder (closes #3110)

04/04/08 11:14:45 changed by noel

  • milestone set to 1.0.14.

The Sensio Labs Network

Since 1998, Sensio Labs has been promoting the Open-Source software movement by providing quality web application development, training, consulting.
Sensio Labs also supports several large Open-Source projects.