AN EVENTS CALENDAR USING CMSB - Sep 11th, 2020
|
Small change October 11, 2018
After testing with PHP7 and CMSB 3.15, I had to move the header line <?php header('Content-type: text/html; charset=utf-8'); ?> in caledar5.php to after the 'load viewer library' call, or I'd get the errors:
E_USER_ERROR: removePrefixedCookie: Can't remove cookie(loginsession), headers already sent! Output started in /home3/ellescho/public_html/thecmsbcookbook/calendar5.php line 1.
/home3/ellescho/public_html/thecmsbcookbook/cmsAdmin/lib/common.php (line 757) http://www.thecmsbcookbook.com/calendar5.php
AND
E_WARNING: session_start(): Cannot send session cache limiter - headers already sent (output started at /home3/ellescho/public_html/thecmsbcookbook/calendar5.php:1)
/home3/ellescho/public_html/thecmsbcookbook/cmsAdmin/lib/init.php (line 713) http://www.thecmsbcookbook.com/calendar5.php
This recipe has been updated to reflect the latest code changes as of 2/2/2011 The zip file was recompiled on April 9, 2011 If you were having difficulties with single events, please re-download the zip file.
Zickey, who bills himself as “just a guy who uses CMS Builder” put together this really cool calendar application and has been kind enough shared both the code and instructions with us. He asks that if you utilize the Zickey calendar, you read and agree to the terms in the terms.txt document, which basically say that if you use the calendar, don’t blame him for anything that doesn’t work the way you expect it to.
To implement the Zickey calendar, you’ll need:
A multi record editor called “events” A viewer called “calendar5.php” A detail viewer called “events”detail.php” The “calendar5.css” file
You can download all the required viewer files, the.css file, the events.ini.php file*, the terms.txt file, and a copy of Zickey’s help file, instructions.rtf from:
http://www.thecmsbcookbook.com/downloads/zickey_calendar5.zip
You can see an operating calendar example at
http://www.thecmsbcookbook.com/calendar5.php
The calendar contains sample events spanning September and October 2020.
***To make the calendar load the event entries from your site, the calendar5.php $dirsToCheck = array code on line 5 must be updated with your own path. You'll also need to modify the eventsDetail.php file the same way. If needed, you can find the path by opening the events editor in the CMS Builder "Code Generator".
Note: The eventsDetail.php viewer is for example only and taken directly from the CMSB code generator.
*** to create your own events editor, upload the events,ini.php file to your cmsAdmin/data/schemaPresets folder and then create the editor from the "select presets" pulldown menu . Setup is extremely simple: 1) create the “events” editor and create some test events. 2) Change the “l $dirsToCheck = array” paths and upload the calendar.php, and eventsDetail.php viewers to your server 3) Upload the calendar5.css file to your css directory
That’s it, the calendar should be fully functional.
The calendar uses a “maxwords” function to limit the amount of words shown on the calendar in the optional event description field. If you’re unfamiliar with the maxwords function you can learn more about it in the recipe, “LIMITING THE NUMBER OF WORDS SHOWN IN A PAGE”.
**** The Zickey calendar is a collaborative project, so if you make any useful changes, or add any functionality, please post your changes and additions to:
http://www.interactivetools.com/iforum/Products_C2/CMS_Builder_F35/P82903
As always, after you’ve got the example working, you can add any required fields and style the pages the way you’d like.
|
The materials on this web site have been created for use with CMS Builder content management software. CMS Builder software is published and licensed for use by InteractiveTools.com. Please contact
Interactive Tools for information on the downloading of the software or the purchasing of licenses.