I posted similar info on the GlobalSCAPE board back in 2005. This thread definitely needs to go into the Frequently asked questions area so I will move it.
WEBGEMS were the Trellix way of doing special features: music, downloads, html codes in a build your own webgem, etc. In CSB, we have the ability to do the same things. Use the INSERT menu on your toolbar to insert images, animated graphics, downloadable files, music, all sorts of goodies.
The old Build Your Own Webgem (BYOG) from Trellix became INSERT > HTML code. (in CSB5 it is INSERT > ADVANCED HTML > HTML CODE but we shortcut instructions to INSERT >HTML)
3 WAYS TO have a downloadable PDF file: You will probably use #1 or #2. 1) USE THE INSERT > FILE DOWNLOAD LINK (in Trellix it's the webgem for file download) Choose your file and publish.
2)
USE FTP TO UPLOAD A FILE: (best option if you have A LOT of files) When you use a 3rd party FTP program to upload your special files (swf, music, pdf, image for slideshows, etc) you can place them into folders on your website that mean something logical if you like. You can place all your pdf files in a pdf folder, or separate them by topic, etc. Or you can use a File Manager if your website control panel offers that choice to upload files. Then in your CSB page, simply link to them either from a web page with a simple link (use
URL style link) or from a script, just use a full URL address.
3) USE CSB/TRELLIX TO UPLOAD A FILE AS PART OF A CODE:
(usually this instruction is for FLASH .swf or image files for slideshows, etc) When you use CSB/Trellix to upload and link to a file (swf, music, pdf, image) as part of a code, you place the code into an INSERT HTML, then place the file into the WEB COMPONENTS part of the insert HTML. To find the file, the code must be modified to put ^GEMDIR/ in front of the file name.
RESULT: CSB/Trellix publishes the code AND your file to your website.
ADDITIONAL INFO: You should look at the VIEW SOURCE on the page with the code. You will not see ^GEMDIR/ in the code. That is placed into your code to tell CSB/Trellix to create a SUBDIRECTORY to hold that webcomponent. The source code on the page will show the swf file can be located at an address that looks like HTMLobj-123/yourfile.swf
LINKING: If you want to link to the file from somewhere else on your site, or as part of another script, you would have to use the true URL address to link to the file, example:
http://www.domain.com/HTMLobj-123/yourfile.swf You would NEVER use the ^GEMDIR/ outside of the confined space of the CSB INSERT HTML interface! To link from one Insert HTML to another is tricky but can be done. Insert the swf file. Publish. Using the View source get the proper url address of the swf file. Then when you put your other code in you can use the true address of the swf file in the code. You use ^GEMDIR/ for the files that are inserted only into the CURRENT insert HTML code.
By the way, when you PUBLISH, if you use instruction #1 or #3 above, remember to UNCHECK the option to publish to a local HTML file if you have defined it in the publishing options. If you do that, your HTML-obj folder will publish fine. [This box is helpful as a setting for previewing your site, but not for publishing your site!]
File > Publish web site > Options > HTML Directory > Uncheck this box when you publish.
You can easily recheck it again when you want to use the preview function again.