Filenames for Document Uploads

3 posts by 2 authors in: Forums > CMS Builder
Last Post: June 1, 2010   (RSS)

Re: [newmediachoice] Filenames for Document Uploads

By Jason - May 31, 2010

Hi,

CMS Builder attaches a postfix such as 001 or 002 when a file of the same name already exists in the upload folder. So, what's happening is that the file set_menu.pdf has already been uploaded at some point, and not removed.

What I would suggest doing is to set up a single record section called Set Menu. All you need here is an upload field to take in the pdf. You can set the maximum number of uploads to 1, so that it can't be duplicated in that section. Also, you can create a new folder inside cmsAdmin/uploads, where your set menu get stored. Set this as the upload directory (make sure to check "Use Custom Directory"). This way, you always know which folder the pdf will be in and that only one section edits that folder. Also, they have to remove the current menu, before being able to upload another.

Hope this helps.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

Hire me! Save time by getting our experts to help with your project.
http://www.interactivetools.com/consulting/

Re: [Jason] Filenames for Document Uploads

Thanks Jason - I'd forgotten that I created a custom upload directory for the pdf documents and for demonstration purposes, I'd hard-wired the links into that directory for the pdf menu downloads. Therefore, when I started uploading the menus via the CMS the affixes were added because the menus were already in that directory. Creating single records isn't going to work for this client as they want to choose the order of the menus on the menu download page, but your suggestion works just as well with multi-records. Many thanks for your help!