PiRSquared17 / mediawiki-page-attachment

Automatically exported from code.google.com/p/mediawiki-page-attachment
Other
0 stars 0 forks source link

Fatal Error: Class ListFiles not found #31

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
As reported on
https://www.mediawiki.org/wiki/Extension_talk:PageAttachment#Fatal_Error:_Class_
ListFiles_not_found_8360
there had to be a small modification in SetupExtension.php to resolv this issue:

Old:
## Special Pages (Unlisted)
$wgSpecialPages['PageAttachmentListFiles']        = 
'\\PageAttachment\\BrowseSearch\\ListFiles';
$wgSpecialPages['PageAttachmentUpload']           = 
'\\PageAttachment\\Upload\\Upload';
$wgSpecialPages['PageAttachmentAuditLogViewer']   = 
'\\PageAttachment\\AuditLog\\AuditLogViewer';

New:
## Special Pages (Unlisted)
$wgSpecialPages['PageAttachmentListFiles']        = 
'PageAttachment\\BrowseSearch\\ListFiles';
$wgSpecialPages['PageAttachmentUpload']           = 
'PageAttachment\\Upload\\Upload';
$wgSpecialPages['PageAttachmentAuditLogViewer']   = 
'PageAttachment\\AuditLog\\AuditLogViewer';

You are able to reproduce it on
Ubuntu 10.04 LTS with all patches and mediawiki 1.18.0 (installed through 
tar.gz) and downloaded PageAttachment-extension 
http://mediawiki-page-attachment.googlecode.com/files/mediawiki-page-attachment-
2.0.0.zip

Hope you can fix this soon.

Original issue reported on code.google.com by daniel@dseichter.de on 4 Jan 2012 at 12:06

GoogleCodeExporter commented 9 years ago
Hi Daniel:

What version of PHP you are using?

Aldrin

Original comment by Aldrin.Baroi@gmail.com on 4 Jan 2012 at 8:07

GoogleCodeExporter commented 9 years ago

Original comment by Aldrin.Baroi@gmail.com on 4 Jan 2012 at 8:08

GoogleCodeExporter commented 9 years ago
Okay, got the PHP version from the discussion page (PHP 5.3.2)

Two issues identified for PHP 5.3.0 - 5.3.2:
1) For "SetupDatabase" class, "setupDatabase" method is being treated as a 
contructor.  See: http://php.net/releases/5_3_3.php
2) Fully qualified class names are being treated diffrently compared to PHP >= 
5.3.3

Need to find a happy medium, otherwise would have to create separate release 
line.

Original comment by Aldrin.Baroi@gmail.com on 5 Jan 2012 at 6:59

GoogleCodeExporter commented 9 years ago
Changed "SetupDatabase" class name to "DatabaseSetup" to eliminate conflict 
with default constructor for PHP 5.3.0 - 5.3.2.

Removed backslash prefix from fully qualified classnames.  It seems to working 
for both PHP 5.3.2 & PHP version >= 5.3.3.

Need to run more tests.

Original comment by Aldrin.Baroi@gmail.com on 5 Jan 2012 at 7:40

GoogleCodeExporter commented 9 years ago
Fixed.

Original comment by Aldrin.Baroi@gmail.com on 7 Jan 2012 at 8:06

GoogleCodeExporter commented 9 years ago
Hello,

great! It works very fine without any errors.

Original comment by daniel@dseichter.de on 7 Jan 2012 at 2:43