RSS

LuxCal Forum

The place for questions, suggestions and news about the LuxCal Event Calendar

User:   Password:   Remember Me?   
LuxCal Forum / General / Support / mini calendar not showing full month
Posted:  04 Dec 2012 05:02
Love the calendar. Itwill do what I need......only if I can get it to work properly.
have two test pages one for the mini calendar and one for the sidebar.

http://mabenchurchofgod.com/test.html (the Mini Cal)
http://mabenchurchofgod.com/test2.html  (the sidebar)

eventually they will be displayed on the same page under calendar.htm.

question 1 is the mini calendar will not show the full month. What am I missing or need to fix.

question 2 is I can not get the side bar to show at all. What am I doing wrong there.
Posted:  04 Dec 2012 06:10
For the mini calendar, try it just plain.

Code:


<iframe id="lcmini" src="http://mabenchurchofgod.com/luxcal/lcmini.php"></iframe>


I haven't tried the sidebar, here is what the documentation says, it might help.

b. Add a Sidebar with Upcoming Events

A sidebar with public upcoming events for the coming x days can be added to your web page. The sidebar is placed in a <div>-tag container, can be placed at any location and is fully customizable. An example is shown on the LuxCal Demo page of the LuxSoft web site. The sidebar can be added to your web page by adding the following lines of code to the <head>-section of your web page:
<link rel="stylesheet" type="text/css" href="mycalendarfolder/css/css_sbar.php"> <script src="mycalendarfolder/common/toolbox.js"></script>

and adding the following lines of code to the body of your web page:
<?php $sbClass = {sidebar class}; (optional) $sbHeader = {sidebar title}; (optional) $sbCatsIn = {list of categories to include}; (optional) $sbCatsEx = {list of categories to exclude}; (optional) $sbUsersIn = {list of users to include}; (optional) $sbUsersEx = {list of users to exclude}; (optional) include './mycalendarfolder/lcsbar.php'; ?>

Explanation of the lines of code:
All parameters indicated by {....}, including the braces, are text strings between single or double quotes.

    <?php: start PHP and ?>: end PHP. If the lines of code are added to a PHP section, these PHP-tags can be omitted.
    $sbClass: This is the class of the container <div>-tag which is used in the CSS to define the style for the sidebar container. This line of code is optional and will default to 'sideBar'. The styles for 'sideBar' are defined in the file css/css_sbar.php of your calendar installation.
    $sbHeader: The title of the sidebar. This line of code is optional. If not specified, the title of the sidebar will be taken from the language files.
    $sbCatsIn: This is a list with one or more IDs of the event categories that should be included in the sidebar. IDs should be separated by commas. This line of code is optional. If not specified, all event categories will be included.
    $sbCatsEx: This is a list with one or more IDs of the event categories that should be excluded from the sidebar. IDs should be separated by commas. This line of code is optional. If not specified, no event categories will be excluded. If $sbCatsIn has been specified, this line of code will be ignored.
    $sbUsersIn: Same as $sbCatsIn, but for calendar users.
    $sbUsersEx: Same as $sbCatsEx, but for calendar users.
    include: At this place the sidebar will be included.

In the above lines of code you should replace mycalendarfolder by the name of the root directory of your calendar installation.

The file css_sbar.php contains the default style for the sidebar container <div>, which should be tailored to your needs. In the same file you can customize the style, colors, fonts, etc. of the sidebar content. The title of the sidebar can be set per sidebar and the events in the sidebar can be filtered on event category ID and/or user ID. This allows for more than one sidebar per site, each with its own title and a different list of upcoming events.

Example of two sidebar definitions for the same website which are complementary:
<?php $sbClass = 'sideBar1'; $sbHeader = 'Birthdays/Holidays' ; $sbCatsIn = '2,4'; include './mycalendarfolder/lcsbar.php'; ?> <?php $sbClass = 'sideBar2'; $sbHeader = 'All other events'; $sbCatsEx = '2,4'; include './mycalendarfolder/lcsbar.php'; ?>

For each event the following will be displayed: date, time and title. Via the admin's Settings page, under "Mini Calendar / Upcoming Events Sidebar", you can choose whether further event details should be shown in a pop-up box (like in the full LuxCal calendar) when hovering an event and if URLs from the event description (if any) should be displayed in the sidebar as a hyperlink. On the same Settings page you can specify the number of days to look ahead for upcoming events in the sidebar.

The sidebar is using the database and tools of the full calendar and therefore the full calendar should be present in the "mycalendarfolder" (see code above).
__________________
"Little Guy"
Some own motorcycles, others ride them.

Find great LuxCal examples by Schwartz at http://www.calendarforum.dk/index.html
Posted:  04 Dec 2012 17:14   Last Edited By: Roel B.
Hi there,
Don't worry, we'll help you to get it working.

mini calendar:
In my browser I saw in the source of your mini calendar web page that you have not followed the instructions in the installation_guide.html. You should read the installation_guide.html section 5c. here you will find two important things:
1. In the style sheet (or in the style section in the <head>) of your parent page (the page with the iframe definition) you must add a style for the iframe. In the installation guide you will find the example:
#lcmini { position:absolute; right:100px; top:15%; width:210px; height:233px; overflow:hidden;}
This style is a good starting point.
2. The mini calendar can automatically change height, depending on how many weeks have to be displayed (4, 5 or 6 depending on which month). If you want to use this option, then you have to add the following script to the <head> of your parent page:
<script>
function setHeight(newHeight){var plus=(document.all)?8:0; document.getElementById('lcmini').style.height=newHeight+plus+'px';}
</script>


sidebar
The sidebar doesn't work because your php-tags are wrong. The php opening tag should be "<?php" and the closing tag should be "?>". And the two div-tags should be placed outside the php-tags. Furthermore the <div class='sidebar'> has no closing tag. And no quotes around text withoin div-tags.
So it should look as follows:

Code:


<div class="sidebar">
<div class="sbHeader">Maben Church of God Events</div>
<?php
include 'http://mabenchurchofgod.com/luxcal/lcsbar.php';
?>
</div>
The include statement can probably be reduced to:
include './luxcal/lcsbar.php';

You should maybe also rename your file to test2.php to have it served by PHP.
And don't forget to read the installation guide section 5b wink

Let me know if it works
Roel
Posted:  05 Dec 2012 16:51
<link rel="stylesheet" type="text/css" href="mycalendarfolder/css/css_sbar.php"> <script src="mycalendarfolder/common/toolbox.js"></script>

Missed that part.  The mini cal is now working. Thanks.

I still can not get the sidebar to work. It only shows the title.
I also renamed the test2.html to test2.php

http://mabenchurchofgod.com/test2.php

update: renamed to page to test2.php and it is now showing the side bar. it still is not showing correctly though. The title is on one side of the page and the side bar on the other and the events are  overlapping in the side bar. I will continue to play with the params but could you also take another look.

Thanks
Posted:  05 Dec 2012 22:18   Last Edited By: Roel B.
Hello,

I had a detailed look at your test2 site.
What you should do is edit the file "luxcal/css/css_sbar.php and change the styles to meet your needs. For instance, if you don't want the sidebar to display on the right site of your page, then you should remove line 49 ("float:right;"), if you want to make the sidebar higher, change the height on line 50 to 450px, and so on.
Roel
Posted:  06 Dec 2012 15:58
Thanks for the help, everything is working
Posted:  06 Dec 2012 18:50
Great!