- <?php
- /**
- * <b>Database Class : Calendar</b><br />
- * Provides all database access methods for the calendar section
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- /**
- * <b>Database Class : Calendar</b><br />
- * Provides all database access methods for the calendar section
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class DB_Cal {
-
- function DB_Cal() { }
-
- // Same code as in calendar include, but repeated so that this file can stand
- // alone from all of the other code
-
- function &incDay ($today)
- {
- $total_days = getdate(mktime(0,0,0,$today['mon']+1,1,$today['year'])-1);
- if($today['mday']++ > $total_days) {
- if($today['mon']++ > 12) {
- $next_day = getdate(mktime(0,0,0,1,1,$today['year']++));
- }
- else {
- $next_day = getdate(mktime(0,0,0,$today['mon']++,1,$today['year']));
- }
- }
- else {
- $next_day = getdate(mktime(0,0,0,$today['mon'],$today['mday']++,$today['year']));
- }
- return $next_day;
- }
-
- function &GetMonthData(&$date) {
- $data = Array();
-
- $month = $date['mon'];
- $year = $date['year'];
- $nextmonth = $month+1;
- $nextyear = $year;
- if($nextmonth > 12) { $nextmonth = 1; $nextyear++; }
- $starttimestamp = mktime(0,0,0,$month,1,$year);
- $stoptimestamp = mktime(0,0,0,$nextmonth,1,$nextyear)-1;
-
- $result = mysql_query("select I.ID, I.Type, I.Start, I.Stop, I.Recursive, I.RecEnd, I.RecDay,
- S.MeetByMonthDays
- from Instance I, Series S
- where S.ID = I.SeriesID
- and (((year(I.Start) = $year or year(I.Stop) = $year)
- and (month(I.Start) = $month or month(I.Stop) = $month))
- or ((unix_timestamp(I.Start) <= $stoptimestamp) and (unix_timestamp(I.RecEnd) >= $starttimestamp)
- and (I.Recursive = 1)))
- order by I.Start");
-
- //Process each row.
- while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
- $start = getdate(strtotime($row['Start']));
- $stop = getdate(strtotime($row['Stop']));
- $itemstartstamp = strtotime($row['Start']);
- if($row['Recursive']) {
- $recendstamp = strtotime($row['RecEnd']);
- $end_month = getdate($stoptimestamp);
- if($row['MeetByMonthDays']==0) { $meetdays=0; }
- else { $meetdays = explode(',',$row['MeetByMonthDays']); }
- for ($day = 1; $day <= $end_month['mday']; $day++) {
- $thisday = getdate(mktime(0,0,0,$month,$day,$year));
- $thisdaystamp = mktime(59,59,23,$month,$day,$year);
- $thisdaystartstamp = mktime(0,0,0,$month,$day,$year);
- if($thisday['weekday'] == $row['RecDay'] && $itemstartstamp <= $thisdaystamp) {
- if($thisdaystartstamp <= $recendstamp) {
- if($meetdays==0) {
- $data[] = new MonthData($row['ID'], $row['Type'], $thisday['mday']);
- }
- else{
- $dayarr = array(); $mkr = $day;
- while($mkr > 0) { $mkr = $mkr-7; }
- $i=$mkr; while($i<=$end_month['mday']) { $dayarr[]=$i;$i=$i+7; }
- foreach($meetdays as $meetingdays) {
- if($dayarr[$meetingdays] == $day) {
- $data[] = new MonthData($row['ID'], $row['Type'], $thisday['mday']);
- }
- }
- }
- }
- }
- }
- }
- else {
- if($start['mday'] == $stop['mday']) {
- $data[] = new MonthData($row['ID'], $row['Type'], $start['mday']);
- }
- else {
- if($start['mon'] != $month) {
- $itemstamp = mktime(0,0,0,$month,1,$year);
- }
- else { $itemstamp = mktime(0,0,0,$start['mon'],$start['mday'],$start['year']); }
- $itemstampdate = getdate($itemstamp);
- $itemstopstamp = mktime(0,0,0,$stop['mon'],$stop['mday'],$stop['year']);
- while($itemstamp <= $itemstopstamp && $itemstamp <= $stoptimestamp) {
- $data[] = new MonthData($row['ID'], $row['Type'], $itemstampdate['mday']);
- $itemstampdate = $this->incDay(getdate($itemstamp));
- $itemstamp = $itemstampdate[0];
- }
- }
- }
- }
- $tempfunction = create_function('$event1,$event2',
- 'return strcmp($event1,$event2);');
- usort($data,$tempfunction);
- return $data;
- }
-
- //Pass it the first and last date inclusively.
- //Doesn't work for recursive items that don't meet 4 times a month
-
- function &GetWeekDataNoRec(&$first, &$last) {
- $data = Array();
-
- $firststamp = mktime(0, 0, 0, $first['mon'], $first['mday'],$first['year']);
- $laststamp = mktime(23, 59, 59, $last['mon'], $last['mday'],$last['year']);
-
-
- $result = mysql_query("select I.ID, I.Type, S.Title as STitle,
- S.ShowItem as SShow, I.Title, I.Start, I.Stop
- from Instance I, Series S
- where S.ID = I.SeriesID
- and (unix_timestamp(I.Start) <= $laststamp) and (unix_timestamp(I.Stop) >= $firststamp)
- order by I.Start");
-
- while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
- $id = $row['ID'];
- $result2 = mysql_query("select S.Title as SSubTitle,
- S.ShowItem as SSubShow,
- time_format(S.Start, '%l:%i %p') as SSubStart
- from Instance I, Series S
- where I.ID = $id AND S.ID = I.SubSeriesID");
- $datatemp2[] = mysql_fetch_array($result2, MYSQL_ASSOC);
- $datatemp[] = $row;
- }
- for($i = 0; $i < count($datatemp); $i++) {
- $item = $datatemp[$i];
- $item2 = $datatemp2[$i];
- $itemstart = getdate(strtotime($item['Start']));
- $itemstop = getdate(strtotime($item['Stop']));
- $data[] = new WeekData($item['ID'], $item['Type'], $item['Title'],
- $itemstart, $item['STitle'], $item['SShow'],
- $item2['SSubTitle'], $item2['SSubStart'],
- $item2['SSubShow']);
- }
- return $data;
- }
-
-
- //Pass it the first and last date inclusively.
-
- function &GetWeekData(&$first, &$last, $daystart=1) {
- $data = Array();
- if($daystart) {
- $firststamp = mktime(0, 0, 0, $first['mon'], $first['mday'],$first['year']); }
- else { $firststamp = mktime($first['hours'],$first['minutes'],$first['seconds'],
- $first['mon'],$first['mday'],$first['year'])+3600; }
- $laststamp = mktime(23, 59, 59, $last['mon'], $last['mday'],$last['year']);
- $lastday = getdate($laststamp);
- $nextmonth = $last['mon']+1;
- $nextyear = $last['year'];
- if($nextmonth > 12) { $nextmonth = 1; $nextyear++; }
- $endmonth = getdate(mktime(0,0,0,$nextmonth,1,$nextyear)-1);
-
- $datatemp2 = Array();
- $datatemp = Array();
-
- $result = mysql_query("select I.ID, I.Type, S.Title as STitle, S.MeetByMonthDays,
- S.ShowItem as SShow, I.Title, I.Start, I.Stop, I.Recursive, I.RecDay, I.RecEnd
- from Instance I, Series S
- where S.ID = I.SeriesID
- and (((unix_timestamp(I.Start) <= $laststamp) and (unix_timestamp(I.Stop) >= $firststamp))
- or ((unix_timestamp(I.Start) <= $laststamp) and (unix_timestamp(I.RecEnd) >= $firststamp)
- and (I.Recursive = 1)))
- order by I.Start");
-
- while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
- $id = $row['ID'];
- $result2 = mysql_query("select S.Title as SSubTitle,
- S.ShowItem as SSubShow,
- time_format(S.Start, '%l:%i %p') as SSubStart
- from Instance I, Series S
- where I.ID = $id AND S.ID = I.SubSeriesID
- order by I.Start");
- $datatemp2[] = mysql_fetch_array($result2, MYSQL_ASSOC);
- $datatemp[] = $row;
- }
- $datacount = count($datatemp);
- $daymkr = $first;
- $mytime = $firststamp;
- $timearr = array();
- while($mytime <= $laststamp) {
- $timearr[] = $daymkr;
- $daymkr = $this->incDay($daymkr);
- $mytime = mktime(0, 0, 0, $daymkr['mon'], $daymkr['mday'],$daymkr['year']);
- }
- foreach($timearr as $thisday) {
- for($i = 0; $i < $datacount; $i++) {
- $item = $datatemp[$i];
- $item2 = $datatemp2[$i];
- $itemstart = getdate(strtotime($item['Start']));
- $itemstop = getdate(strtotime($item['Stop']));
- $itemstime = mktime(0, 0, 0, $itemstart['mon'], $itemstart['mday'],$itemstart['year']);
- if(!$item['Recursive']) {
- if($itemstart['mday'] == $itemstop['mday']) {
- if($itemstart['mday'] == $thisday['mday'] && $itemstart['mon'] == $thisday['mon']) {
- $data[] = new WeekData($item['ID'], $item['Type'], $item['Title'],
- $itemstart, $item['STitle'], $item['SShow'],
- $item2['SSubTitle'], $item2['SSubStart'],
- $item2['SSubShow']);
- }
- }
- else {
- if($itemstart['mon'] != $thisday['mon']) {
- $itemstamp = mktime(0,0,0,$thisday['mon'],1,$thisday['year']);
- }
- else { $itemstamp = mktime(0,0,0,$itemstart['mon'],$itemstart['mday'],$itemstart['year']); }
- $itemstampdate = getdate($itemstamp);
- $itemstopstamp = mktime(0,0,0,$itemstop['mon'],$itemstop['mday'],$itemstop['year']);
- while($itemstamp <= $itemstopstamp && $itemstamp <= $laststamp) {
- if($itemstampdate['mday'] == $thisday['mday']) {
- $data[] = new WeekData($item['ID'],$item['Type'],$item['Title'],getdate($itemstamp),$item['STitle'],
- $item['SShow'],$item2['SSubTitle'],$item2['SSubStart'],$item2['SSubShow']);
- }
- $itemstampdate = $this->incDay(getdate($itemstamp));
- $itemstamp = $itemstampdate[0];
- }
- }
- }
- else if ((strcasecmp($thisday['weekday'],$item['RecDay']) == 0) && ($item['Recursive'])) {
- $dayarr = array(); $day= $thisday['mday']; $mkr = $day; $addflg=false;
- if($item['MeetByMonthDays']==0) { $addflg = true; }
- else {
- $meetdays = explode(',',$item['MeetByMonthDays']);
- while($mkr > 0) { $mkr = $mkr-7; }
- $j=$mkr; while($j<=$endmonth['mday']) { $dayarr[]=$j;$j=$j+7; }
- foreach($meetdays as $meetingdays) {
- if($dayarr[$meetingdays] == $day) { $addflg=true; }
- }
- }
- if($addflg) {
- $datestamp = mktime($itemstart['hours'],
- $itemstart['minutes'],0,$thisday['mon'],
- $thisday['mday'],$thisday['year']);
- $date = getdate($datestamp);
- if($datestamp >= $firststamp) {
- $data[] = new WeekData($item['ID'], $item['Type'], $item['Title'],
- $date, $item['STitle'], $item['SShow'],
- $item2['SSubTitle'], $item2['SSubStart'],
- $item2['SSubShow']);
- }
- }
- }
- }
- }
- $tempfunction = create_function('$event1,$event2',
- 'return strcmp($event1->Start[0],$event2->Start[0]);');
- usort($data,$tempfunction);
- return $data;
- }
-
- // Pass the date
- // Returns ID only
-
- function &GetDayData(&$day) {
- $data = Array();
-
- $begindaystamp = mktime(0, 0, 0, $day['mon'], $day['mday'], $day['year']);
- $enddaystamp = mktime(23, 59, 59, $day['mon'], $day['mday'], $day['year']);
- $weekday = $day['weekday'];
-
- $result = mysql_query("select I.ID, I.Start, I.Recursive, I.RecDay, I.RecEnd
- from Instance I
- where ((($begindaystamp <= unix_timestamp(I.Start)) and
- (unix_timestamp(I.Start) <= $enddaystamp))
- or (($begindaystamp <= unix_timestamp(I.Stop)) and
- (unix_timestamp(I.Stop) <= $enddaystamp))
- or ((unix_timestamp(I.Start) <= $begindaystamp) and
- ($begindaystamp <= unix_timestamp(I.Stop)))
- or (
- (unix_timestamp(I.Start) <= $begindaystamp)
- and (unix_timestamp(I.RecEnd) >= $begindaystamp)
- and (I.RecDay = '$weekday')
- and (I.Recursive = 1)
- )
- )
- order by I.Start");
-
- while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
- $tempdate = getdate(strtotime($row['Start']));
- if($row['Recursive'] || $tempdate['mday'] != $day['mday']) {
- $row['Start'] = getdate(mktime($tempdate['hours'],$tempdate['minutes'],0,
- $day['mon'],$day['mday'],$day['year']));
- }
- else { $row['Start'] = $tempdate; }
- $data[] = new DayData($row['ID'],$row['Start']);
- }
- $tempfunction = create_function('$event1,$event2',
- 'return strcmp($event1->Start[0],$event2->Start[0]);');
- usort($data,$tempfunction);
- return $data;
- }
-
-
- //Pass it the ID.
- //There must be an ID associated with all of the elements.
-
- function &GetCalItemData(&$id) {
- $result = mysql_query("select I.ID, I.Title, I.Start, I.Stop, I.Type,
- I.Recursive, I.RecDay, I.RecEnd, I.ContactEmail,
- I.Description, S.ShowItem, S.Title as STitle, S.MeetByMonthDays,
- C.Email, C.First, C.Last, C.Title as CTitle,
- C.ShowMainTitle, C.ShowMainFirstName, C.ID as CID,
- L.ID AS LID, L.Name AS LName,
- A.Title AS ATitle, A.LinkStream as ALinkStream,
- A.ID as AID, A.LinkDownload as ALinkDownload
- from Instance I, Series S, Contact C, Location L, Audio A
- where I.ID = $id
- and S.ID = I.SeriesID and C.ID = I.ContactID and
- L.ID = I.LocationID and A.ID = I.AudioID
- limit 1");
-
- $row = mysql_fetch_array($result, MYSQL_ASSOC);
-
- $start = getdate(strtotime($row['Start']));
- $stop = getdate(strtotime($row['Stop']));
- $recend = getdate(strtotime($row['RecEnd']));
-
- $result2 = mysql_query("select S.Title as SSubTitle,
- S.ShowItem as SSubShow,
- time_format(S.Start, '%l:%i %p') as SSubStart,
- time_format(S.Stop, '%l:%i %p') as SSubStop
- from Instance I, Series S
- where I.ID = $id
- AND S.ID = I.SubSeriesID");
- $row2 = mysql_fetch_array($result2, MYSQL_ASSOC);
-
- $fullname = "";
- if($row['ShowMainTitle']) { $fullname .= $row['CTitle']." "; }
- if($row['ShowMainFirstName']) { $fullname .= $row['First']." ".$row['Last']; }
-
- $data = new CalItemData($row['ID'], $row['Type'], $row['Title'], $row['ContactEmail'],
- $start, $stop, $row['Email'], $row['CID'], $fullname, $row['Description'], $row['STitle'],
- $row['ShowItem'], $row['ATitle'], $row['ALinkStream'], $row['ALinkDownload'], $row['AID'], $row['LID'], $row['LName'],
- $row2['SSubTitle'], $row2['SSubShow'], $row2['SSubStart'], $row2['SSubStop'],
- $row['Recursive'], $row['RecDay'], $recend, $row['MeetByMonthDays']);
-
- return $data;
- }
-
- function &SearchCalType(&$search,$atype,$limit,$blimit) {
- $data = Array();
- $query_string = "select I.ID, I.Type, S.Title as STitle, I.Description, I.Title
- from Instance I, Series S
- where S.ID = I.SeriesID AND (";
-
- foreach($atype as $type) {
- if($type == "title") {
- $query_string = $query_string . "I.Title LIKE '%$search%' OR ";
- }
- else if($type == "stitle") {
- $query_string = $query_string . "STitle LIKE '%$search%' OR ";
- }
- else if($type == "description") {
- $query_string = $query_string . "I.Description LIKE '%$search%' OR ";
- }
- else { die("Invalid Parameters"); }
- }
- if(count($atype) == 0) { die("Invalid Parameters"); }
-
- $query_string = substr($query_string,0,strlen($query_string)-4);
- $query_string = $query_string . ") limit $blimit,$limit";
- $result = mysql_query($query_string);
-
- require_once ($GLOBALS['SERVER_DIRECTORY'].$GLOBALS['INCLUDE_PATH'].$GLOBALS['CALENDAR_INCLUDE']);
- $cal = new Calendar();
-
- //Process each row.
- while ($item = mysql_fetch_array($result, MYSQL_ASSOC)) {
- $tempcaldata = $this->GetCalItemData($item['ID']);
- $printdate = "";
- $timestamp = 0;
- if($tempcaldata->Recursive) {
- $recstamp = $cal->nextEventFromRecursive($tempcaldata);
- $timestamp = $recstamp;
- if($recstamp == 0) { $recstamp = $tempcaldata->RecEnd[0]; }
- $recdate = getdate($recstamp);
- $printdate = $recdate['month']." ".$recdate['mday'].", ".$recdate['year'];
- }
- else if($tempcaldata->Start['year'] == $tempcaldata->Stop['year'] &&
- $tempcaldata->Start['mon'] == $tempcaldata->Stop['mon'] &&
- $tempcaldata->Start['mday'] == $tempcaldata->Stop['mday']) {
- $timestamp = $tempcaldata->Start[0];
- $printdate .= $tempcaldata->Start['month']." ".$tempcaldata->Start['mday'].
- ", ".$tempcaldata->Start['year'];
- }
- else {
- $timestamp = $tempcaldata->Start[0];
- $printdate .= $tempcaldata->Start['month']." ".$tempcaldata->Start['mday'].
- ", ".$tempcaldata->Start['year']." - ";
- $printdate .= $tempcaldata->Stop['month']." ".$tempcaldata->Stop['mday'].
- ", ".$tempcaldata->Stop['year'];
- }
- $data[] = new SearchData($item['ID'], $item['Type'], $item['Title'],
- $printdate,$item['STitle'], $item['Description'],$timestamp);
- }
-
- $tempfunction = create_function('$event1,$event2',
- 'return strcmp($event2->Timestamp,$event1->Timestamp);');
- usort($data,$tempfunction);
- return $data;
- }
-
- function &SearchCalCount(&$item,$atype) {
- $data = Array();
- $query_string = "SELECT DISTINCTROW COUNT(*)
- from Instance I, Series S
- where S.ID = I.SeriesID AND (";
-
- foreach($atype as $type) {
- if($type == "title") {
- $query_string = $query_string . "I.Title LIKE '%$item%' OR ";
- }
- else if($type == "stitle") {
- $query_string = $query_string . "STitle LIKE '%$item%' OR ";
- }
- else if($type == "description") {
- $query_string = $query_string . "I.Description LIKE '%$item%' OR ";
- }
- else { die("Invalid Parameters"); }
- }
- if(count($atype) == 0) { die("Invalid Parameters"); }
-
- $query_string = substr($query_string,0,strlen($query_string)-4);
- $query_string = $query_string . " )";
- $result = mysql_query($query_string);
- $row = mysql_fetch_array($result, MYSQL_ASSOC);
- foreach($row as $item) { $count = $item; }
- return $count;
- }
- }
-
- /**
- * <b>Database Container Class : Month</b><br />
- * Contains all of the specific data for an event on the month view.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class MonthData {
- var $ID;
- var $Type;
- var $Day;
-
- function MonthData($id, $type, $day) {
- $this->ID = $id;
- $this->Type = $type;
- $this->Day = $day;
- }
- }
-
-
- /**
- * <b>Database Container Class : Week</b><br />
- * Contains all of the specific data for an event of the week.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class WeekData {
- var $ID;
- var $Type;
- var $Title;
- var $Start;
- var $STitle;
- var $SShow;
- var $SSubTitle;
- var $SSubStart;
- var $SSubShow;
-
- function WeekData($id, $type, $title, $start, $stitle, $sshow,
- $ssubtitle, $ssubstart, $ssubshow) {
- $this->ID = $id;
- $this->Type = $type;
- $this->Title = $title;
- $this->Start = $start;
- $this->STitle = $stitle;
- $this->SShow = $sshow;
- $this->SSubTitle = $ssubtitle;
- $this->SSubStart = $ssubstart;
- $this->SSubShow = $ssubshow;
- }
- }
-
-
- /**
- * <b>Database Container Class - Day</b><br />
- * Contains all of the specific data for an event of the day.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class DayData {
- var $ID;
- var $Start;
-
- function DayData($id,$start) {
- $this->ID = $id;
- $this->Start = $start;
- }
- }
-
-
- /**
- * <b>Database Container Class : Calendar Item</b><br />
- * Contains all of the specific data for a calendar event.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class CalItemData {
- var $ID;
- var $Type;
- var $Title;
- var $ContactEmail;
- var $Start;
- var $Stop;
- var $Email;
- var $CID;
- var $CName;
- var $Description;
- var $STitle;
- var $SShow;
- var $ATitle;
- var $ALinkStream;
- var $ALinkDownload;
- var $AID;
- var $LID;
- var $LName;
- var $SSubTitle;
- var $SSubShow;
- var $SSubStart;
- var $SSubStop;
- var $Recursive;
- var $RecDay;
- var $RecEnd;
- var $MeetByMonth;
-
- function CalItemData($id, $type, $title, $contactemail, $start, $stop, $email, $cid, $cname,
- $desc, $stitle, $sshow, $atitle, $alinkstream, $alinkdownload, $aid, $lid, $lname,
- $ssubtitle, $ssubshow, $ssubstart, $ssubstop, $rec, $recday, $recend,$meeting) {
- $this->ID = $id;
- $this->Type = $type;
- $this->Title = $title;
- $this->ContactEmail = $contactemail;
- $this->Start = $start;
- $this->Stop = $stop;
- $this->Email = $email;
- $this->CID = $cid;
- $this->CName = $cname;
- $this->Description = $desc;
- $this->STitle = $stitle;
- $this->SShow = $sshow;
- $this->ATitle = $atitle;
- $this->ALinkStream = $alinkstream;
- $this->ALinkDownload = $alinkdownload;
- $this->AID = $aid;
- $this->LID = $lid;
- $this->LName = $lname;
- $this->SSubTitle = $ssubtitle;
- $this->SSubShow = $ssubshow;
- $this->SSubStart = $ssubstart;
- $this->SSubStop = $ssubstop;
- $this->Recursive = $rec;
- $this->RecDay = $recday;
- $this->RecEnd = $recend;
- $this->MeetByMonth = $meeting;
- }
- }
-
- /**
- * Database Container Class - Calendar Search
- * Contains all of the specific data for a calendar search result.
- * @author Kristen O'Brien <kristen_paristemi-com>
- * @copyright Copyright © 2004, Kristen O'Brien
- * @license http://opensource.org/licenses/gpl-license.php GNU Public License
- * @link http://www.paristemi.com Paristemi Main Site
- * @package paristemi
- * @subpackage paristemi_database_layer
- * @since Build 0.5
- * @version Build 0.7
- * @filesource
- */
- class SearchData {
- var $ID;
- var $Type;
- var $Title;
- var $Date;
- var $STitle;
- var $Description;
- var $Timestamp;
-
- function SearchData($id, $type, $title, $date, $stitle, $desc, $timestamp=0) {
- $this->ID = $id;
- $this->Type = $type;
- $this->Title = $title;
- $this->Date = $date;
- $this->STitle = $stitle;
- $this->Description = $desc;
- $this->Timestamp = $timestamp;
- }
- }
-
- ?>