Use of "&" character in file names

I have many file names with the character "&" in my gallery. These have been added & displayed with no problems in the past, & still display fine. But since 1.4.5 I can not add files with the "&" character.

This must be a database problem. File names with this character are currently in the database, but I can't seem to add them to the database now.

Is there a setting i have wrong that is causing this?

Comments

  • acrylian Administrator, Developer
    I have no idea but I would recommend not use that char in file/folder names since it is a query delimiter to avoid possible issues. If uploading via the backend by default Zenphoto would clear that char like other specials chars actually.
  • I know the use of the "&" character would not be recommended. But my original decision to go with ZP for CMS was because it would correctly display this character. I already had a large number of images named this way from years ago.

    All my old images display just fine. When I examine the database I can't see any difference between the old files & the new ones. I can upload an identical file name, to one currently in the database in a different folder and it will not display now, while the old one will still display fine.

    The only difference I can determine is that I am using 1.4.5 now & I was using 1.4.4 (or older) in the past.
  • Another simple way to look this issue. ZP has the ability to display file names containing the "&" character if the file is added to the database with 1.4.4 or older, but not if the file is added to the database using 1.4.5

    As I said I can see no difference in the properties when I look at the files in the database using PHPadmin.
  • acrylian Administrator, Developer
    Maybe my colleague has any idea. In 1.4.5 the internal rewrite handling has been changed greatly so maybe something got lost. Probably you should open a ticket.
  • I know of no changes to 1.4.5 specifically in this area. But it is certainly possible that one or more of the security changes has impacted this.

    So, maybe some sleuthing will help understand what is happening.

    If it is indeed the database that is different, what is the name representation in the database for the 1.4.4 uploaded image and what is it for the 1.4.5 one? Maybe the difference will be a clue.

    How exactly are the files added? What SEO plugins are enabled? Normally the Zenphoto upload process would strip the ampersand from the filename.

    What is happening when the file does not display? Do you get a broken image? a PHP error? etc.
  • acrylian Administrator, Developer
    You get a broken image with the X (there is a ticket now).
  • This will not be fixed. Zenphoto cannot be both secure and allow ampersand in file and folder names. Use the seo cleanup utility to fix your image names.
Sign In or Register to comment.