Home Private Messages Search
CPG Dragonfly™ CMS stopsoftwarepatents.eu petition banner
Toggle Content
 
Forums ⇒ DragonflyCMS ⇒ Add-Ons & Blocks :: Archives ⇒ PR1 - coppermine image upload fix :: Archived


PR1 - coppermine image upload fix :: Archived
Need help creating a block or add-on, or you have created or modified a block/add-on that works in Dragonfly CMS and it meets the CPG Security Requirements? Do you have feedback about a specific add-on? Here is the place to post. Read the announcements here first!.
Go to page 1, 2  Next
Post new topic    Revive this topic    Printer Friendly Page     Forum Index ⇒  Add-Ons & Blocks

Topic Archived View previous topic :: View next topic  
Author Message
tulsais
Newbie
Newbie

Offline Offline
Joined: Jan 05, 2005
Posts: 11

PostPosted: Wed Jan 05, 2005 4:10 am
Post subject: PR1 - coppermine image upload fix

I have a fix that I thought I would share with everyone. I was having problems upload images, batch and single. I kept getting the "Unable to create thumbnail or reduced size image."

My problem was I had been trying to upload an image DSC000.JPG which, after being manipulated, turned to dsc000.JPG. Notice the different case.... The batch upload was also affected. The fix is simple. I added 1 simple word to 2 lines.

In modules/coppermine/include/picmgmt.inc line 29 & 30:
added strtolower() around $filename variable. Be sure you are only adding it to the definition of $normal and $thumb. If you add it to $image, it will break the page.

Let me know if this causes any problems I don't know about!


tulsais's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
FreeBSD4.10/Apache2/MySQL4.0/PHP4.3/CPG9
Back to top
View user's profile Visit poster's website
Phoenix
• Many Posts •
• Many Posts •

Offline Offline
Joined: Apr 19, 2004
Posts: 8799
Location: Netizen
PostPosted: Wed Jan 05, 2005 4:15 am
Post subject: Re: Dragonfly PR1 - Image upload fix

hmm, I can see the dilemma people are having - Dragonfly, so I have moved it to 9.x

Would be best to report this in cpgnuke.com/Projects/p=1.html
That way it can be verified, or an alternative provided.


Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)


Last edited by Phoenix on Wed Jan 05, 2005 4:27 am; edited 1 time in total
Back to top
View user's profile Visit poster's website Photo Gallery
mrrizal
Newbie
Newbie

Offline Offline
Joined: Sep 11, 2004
Posts: 8

PostPosted: Wed Jan 05, 2005 4:25 am
Post subject: Re: PR1 - coppermine image upload fix

can you describe the full code since i amnot a programmer


mrrizal's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Freebsd/Apache 2.0.49/MySQL 4.17/PHP 4.3.9/CPGNuke 9.0 (cvs)
Back to top
View user's profile Visit poster's website
DJ Maze
Developer
Developer

Offline Offline
Joined: Apr 19, 2004
Posts: 5683
Location: http://tinyurl.com/5z8dmv
PostPosted: Wed Jan 05, 2005 7:57 am
Post subject: Re: PR1 - coppermine image upload fix

What did you use (IM, GD or netPBM) ?
Is the system you had the problem FreeBSD or something else ?


DJ Maze's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Fedora 15 / 2.2.22 / 5.5.20 / 5.3.10 / CVS
Back to top
View user's profile Visit poster's website Yahoo Messenger Photo Gallery
mrrizal
Newbie
Newbie

Offline Offline
Joined: Sep 11, 2004
Posts: 8

PostPosted: Wed Jan 05, 2005 8:04 am
Post subject: Re: PR1 - coppermine image upload fix

ok i try everything.

i got this error whe using IM and netpbm
Quote::
The picture 'modules/coppermine/albums/userpics/dsc00942~6.JPG' can't be inserted in the album

Unable to create thumbnail or reduced size image.

i think tulsais isright because my original filename is DSC00000942.JPG and the error display namein small cap.

I got this error when using GD
Quote::
Fatal error: Call to undefined function: image_file_to_extension() in /usr/home/mrrizal/data/www/semesti/html/includes/imaging/gd2.inc on line 68

i just update gd2.inc using cvs since last time i got corrupted image when i upload a image.

and i just try another cms using coppermine as plugin. it running well. i make a conclusion my freebsd's IM,netpbm or GD is ok.


mrrizal's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Freebsd/Apache 2.0.49/MySQL 4.17/PHP 4.3.9/CPGNuke 9.0 (cvs)
Back to top
View user's profile Visit poster's website
tulsais
Newbie
Newbie

Offline Offline
Joined: Jan 05, 2005
Posts: 11

PostPosted: Wed Jan 05, 2005 3:50 pm
Post subject: Re: PR1 - coppermine image upload fix

Sorry, let me give some more info...

I'm running FreeBSD4.10 with Imagemagick. The only problem I had was the original filename was in CAPS, but the new filename was lower case with a CAPS extension. What I've stated above just converts all name to lowercase after the normal and thumb. Now, while writing this response, I believe I've thought of a problem. The original name will still be CAPS, so when it tries to display it, it will probably error because the file is being stored in MySQL all lowercase.

I'm not sure how to post the bug in the reporting tool, so if someone could help me with that, I definately appreciate it. Feel free to ask me any questions about what I've done. I am new to CPGNuke, so I'm not sure if I can be of any help. Big grin


tulsais's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
FreeBSD4.10/Apache2/MySQL4.0/PHP4.3/CPG9
Back to top
View user's profile Visit poster's website
Śyama_Dāsa
Developer
Developer

Offline Offline
Joined: Apr 19, 2004
Posts: 2048
Location: Dragonfly CMS Tribe
PostPosted: Wed Jan 05, 2005 6:30 pm
Post subject: Re: PR1 - coppermine image upload fix

This was fixed in the latest CVS version.
Files changed are:
html/includes/imaging imaging.inc 1.5
html/modules/coppermine db_input.php 8.11
html/modules/coppermine/include picmgmt.inc 8.8
Thanks tulsais and mrrizal

_________________
AKA Akamu / Read these and your life will be successful | Find a Repair
--
Mods and Professional Support via YIM

Śyama_Dāsa's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
win32 / Apache 1.3.33 / MySQL 4.1.16/PHP 4.4/CPG-CVS ( browsers: Mozilla 1.7.x / IE6 / Opera 8.0)
Back to top
View user's profile Visit poster's website Yahoo Messenger Photo Gallery
rusty_blade
Nice poster
Nice poster

Offline Offline
Joined: May 16, 2004
Posts: 136
Location: Toronto, Canada
PostPosted: Thu Jan 06, 2005 5:08 am
Post subject: Re: PR1 - coppermine image upload fix

Am I missing something? I have a server with Dragonfly and CPG 8.2. The 8.2 works fine and is set-up to GD version 2.x.
However, the Dragonfly only has 2 options: Image Magick and Netpdm, but no GD.

So I downloaded ImageMagick and installed it and I gave the path and it still doesn't work. I tried adding the strtolower($filename); but without any success.

What should be done?


rusty_blade's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
WinXP Pro; Apache 2; mysql-3.23.38; PHP 4.3.6
Back to top
View user's profile Visit poster's website
Phoenix
• Many Posts •
• Many Posts •

Offline Offline
Joined: Apr 19, 2004
Posts: 8799
Location: Netizen
PostPosted: Thu Jan 06, 2005 5:12 am
Post subject: Re: PR1 - coppermine image upload fix

You would be best updating with the latest snapshot as there have been extensive changes to many files since PR1 was released - all 3 options show up on mine.

_________________
DonationsPro for DragonflyCMS, SMF, MyBB, vBulletin

Phoenix's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website Photo Gallery
Andreas
500+ Posts Club
500+ Posts Club

Offline Offline
Joined: Sep 03, 2004
Posts: 852
Location: Gävle, Sweden
PostPosted: Thu Jan 06, 2005 11:07 am
Post subject: Re: PR1 - coppermine image upload fix

Is the PR1 package continously updated as well with the new changes or should the rest of us return to downloading the latest CVS-tarballs?

_________________
Andreas Rönnqvist
www.omegaproject.se
[OmegaProject] Founder

Andreas's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Linux/Apache 2.0.52(Unix)/4.0.23/4.3.10-2/Dragonfly 9.0.6.1
Back to top
View user's profile Visit poster's website ICQ Number MSN Messenger Yahoo Messenger
PerM
Dragonfly addicted
Dragonfly addicted

Offline Offline
Joined: Aug 07, 2004
Posts: 390
Location: Sweden
PostPosted: Thu Jan 06, 2005 12:10 pm
Post subject: Re: PR1 - coppermine image upload fix

Well...logically thinking, if the PR1 package was continously updated it woudn't be PR1 anymore, would it? Smile i.e use CVS.


PerM's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
Back to top
View user's profile Visit poster's website ICQ Number
Spawn
Newbie
Newbie

Offline Offline
Joined: Jan 28, 2005
Posts: 13

PostPosted: Sun Jan 30, 2005 12:25 am
Post subject: Re: PR1 - coppermine image upload fix

akamu wrote:
This was fixed in the latest CVS version.
Files changed are:
html/includes/imaging imaging.inc 1.5
html/modules/coppermine db_input.php 8.11
html/modules/coppermine/include picmgmt.inc 8.8
Thanks tulsais and mrrizal

html/modules/coppermine/include picmgmt.inc 8.8 wasnt in the CVS tree. im still getting
Code::
"Unable to create thumbnail or reduced size image. 

File: /home/spawnge/public_html/modules/coppermine/db_input.php - Line: 446 " 
and the footer says
Code::
"includes/coppermine/picmgmt.inc
Warning line 125: chmod(): SAFE MODE Restriction in effect. The script whose uid is 32388 is not allowed to access modules/coppermine/albums/userpics/10002/vorlondd_outline.jpg owned by uid 99
Warning line 127: getimagesize(): SAFE MODE Restriction in effect. The script whose uid is 32388 is not allowed to access modules/coppermine/albums/userpics/10002/vorlondd_outline.jpg owned by uid 99
Warning line 127: getimagesize(modules/coppermine/albums/userpics/10002/vorlondd_outline.jpg): failed to open stream: Success
Warning line 130: unlink(): SAFE MODE Restriction in effect. The script whose uid is 32388 is not allowed to access modules/coppermine/albums/userpics/10002/vorlondd_outline.jpg owned by uid 99

ill put the info i klnow about my server in my profile, as i was too alzy to before


Spawn's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
linux/1.3.33 (Unix)/4.0.18-standard/4.3.10/9.0
Back to top
View user's profile
Spawn
Newbie
Newbie

Offline Offline
Joined: Jan 28, 2005
Posts: 13

PostPosted: Sun Jan 30, 2005 12:37 am
Post subject: Re: PR1 - coppermine image upload fix

im sorry i found it, im a freaking moron.


Spawn's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
linux/1.3.33 (Unix)/4.0.18-standard/4.3.10/9.0
Back to top
View user's profile
Spawn
Newbie
Newbie

Offline Offline
Joined: Jan 28, 2005
Posts: 13

PostPosted: Sun Jan 30, 2005 12:45 am
Post subject: Re: PR1 - coppermine image upload fix

actually i still get the exact same error after i updated the files


Spawn's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
linux/1.3.33 (Unix)/4.0.18-standard/4.3.10/9.0
Back to top
View user's profile
Śyama_Dāsa
Developer
Developer

Offline Offline
Joined: Apr 19, 2004
Posts: 2048
Location: Dragonfly CMS Tribe
PostPosted: Sun Jan 30, 2005 1:06 am
Post subject: Re: PR1 - coppermine image upload fix

Spawn Link to your site?

_________________
AKA Akamu / Read these and your life will be successful | Find a Repair
--
Mods and Professional Support via YIM

Śyama_Dāsa's server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS)
win32 / Apache 1.3.33 / MySQL 4.1.16/PHP 4.4/CPG-CVS ( browsers: Mozilla 1.7.x / IE6 / Opera 8.0)
Back to top
View user's profile Visit poster's website Yahoo Messenger Photo Gallery
Display posts from previous:   
Post new topic    Revive this topic    Printer Friendly Page    Forum Index ⇒  Add-Ons & Blocks
Page 1 of 2
All times are GMT
Go to page 1, 2  Next

Archive Revive
Username:
This is an archived topic - your reply will not be appended here.
Instead, a new topic will be generated in the active forum.
The new topic will provide a reference link to this archived topic.
 
   Toggle Content User Info

Welcome Anonymous

Nickname
Password
(Register)

   Toggle Content Last CVS commits
· Fixed .ico Expires header.
· Removed domain name from cookies so subdomains wont access them anymore.
· CSS and JS, case insensitives.
· CSS and JS, send correct HTTP 1.1 headers and fixed issues where themes and...
· Further security class improvements.
· 301 redirects on LEO changes
· Option to force 3xx http status codes
· Validate googlebot.com and google.com crawlers.
· CCBot
· Rss with etag and atom.

read more...

   Toggle Content Community

Support for DragonflyCMS in a other languages:

Deutsch
Español

   Toggle Content X-links
UltraEdit Browse Happy logo Firefox MySQL PostgreSQL Valid CSS! Valid XHTML 1.0! Unicode Encoded Badge NukeBiz Resources Raven DragonflyCMS Dedicated Now InsideSupport Lampe Berger

You are seeing squares or questionmarks on this page?

All content of this website is copyrighted by the Creative Commons NC-SA
The logos and trademarks used on this site are the property of their respective owners
We are not responsible for comments posted by our users, as they are the property of the poster.
Our server runs on a P3 1.2GHz with 512MB RAM with no accelerators
Support GoPHP5.org
Interactive software released under GNU GPL, Code Credits, Privacy Policy