Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: apostophe in filenames?  (Read 3965 times)

0 Members and 1 Guest are viewing this topic.

lnguyen

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
apostophe in filenames?
« on: June 24, 2004, 10:14:54 pm »

Ok, have a few things I've noticed.  I have no idea if this was present in 1.2.1 or not, as I never noticed it (never brought to my attention anyway)

what can I do about apostrophe's in filenames?  I got a database error when trying to view the picture (after clickcing the thumbnail) and turned on debug.  basically, the error goes with filename = 'blah's pciture.jpg'" (yes, the last part is an apostrophe and a qoute)

Any ideas?

Thanks
Linh
« Last Edit: June 25, 2004, 04:38:06 am by lnguyen »
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: apostophe in filenames, unassigned albums?
« Reply #1 on: June 25, 2004, 12:33:28 am »

please post only one ossue per thread. Please post deep links to illustrate the issue you're facing.

GauGau
Logged

lnguyen

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
Re: apostophe in filenames?
« Reply #2 on: June 25, 2004, 04:41:41 am »

what do you mean by deep links? 

this is the ablum in question for the apostrophe problem: http://kineticphoto.net/thumbnails.php?album=25

I think it's apostrophes that are causing the problem.  I turned on debug for all.  If you click on any of the images there, you'll see what I'm talking about. 

Thanks
Linh
Logged

Tarique Sani

  • VIP
  • Coppermine addict
  • ***
  • Offline Offline
  • Gender: Male
  • Posts: 2712
    • http://tariquesani.net
Re: apostophe in filenames?
« Reply #3 on: June 25, 2004, 05:14:19 am »

Open the file exif_php.inc.php in the includes directory and change line 33 to

Code: [Select]
"WHERE filename = \"$filename\"";
instead of

Code: [Select]
"WHERE filename = '$filename'";
Or the time being turn the read EXIF information off....
« Last Edit: June 25, 2004, 08:10:57 am by Tarique Sani »
Logged
SANIsoft PHP applications for E Biz

lnguyen

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
Re: apostophe in filenames?
« Reply #4 on: June 25, 2004, 06:01:58 pm »

thank you!

also, for future reference, gotta do the same for the following code:

Code: [Select]
VALUES (\"$filename\",
in the same file

thanks again

Linh
Logged
Pages: [1]   Go Up
 

Page created in 0.02 seconds with 20 queries.