public:calcms:setup_agenda

Basic Setup

Locations

These are different paths that are used by calcms. Please make sure that the private files and directories are not publicly accessible from your web server.

location base URL description content public
/var/www/ / your website x
/home/calcms/website/agenda /agenda/ dynamic calcms web interface controllers, widgets x
/home/calcms/website/agenda_files /agenda_files/ static calcms web content images, css, js x
/home/calcms/website/agenda/config/config.cgi configuration -
/home/calcms/tools calcms tools -
/home/calcms/lib/calcms perl modules -

You can choose other paths than /var/www and /home/calcms/. Relative URLs should not be changed. The absolute path of the Perl module directory should be set to startup.pl so that mod_perl can find the modules. If you use a different path of config.cgi, please use tools/update_page.sh

Prepare source page

Calcms Webinterface needs a simple web page in which it has to be embedded.

This can be

  • a static html page
  • a separate page in your CMS that contains the agenda You can take over the CMS layout yourself or, depending on your CMS, define a page with some html markup.

We need to add some css and js to the header of the page so that calcms can insert dynamic content and define the feeds:

<!--calcms start-->
<link rel="alternate" type="application/atom+xml" title="Sendeplan Atom" href="/agenda/atom/" />
<link rel="alternate" type="application/rss+xml" title="Sendeplan RSS" href="/agenda/rss/" /> 
<link rel="alternate" type="application/atom+xml" title="Sendekommentare" href="/agenda/feed_kommentare/" />
<link rel="stylesheet" type="text/css" media="screen" href="/agenda_files/css/calcms.css" /> 
<script type="text/javascript" src="/agenda_files/js/jquery.js"></script>
<script type="text/javascript" src="/agenda_files/js/calcms.js"></script> 
<script type="text/javascript" src="/agenda_files/js/calcms.cust.js"></script>
<!--calcms end-->

Calcms will replace special divs on this page after a Calcms ID has been set. If you use a CMS, create a page and place the divs where you need them.

div id description
calcms_calendar a calendar widget with links to all events by selected day, month, week or weekday
calcms_menu a short list of icons and names of selected events
calcms_list a list of series, title and excerpt of selected events
calcms_playlist current events or events next to come
calcms_search input box to search events
calcms_comments current comments

Example index.html:

<html>
    <head>
<!--calcms start-->
<link rel="alternate" type="application/atom+xml" title="Sendeplan Atom" href="/agenda/atom/" />
<link rel="alternate" type="application/rss+xml" title="Sendeplan RSS" href="/agenda/rss/" /> 
<link rel="alternate" type="application/atom+xml" title="Sendekommentare" href="/agenda/feed_kommentare/" />
<link rel="stylesheet" type="text/css" media="screen" href="/agenda_files/css/calcms.css" /> 
<script type="text/javascript" src="/agenda_files/js/jquery.js"></script>
<script type="text/javascript" src="/agenda_files/js/calcms.js"></script> 
<script type="text/javascript" src="/agenda_files/js/calcms.cust.js"></script>
<!--calcms end-->
    </head>
    <body>
        <table>
            <tr>
                <td> 
                    <div id="calcms_menu"></div> 
                </td>
                <td> 
                    <div id="calcms_list"></div>
                </td>
                <td> 
                    <div id="calcms_calendar"></div> 
                    <div id="calcms_search"></div> 
                    <div id="calcms_playlist"></div> 
                </td>
            </tr>
        </table>
    <body>
</html>

Set the URL of this page /index.html to the source_url during configuration. In a CMS use the URL of the created page, e.g. /calcms/

You should not use this page anywhere else, remove it from robots.txt, some editing of this page is required before it contains helpful content.

Update the calcms start page

Now call ./tools/update_page.sh to generate the Calcms start page. This will generate a hmtl page under /agenda/programm.html. The agenda start page will contain the content of the source_url, but static widgets will be replaced by the content of calcms. Call the script update_page.sh after every change to your website or CMS layout. You can create a cronjob that runs update_page.sh hourly to make sure that the calcms pages have the correct layout.

Create a menu item „Program“ that links to /agenda/programm.html in your static website or CMS to refer to the schedule.


Impressum Datenschutz