Get options from database

2 posts by 2 authors in: Forums > CMS Builder
Last Post: November 22, 2011   (RSS)

Re: [mediaco] Get options from database

By Jason - November 22, 2011

Hi,

The reason you're only getting the name as an option is that all upload information is actually stored in a separate uploads table. Also, when choosing options, only the value you select for "option value" will be stored in the database.

Probably the best approach would be to use the "num" field from videos as your option value for your drop down in courses. Then, when you are outputting your courses, you can do a second query to the videos table to get the related video record. If you use getRecords() to do this, CMS Builder will automatically append the upload information to the video record.

Hope this helps get you started.
---------------------------------------------------
Jason Sauchuk - Project Manager
interactivetools.com

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