version 1.304, 2012/03/25 14:36:01
|
version 1.306, 2012/03/26 10:24:08
|
Line 1309 sub htmlareaselectactive {
|
Line 1309 sub htmlareaselectactive {
|
$.fn.jPicker.defaults.images.clientPath="/adm/jpicker/images/"; |
$.fn.jPicker.defaults.images.clientPath="/adm/jpicker/images/"; |
$(".colorchooser").jPicker(); |
$(".colorchooser").jPicker(); |
|
|
// Only define the countdown if a dueDate variable is defined: |
|
|
|
if (typeof(dueDate) != "undefined") { |
|
$("#duedatecountdown").countdown({until: dueDate, compact: true, |
|
layout: "<b>Due in: {dn} {dl} {hnn}{sep}{mnn}{sep}{snn}</b>", |
|
onTick: function (periods) { |
|
if($.countdown.periodsToSeconds(periods) < 60) { |
|
$(this).css("color", "red"); //Highlight last minute. |
|
} |
|
} |
|
}); |
|
} |
|
|
|
}); |
}); |
'; |
'; |
|
# Code to put a due date countdown in 'duedatecountdown' span. |
|
# This is currently located in the breadcrumb headers. |
|
# note that the dueDateLayout is internatinoalized below. |
|
# Here document is used to support the substitution into the javascript below. |
|
# ..which unfortunately necessitates escaping the $'s in the javascript. |
|
|
|
my $dueDateLayout = '<b>' . &mt('Due in: {dn} {dl} {hnn}{sep}{mnn}{sep}{snn}') . '</b>'; |
|
$output .= <<JAVASCRIPT; |
|
\$(document).ready(function() { |
|
if (typeof(dueDate) != "undefined") { |
|
\$("#duedatecountdown").countdown({until: dueDate, compact: true, |
|
layout: "$dueDateLayout", |
|
onTick: function (periods) { |
|
if(\$.countdown.periodsToSeconds(periods) < 60) { |
|
\$(this).css("color", "red"); //Highlight last minute. |
|
} |
|
} |
|
}); |
|
} |
|
}); |
|
JAVASCRIPT |
if ($dragmath_prefix ne '') { |
if ($dragmath_prefix ne '') { |
$output .= ' |
$output .= ' |
|
|