SVN Alba r5128 - in prosistem/alba/trunk/alba: apps/principal/modules/cal/actions apps/principal/modules/cal/lib web/js web/js/cal
Author: sabino Date: 2007-09-19 18:33:29 -0300 (Wed, 19 Sep 2007) New Revision: 5128 Added: prosistem/alba/trunk/alba/web/js/cal/ prosistem/alba/trunk/alba/web/js/cal/event.js Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/actions/components.class.php prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/default_config.php prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/ical_parser.php prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/init.inc.php prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/template.php Log: Ahora el calendario lee los eventos :) Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/actions/components.class.php =================================================================== --- prosistem/alba/trunk/alba/apps/principal/modules/cal/actions/components.class.php 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/apps/principal/modules/cal/actions/components.class.php 2007-09-19 21:33:29 UTC (rev 5128) @@ -13,13 +13,17 @@ { public function _phpicalendar($current_view) { - $default_cal_alba = $this->archivo; + $default_cal_alba = $this->archivo; //substr($this->archivo,0, -4); +// $default_cal_alba = BASE.'calendars/'.'Home.ics'; +// echo substr($this->archivo,0, -4); +// echo $this->archivo; // print_r( file($this->archivo)); $context = sfContext::getInstance(); require_once(BASE.'ical_parser.php'); require_once(BASE.'list_functions.php'); require_once(BASE.'template.php'); $context->getResponse()->addStylesheet ("cal/templates/$template/default", '', array()); + $context->getResponse()->addJavascript ("cal/event"); // if (isset($_GET['jumpto_day'])) { // $jumpto_day_time = strtotime($_GET['jumpto_day']); @@ -44,14 +48,81 @@ // header("Content-Type: text/html; charset=$charset"); - if ($minical_view == 'current') $minical_view = 'day'; + if ($minical_view == 'current') $minical_view = $current_view; + + if ($current_view == 'month') { // from month.php + ereg ("([0-9]{4})([0-9]{2})([0-9]{2})", $getdate, $day_array2); + $this_day = $day_array2[3]; + $this_month = $day_array2[2]; + $this_year = $day_array2[1]; + + $unix_time = strtotime($getdate); + $today_today = date('Ymd', time() + $second_offset); + $tomorrows_date = date('Ymd', strtotime("+1 day", $unix_time)); + $yesterdays_date = date('Ymd', strtotime("-1 day", $unix_time)); + $sidebar_date = localizeDate($dateFormat_week_list, $unix_time); + + // find out next month + $next_month_month = ($this_month+1 == '13') ? '1' : ($this_month+1); + $next_month_day = $this_day; + $next_month_year = ($next_month_month == '1') ? ($this_year+1) : $this_year; + while (!checkdate($next_month_month,$next_month_day,$next_month_year)) $next_month_day--; + $next_month_time = mktime(0,0,0,$next_month_month,$next_month_day,$next_month_year); + + // find out last month + $prev_month_month = ($this_month-1 == '0') ? '12' : ($this_month-1); + $prev_month_day = $this_day; + $prev_month_year = ($prev_month_month == '12') ? ($this_year-1) : $this_year; + while (!checkdate($prev_month_month,$prev_month_day,$prev_month_year)) $prev_month_day--; + $prev_month_time = mktime(0,0,0,$prev_month_month,$prev_month_day,$prev_month_year); + + $next_month = date("Ymd", $next_month_time); + $prev_month = date("Ymd", $prev_month_time); + $display_date = localizeDate ($dateFormat_month, $unix_time); + $parse_month = date ("Ym", $unix_time); + $first_of_month = $this_year.$this_month."01"; + $start_month_day = dateOfWeek($first_of_month, $week_start_day); + $thisday2 = localizeDate($dateFormat_week_list, $unix_time); + $num_of_events2 = 0; + + $list_icals = display_ical_list(availableCalendars($username, $password, $ALL_CALENDARS_COMBINED)); + $list_years = list_years(); + $list_months = list_months(); + $list_weeks = list_weeks(); + $list_jumps = list_jumps(); + $list_calcolors = list_calcolors(); + $list_icals_pick = display_ical_list(availableCalendars($username, $password, $ALL_CALENDARS_COMBINED), TRUE); + } elseif ($current_view == 'year') { // from year.php + ereg ("([0-9]{4})([0-9]{2})([0-9]{2})", $getdate, $day_array2); + $this_day = $day_array2[3]; + $this_month = $day_array2[2]; + $this_year = $day_array2[1]; + $next_year = strtotime ("+1 year", strtotime($getdate)); + $next_year = date ("Ymd", $next_year); + $prev_year = strtotime ("-1 year", strtotime($getdate)); + $prev_year = date ("Ymd", $prev_year); + + $sidebar_date = localizeDate($dateFormat_day, strtotime($getdate)); + + // For the side months + ereg ("([0-9]{4})([0-9]{2})([0-9]{2})", $getdate, $day_array2); + $this_day = $day_array2[3]; + $this_month = $day_array2[2]; + $this_year = $day_array2[1]; + } $weekstart = 1; $unix_time = strtotime($getdate); $today_today = date('Ymd', time() + $second_offset); $next_day = date('Ymd', strtotime("+1 day", $unix_time)); $prev_day = date('Ymd', strtotime("-1 day", $unix_time)); + + //from week.php + $next_week = date("Ymd", strtotime("+1 week", $unix_time)); + $prev_week = date("Ymd", strtotime("-1 week", $unix_time)); + + $globals_local = array(); $globals_local['daysofweek_lang'] = $daysofweek_lang; $globals_local['daysofweekshort_lang'] = $daysofweekshort_lang; $globals_local['daysofweekreallyshort_lang'] = $daysofweekreallyshort_lang; @@ -160,18 +231,19 @@ $page->replace_files(array( 'header' => '', - 'event_js' => '', + 'event_js' => "", 'footer' => '', 'sidebar' => '', - 'search_box' => '' + 'search_box' => '', + 'calendar_nav' => '', )); $prefixUri = sfContext::getInstance()->getRequest()->getUriPrefix(); $globals = array( "base" => $relativeUrlRoot ."/images/cal", 'day_view_action' => $action.'/'.$this->verPorDia, - 'week_view_action' => $action.'/'.$this->verPorSemana, - 'month_view_action' => $prefixUri.$relativeUrlRoot.'/'.$action.'/'.$this->verPorMes, - 'year_view_action' => $prefixUri.$relativeUrlRoot.'/'.$action.'/'.$this->verPorAnio, + 'week_view_action' => $action."/".$this->verPorSemana, + 'month_view_action' => $action.'/'.$this->verPorMes, + 'year_view_action' => $action.'/'.$this->verPorAnio, 'version' => $phpicalendar_version, 'charset' => $charset, 'default_path' => '', @@ -223,7 +295,18 @@ 'l_search' => $lang['l_search'], 'l_this_site_is' => $lang['l_this_site_is'] ); - + if ($current_view == 'month') { + $globals['next_month'] = $next_month; + $globals['prev_month'] = $prev_month; + $globals['l_this_months'] = $lang['l_this_months']; + } elseif ($current_view == 'year') { + $globals['next_year'] = $next_year; + $globals['prev_year'] = $prev_year; + $globals['l_this_year'] = $lang['l_this_year']; + } elseif ($current_view == 'week') { + $globals['next_week'] = $next_week; + $globals['prev_week'] = $prev_week; + } //print_r($globals); $page->replace_tags($globals); Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/default_config.php =================================================================== --- prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/default_config.php 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/default_config.php 2007-09-19 21:33:29 UTC (rev 5128) @@ -5,7 +5,7 @@ // To set values, change the text between the single quotes // Follow instructions to the right for detailed information -$template = 'default'; // Template support +$template = 'red'; // Template support $default_view = 'day'; // Default view for calendars = 'day', 'week', 'month', 'year' $minical_view = 'current'; // Where do the mini-calendars go when clicked? = 'day', 'week', 'month', 'current' // $default_cal = "$ALL_CALENDARS_COMBINED"; // Exact filename of calendar without .ics. Or set to $ALL_CALENDARS_COMBINED to open all calenders combined into one. Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/ical_parser.php =================================================================== --- prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/ical_parser.php 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/ical_parser.php 2007-09-19 21:33:29 UTC (rev 5128) @@ -27,80 +27,81 @@ // reading the file if it's allowed $parse_file = true; -if ($save_parsed_cals == 'yes') { - if (sizeof ($cal_filelist) > 1) { - $parsedcal = $tmp_dir.'/parsedcal-'.urlencode($cpath.'::'.$cal_filename).'-'.$this_year; - if (file_exists($parsedcal)) { - $fd = fopen($parsedcal, 'r'); - $contents = fread($fd, filesize($parsedcal)); - fclose($fd); - $master_array = unserialize($contents); - $z=1; - $y=0; - if (sizeof($master_array['-4']) == (sizeof($cal_filelist))) { - foreach ($master_array['-4'] as $temp_array) { - $mtime = $master_array['-4'][$z]['mtime']; - $fname = $master_array['-4'][$z]['filename']; - $wcalc = $master_array['-4'][$z]['webcal']; - if ($wcalc == 'no') $realcal_mtime = filemtime($fname); - $webcal_mtime = time() - strtotime($webcal_hours * 3600); - if (($mtime == $realcal_mtime) && ($wcalc == 'no')) { - $y++; - } elseif (($wcalc == 'yes') && ($mtime > $webcal_mtime)) { - //echo date('H:i',$mtime). ' > '. date('H:i',$webcal_mtime); - $y++; - } - $z++; - } - foreach ($master_array['-3'] as $temp_array) { - if (isset($temp_array) && $temp_array !='') $caldisplaynames[] = $temp_array; - } - if ($y == sizeof($cal_filelist)) { - if ($master_array['-1'] == 'valid cal file') { - $parse_file = false; - $calendar_name = $master_array['calendar_name']; - $calendar_tz = $master_array['calendar_tz']; - } - } - } - } - if ($parse_file == true) unset($master_array); - } else { - foreach ($cal_filelist as $filename) { - $realcal_mtime = filemtime($filename); - $parsedcal = $tmp_dir.'/parsedcal-'.urlencode($cpath.'::'.$cal_filename).'-'.$this_year; - if (file_exists($parsedcal)) { - $parsedcal_mtime = filemtime($parsedcal); - if ($realcal_mtime == $parsedcal_mtime) { - $fd = fopen($parsedcal, 'r'); - $contents = fread($fd, filesize($parsedcal)); - fclose($fd); - $master_array = unserialize($contents); - if ($master_array['-1'] == 'valid cal file') { - $parse_file = false; - $calendar_name = $master_array['calendar_name']; - $calendar_tz = $master_array['calendar_tz']; - } - } - } - } - } -} +//@annotation esto lo saque porque no tiene sentido en nuestro caso +// if ($save_parsed_cals == 'yes') { +// if (sizeof ($cal_filelist) > 1) { +// $parsedcal = $tmp_dir.'/parsedcal-'.urlencode($cpath.'::'.$cal_filename).'-'.$this_year; +// if (file_exists($parsedcal)) { +// $fd = fopen($parsedcal, 'r'); +// $contents = fread($fd, filesize($parsedcal)); +// fclose($fd); +// $master_array = unserialize($contents); +// $z=1; +// $y=0; +// if (sizeof($master_array['-4']) == (sizeof($cal_filelist))) { +// foreach ($master_array['-4'] as $temp_array) { +// $mtime = $master_array['-4'][$z]['mtime']; +// $fname = $master_array['-4'][$z]['filename']; +// $wcalc = $master_array['-4'][$z]['webcal']; +// if ($wcalc == 'no') $realcal_mtime = filemtime($fname); +// $webcal_mtime = time() - strtotime($webcal_hours * 3600); +// if (($mtime == $realcal_mtime) && ($wcalc == 'no')) { +// $y++; +// } elseif (($wcalc == 'yes') && ($mtime > $webcal_mtime)) { +// //echo date('H:i',$mtime). ' > '. date('H:i',$webcal_mtime); +// $y++; +// } +// $z++; +// } +// foreach ($master_array['-3'] as $temp_array) { +// if (isset($temp_array) && $temp_array !='') $caldisplaynames[] = $temp_array; +// } +// +// if ($y == sizeof($cal_filelist)) { +// if ($master_array['-1'] == 'valid cal file') { +// $parse_file = false; +// $calendar_name = $master_array['calendar_name']; +// $calendar_tz = $master_array['calendar_tz']; +// } +// } +// } +// } +// if ($parse_file == true) unset($master_array); +// } else { +// foreach ($cal_filelist as $filename) { +// $realcal_mtime = filemtime($filename); +// $parsedcal = $tmp_dir.'/parsedcal-'.urlencode($cpath.'::'.$cal_filename).'-'.$this_year; +// if (file_exists($parsedcal)) { +// $parsedcal_mtime = filemtime($parsedcal); +// if ($realcal_mtime == $parsedcal_mtime) { +// $fd = fopen($parsedcal, 'r'); +// $contents = fread($fd, filesize($parsedcal)); +// fclose($fd); +// $master_array = unserialize($contents); +// if ($master_array['-1'] == 'valid cal file') { +// $parse_file = false; +// $calendar_name = $master_array['calendar_name']; +// $calendar_tz = $master_array['calendar_tz']; +// } +// } +// } +// } +// } +// } if ($parse_file) { $overlap_array = array (); $uid_counter = 0; } +// print_r ($cal_filelist); die; $calnumber = 1; foreach ($cal_filelist as $cal_key=>$filename) { - // Find the real name of the calendar. $actual_calname = getCalendarName($filename); if ($parse_file) { - // Let's see if we're doing a webcal $is_webcal = FALSE; if (substr($filename, 0, 7) == 'http://' || substr($filename, 0, 8) == 'https://' || substr($filename, 0, 9) == 'webcal://') { @@ -1210,13 +1211,13 @@ //If you want to see the values in the arrays, uncomment below. -//print '<pre>'; -//print_r($master_array); -//print_r($overlap_array); -//print_r($day_array); -//print_r($rrule_array); -//print_r($recurrence_delete); -//print_r($cal_displaynames); -//print_r($cal_filelist); -//print '</pre>'; +// print '<pre>'; +// print_r($master_array); +// print_r($overlap_array); +// print_r($day_array); +// print_r($rrule_array); +// print_r($recurrence_delete); +// print_r($cal_displaynames); +// print_r($cal_filelist); +// print '</pre>'; ?> Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/init.inc.php =================================================================== --- prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/init.inc.php 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/init.inc.php 2007-09-19 21:33:29 UTC (rev 5128) @@ -17,23 +17,24 @@ if (is_file(BASE.'config.inc.php')) include_once(BASE.'config.inc.php'); include_once(BASE.'sanitize.php'); -$cookie_name = 'phpicalendar_'.basename($default_path); -if (isset($_COOKIE["$cookie_name"]) && !isset($_POST['unset'])) { - $phpicalendar = unserialize(stripslashes($_COOKIE[$cookie_name])); - if (isset($phpicalendar['cookie_language'])) $language = $phpicalendar['cookie_language']; - if (isset($phpicalendar['cookie_calendar'])) $default_cal_check = $phpicalendar['cookie_calendar']; - if (isset($phpicalendar['cookie_cpath'])) $default_cpath_check= $phpicalendar['cookie_cpath']; - if (isset($phpicalendar['cookie_view'])) $default_view = $phpicalendar['cookie_view']; - if (isset($phpicalendar['cookie_style']) && is_dir(BASE.'templates/'.$phpicalendar['cookie_style'].'/')){ - $template = $phpicalendar['cookie_style']; - } - if (isset($phpicalendar['cookie_startday'])) $week_start_day = $phpicalendar['cookie_startday']; - if (isset($phpicalendar['cookie_time'])) $day_start = $phpicalendar['cookie_time']; -} -#cpath modifies the calendar path based on the url or cookie values. This allows you to run multiple calendar subsets from a single phpicalendar installation. Operations on cpath are largely hidden from the end user. -if ($calendar_path == '') { - $calendar_path = BASE.'calendars'; -} +//@annotation esto lo saque porque no tiene sentido en nuestro caso +// $cookie_name = 'phpicalendar_'.basename($default_path); +// if (isset($_COOKIE["$cookie_name"]) && !isset($_POST['unset'])) { +// $phpicalendar = unserialize(stripslashes($_COOKIE[$cookie_name])); +// if (isset($phpicalendar['cookie_language'])) $language = $phpicalendar['cookie_language']; +// if (isset($phpicalendar['cookie_calendar'])) $default_cal_check = $phpicalendar['cookie_calendar']; +// if (isset($phpicalendar['cookie_cpath'])) $default_cpath_check= $phpicalendar['cookie_cpath']; +// if (isset($phpicalendar['cookie_view'])) $default_view = $phpicalendar['cookie_view']; +// if (isset($phpicalendar['cookie_style']) && is_dir(BASE.'templates/'.$phpicalendar['cookie_style'].'/')){ +// $template = $phpicalendar['cookie_style']; +// } +// if (isset($phpicalendar['cookie_startday'])) $week_start_day = $phpicalendar['cookie_startday']; +// if (isset($phpicalendar['cookie_time'])) $day_start = $phpicalendar['cookie_time']; +// } +// #cpath modifies the calendar path based on the url or cookie values. This allows you to run multiple calendar subsets from a single phpicalendar installation. Operations on cpath are largely hidden from the end user. +// if ($calendar_path == '') { +// $calendar_path = BASE.'calendars'; +// } $cpath = ''; #initialize cpath to prevent later undef warnings. if(isset($_REQUEST['cpath'])&& $_REQUEST['cpath'] !=''){ @@ -109,31 +110,32 @@ // Pull the calendars off the GET line if provided. The $cal_filename // is always an array, because this makes it easier to deal with below. $cal_filenames = array(); -if (isset($_GET['cal'])) { - // If the cal value is not an array, split it into an array on - // commas. - if (!is_array($_GET['cal'])) - $_GET['cal'] = explode(',', $_GET['cal']); - - // Grab the calendar filenames off the cal value array. - $cal_filenames = $_GET['cal']; -} else { - if (isset($default_cal_check)) { - if ($default_cal_check != $ALL_CALENDARS_COMBINED) { - $calcheck = $calendar_path.'/'.$default_cal_check.'.ics'; - $calcheckopen = @fopen($calcheck, "r"); - if ($calcheckopen == FALSE) { - $cal_filenames = explode(',',$default_cal); - } else { - $cal_filenames[0] = $default_cal_check; - } - } else { - $cal_filenames[0] = $ALL_CALENDARS_COMBINED; - } - } else { - $cal_filenames = explode(',',$default_cal_alba); - } -} +// if (isset($_GET['cal'])) { +// // If the cal value is not an array, split it into an array on +// // commas. +// if (!is_array($_GET['cal'])) +// $_GET['cal'] = explode(',', $_GET['cal']); +// +// // Grab the calendar filenames off the cal value array. +// $cal_filenames = $_GET['cal']; +// } else { +// if (isset($default_cal_check)) { +// if ($default_cal_check != $ALL_CALENDARS_COMBINED) { +// $calcheck = $calendar_path.'/'.$default_cal_check.'.ics'; +// $calcheckopen = @fopen($calcheck, "r"); +// if ($calcheckopen == FALSE) { +// $cal_filenames = explode(',',$default_cal); +// } else { +// $cal_filenames[0] = $default_cal_check; +// } +// } else { +// $cal_filenames[0] = $ALL_CALENDARS_COMBINED; +// } +// } else { +// $cal_filenames = explode(',',$default_cal_alba); +// } +// } +$cal_filenames = explode(',',$default_cal_alba); //load cal_filenames if $ALL_CALENDARS_COMBINED if ($cal_filenames[0] == $ALL_CALENDARS_COMBINED){ @@ -160,10 +162,11 @@ // Otherwise it is a local calendar. else { // Check blacklisted. - if (in_array($cal_filename, $blacklisted_cals) && $cal_filename !='') { - exit(error($lang['l_error_restrictedcal'], $cal_filename)); - } - $local_cals[] = urldecode(str_replace(".ics", '', basename($cal_filename))); +// if (in_array($cal_filename, $blacklisted_cals) && $cal_filename !='') { +// exit(error($lang['l_error_restrictedcal'], $cal_filename)); +// } +// $local_cals[] = urldecode(str_replace(".ics", '', basename($cal_filename))); + $local_cals[] = urldecode($cal_filename); } } @@ -227,11 +230,13 @@ $globals['lang'] = $lang; $globals['ALL_CALENDARS_COMBINED'] = $ALL_CALENDARS_COMBINED; - $local_cals = availableCalendars($username, $password, $local_cals,false, $globals); + //@annotation esto no pasaba el chequeo y no es necesario + //$local_cals = availableCalendars($username, $password, $local_cals,false, $globals); foreach ($local_cals as $local_cal) { $cal_displaynames[] = str_replace('32', ' ', getCalendarName($local_cal)); } + $cal_filelist = array_merge($cal_filelist, $local_cals); $cals = array_merge($cals, array_map("urlencode", array_map("getCalendarName", $local_cals))); @@ -255,7 +260,6 @@ } } } - // We should only allow a download filename and subscribe path if there is // only one calendar being displayed. if (count($cal_filelist) > 1) { @@ -278,19 +282,19 @@ return ((float)$usec + (float)$sec); } #uncomment for diagnostics -#echo "after init.inc.ics<pre>"; -#echo "cals"; -#print_r($cals);echo"\n\n"; -#echo "cal_filenames"; -#print_r($cal_filenames);echo"\n\n"; -#echo "web_cals"; -#print_r($web_cals);echo"\n\n"; -#echo "local_cals"; -#print_r($local_cals);echo"\n\n"; -#echo "cal_filelist"; -#print_r($cal_filelist); -#echo "cal_displaynames"; -#print_r($cal_displaynames); -#echo "</pre><hr>"; +// echo "after init.inc.ics<pre>"; +// echo "cals"; +// print_r($cals);echo"\n\n"; +// echo "cal_filenames"; +// print_r($cal_filenames);echo"\n\n"; +// echo "web_cals"; +// print_r($web_cals);echo"\n\n"; +// echo "local_cals"; +// print_r($local_cals);echo"\n\n"; +// echo "cal_filelist"; +// print_r($cal_filelist); +// echo "cal_displaynames"; +// print_r($cal_displaynames); +// echo "</pre><hr>"; ?> Modified: prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/template.php =================================================================== --- prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/template.php 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/apps/principal/modules/cal/lib/template.php 2007-09-19 21:33:29 UTC (rev 5128) @@ -948,6 +948,7 @@ $first_of_year = $minical_year."0101"; // Add links in to the month/year views. + //@annotation modificacion de los link que produce en la vista de month and year $dateFormat_month_local = str_replace("%B", "<a class=\"ps3\" href=\"month.php?cal=$this->cal&getdate=$first_of_month\">%B</a>", $this->dateFormat_month); $dateFormat_month_local = str_replace("%Y", "<a class=\"ps3\" href=\"year.php?cal=$this->cal&getdate=$first_of_year\">%Y</a>", $dateFormat_month_local); Added: prosistem/alba/trunk/alba/web/js/cal/event.js =================================================================== --- prosistem/alba/trunk/alba/web/js/cal/event.js 2007-09-19 20:26:45 UTC (rev 5127) +++ prosistem/alba/trunk/alba/web/js/cal/event.js 2007-09-19 21:33:29 UTC (rev 5128) @@ -0,0 +1,51 @@ +<script language="JavaScript" type="text/javascript"> +<!-- +function openEventWindow(num) { + // populate the hidden form + var data = document.popup_data[num]; + var form = document.forms.eventPopupForm; + form.elements.date.value = data.date; + form.elements.time.value = data.time; + form.elements.uid.value = data.uid; + form.elements.cpath.value = data.cpath; + form.elements.event_data.value = data.event_data; + + // open a new window + var w = window.open('', 'Popup', 'scrollbars=yes,width=460,height=275'); + form.target = 'Popup'; + form.submit(); +} + +function EventData(date, time, uid, cpath, event_data) { + this.date = date; + this.time = time; + this.uid = uid; + this.cpath = cpath; + this.event_data = event_data; +} +//--> +</script> +<script language="JavaScript" type="text/javascript"> +<!-- + +function openTodoInfo(num) { + // populate the hidden form + var data = document.todo_popup_data[num]; + var form = document.forms.todoPopupForm; + + form.elements.todo_data.value = data.todo_data; + + // open a new window + var w = window.open('', 'Popup', 'scrollbars=yes,width=460,height=275'); + form.target = 'Popup'; + form.submit(); +} +function TodoData(todo_data,todo_text) { + this.todo_data = todo_data; + this.todo_text = todo_text; +} + +document.popup_data = new Array(); +document.todo_popup_data = new Array(); +//--> +</script>
participants (1)
-
commits@pressenter.com.ar