Web Development Thread, MRBS config.inc.php in Coding and Web Development; hi, im getting errors when setting up mrbs, the line the error refers to is where im trying to set ...
-
30th April 2009, 03:34 PM #1
- Rep Power
- 0
MRBS config.inc.php
hi, im getting errors when setting up mrbs, the line the error refers to is where im trying to set up periods as opposed to time lines...
could you post the calendar bit of your config file if you have a working periods not time set up>>???
"Parse error: syntax error, unexpected T_VARIABLE in /var/www/mrbs/config.inc.php on line 94"
thanks!!!!
-
-
IDG Tech News
-
30th April 2009, 03:38 PM #2 /*******************
* Calendar settings
*******************/
// Note: Be careful to avoid specify options that displays blocks overlaping
// the next day, since it is not properly handled.
// This setting controls whether to use "clock" based intervals (FALSE and
// the default) or user defined periods (TRUE). If user-defined periods
// are used then $resolution, $morningstarts, $eveningends,
// $eveningends_minutes and $twentyfourhour_format are ignored.
$enable_periods = TRUE;
// Resolution - what blocks can be booked, in seconds.
// Default is half an hour: 1800 seconds.
$resolution = 1800;
// Default duration - default length (in seconds) of a booking.
// Ignored if $enable_periods is TRUE
// Defaults to (60 * 60) seconds, i.e. an hour
$default_duration = (60 * 60);
// Start and end of day.
// NOTE: The time between the beginning of the last and first
// slots of the day must be an integral multiple of the resolution,
// and obviously >=0.
// The default settings below (along with the 30 minute resolution above)
// give you 24 half-hourly slots starting at 07:00, with the last slot
// being 18:30 -> 19:00
// The beginning of the first slot of the day
$morningstarts = 7; // must be integer in range 0-23
$morningstarts_minutes = 0; // must be integer in range 0-59
// The beginning of the last slot of the day
$eveningends = 18; // must be integer in range 0-23
$eveningends_minutes = 30; // must be integer in range 0-59
// Example 1.
// If resolution=3600 (1 hour), morningstarts = 8 and morningstarts_minutes = 30
// then for the last period to start at say 4:30pm you would need to set eveningends = 16
// and eveningends_minutes = 30
// Example 2.
// To get a full 24 hour display with 15-minute steps, set morningstarts=0; eveningends=23;
// eveningends_minutes=45; and resolution=900.
// Do some checking
$start_first_slot = ($morningstarts*60) + $morningstarts_minutes; // minutes
$start_last_slot = ($eveningends*60) + $eveningends_minutes; // minutes
$start_difference = ($start_last_slot - $start_first_slot) * 60; // seconds
if (($start_difference < 0) or ($start_difference%$resolution != 0))
{
die('Configuration error: start and end of day incorrectly defined');
}
// Define the name or description for your periods in chronological order
// For example:
// $periods[] = "Period 1"
// $periods[] = "Period 2"
// ...
// or
// $periods[] = "09:15 - 09:50"
// $periods[] = "09:55 - 10:35"
// ...
// is used to ensure that the name or description is not wrapped
// when the browser determines the column widths to use in day and week
// views
//
// NOTE: MRBS assumes that the descriptions are valid HTML and can be output
// directly without any encoding. Please ensure that any special characters
// are encoded, eg '&' to '&', '>' to '>', lower case e acute to
// 'é' or 'é', etc.
// NOTE: The maximum number of periods is 60. Do not define more than this.
$periods[] = "Period 1";
$periods[] = "Period 2";
$periods[] = "Period 3";
$periods[] = "Period 4";
$periods[] = "Period 5";
$periods[] = "Period 6";
$periods[] = "After School";
// NOTE: The maximum number of periods is 60. Do not define more than this.
// Do some checking
if (count($periods) > 60)
{
die('Configuration error: too many periods defined');
}
// Start of week: 0 for Sunday, 1 for Monday, etc.
$weekstarts = 1;
// Trailer date format: 0 to show dates as "Jul 10", 1 for "10 Jul"
$dateformat = 1;
// Time format in pages. 0 to show dates in 12 hour format, 1 to show them
// in 24 hour format
$twentyfourhour_format = 0;
Last edited by HodgeHi; 30th April 2009 at 03:39 PM.
Reason: Sorry wrong config file
-
-
30th April 2009, 03:42 PM #3 Make sure your using valid syntax, and haven't accidently deleted a dollar or something...
i.e no special chars or white space
-
-
1st May 2009, 12:20 PM #4
- Rep Power
- 0
blinkin semi-colon missing!
thanks for the reply, it was a semi colon. or rather the lack of one.
doh!
-
SHARE: 
Similar Threads
-
By FN-GM in forum Windows
Replies: 20
Last Post: 30th April 2012, 01:26 PM
-
By mossj in forum Web Development
Replies: 7
Last Post: 14th July 2009, 04:23 PM
-
By Hightower in forum Coding
Replies: 9
Last Post: 11th December 2008, 03:48 PM
-
By monkey_boy in forum Other Stuff
Replies: 0
Last Post: 24th April 2007, 11:29 AM
-
By Joedetic in forum Web Development
Replies: 0
Last Post: 28th June 2006, 11:54 AM
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules