Prevent adding record to cms_uploads table?

4 posts by 2 authors in: Forums > CMS Builder
Last Post: December 15, 2008   (RSS)

Re: [rcrofoot] Prevent adding record to cms_uploads table?

By Dave - December 13, 2008

Hi Rick,

There's no built in way to do that. Otherwise CMS Builder wouldn't be able to track the uploads or remove them later when the user deletes them.

What are you trying to do?
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] Prevent adding record to cms_uploads table?

Dave-

In addition to allowing a user to add individual records and upload corresponding PDFs individually, I've created a bulk upload PHP page that uses a CSV file to add many records in one operation...So I write to the CMS tables directly and they show up on the site, and in the CMS editor interface...However, for every CSV record added, there needs to be an accompanying PDF... So, I am using a second section editor so the user can upload PDFs from their hard drive to the server...

As an alternative, I thought of giving the user an html dropdown populated with PDF files from a directory I would tell them to create (and load w/PDFs) on their hard drive...But there will be users from Japan, Germany, and who knows where else using the site...I don't think a directory like c:\uploads would look the same in Japan as it does here, so I decided not to do it that way...

I can still do this with CMS, but I'll end up with double entries in the cms_uploads table...not the worst thing in the world, and definately still acceptable although not ideal...

Hope that makes sense...As always...Thanks for the response and help!

Rick

Re: [rcrofoot] Prevent adding record to cms_uploads table?

By Dave - December 15, 2008

So you've written a custom php program to import records into the database? And then you want to upload the PDFs through CMS builder for the records? Is that right?

If CMS Builder doesn't store anything in the uploads table it won't know there is an upload there. So it will always show no uploads for each record.

I think what you're going to need to do is either write another custom app that allows you to upload PDFs outside of CMS Builder.

How are you getting fouble entries in the cms_uploads table? Are you currently adding to it from outside CMS Builder?

This sounds pretty custom - sorry if I don't have a clear cut answer :)
Dave Edis - Senior Developer
interactivetools.com