From: <par...@us...> - 2009-05-26 20:18:32
|
Update of /cvsroot/phpicalendar/phpicalendar/functions In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv18932/functions Modified Files: template.php Log Message: Sanitize print view and add URL links Index: template.php =================================================================== RCS file: /cvsroot/phpicalendar/phpicalendar/functions/template.php,v retrieving revision 1.114 retrieving revision 1.115 diff -C2 -d -r1.114 -r1.115 *** template.php 14 May 2009 21:45:44 -0000 1.114 --- template.php 26 May 2009 20:15:15 -0000 1.115 *************** *** 86,96 **** $seen_events["$new_key2"] = 1; $day_events++; ! if (isset($new_val2['event_text'])) { ! $event_text = stripslashes(urldecode($new_val2['event_text'])); ! $location = stripslashes(urldecode($new_val2['location'])); ! $description = stripslashes(urldecode($new_val2['description'])); ! $event_start = $new_val2['event_start']; ! $event_end = $new_val2['event_end']; ! if (isset($new_val2['display_end'])) $event_end = $new_val2['display_end']; if (!isset($new_val2['event_start'])) { $event_start = $lang['l_all_day']; --- 86,98 ---- $seen_events["$new_key2"] = 1; $day_events++; ! if (isset($new_val2['event_text'])) { ! $event_text = sanitizeForWeb(stripslashes(urldecode($new_val2['event_text']))); ! $location = sanitizeForWeb(stripslashes(urldecode($new_val2['location']))); ! $description = sanitizeForWeb(stripslashes(urldecode($new_val2['description']))); ! if (!empty($description)) $description = ereg_replace("[[:alpha:]]+://[^<>[:space:]]+[[:alnum:]/]",'<a target="_new" href="\0">\0</a>', $description); ! ! $event_start = $new_val2['event_start']; ! $event_end = $new_val2['event_end']; ! if (isset($new_val2['display_end'])) $event_end = $new_val2['display_end']; if (!isset($new_val2['event_start'])) { $event_start = $lang['l_all_day']; |