version 1.21, 2003/04/18 20:21:38
|
version 1.28, 2004/05/27 06:26:19
|
Line 304 function stringeval() {
|
Line 304 function stringeval() {
|
draw(); |
draw(); |
} |
} |
|
|
|
function radiostringeval(newval) { |
|
svalue=newval; |
|
draw(); |
|
} |
|
|
function intervaldis() { |
function intervaldis() { |
csecs=svalue; |
csecs=svalue; |
cdays=Math.floor(csecs/86400); |
cdays=Math.floor(csecs/86400); |
Line 323 function pickcolor(picked) {
|
Line 328 function pickcolor(picked) {
|
|
|
function colorfield(ir,ig,ib) { |
function colorfield(ir,ig,ib) { |
var col=new Array; |
var col=new Array; |
col=["00","11","22","33","44","55","66","77","88","99","AA","BB","CC","DD","EE","FF"]; |
col=["00","11","22","44","66","88","AA","CC","DD","EE","FF"]; |
var color='#'+col[ir]+col[ig]+col[ib]; |
var color='#'+col[ir]+col[ig]+col[ib]; |
var selection=" "; |
var selection="<font color='"+color+"'>X</font>"; |
if (color==svalue) { selection="X"; } |
if (color==svalue) { selection="<font color='#"+col[10-ir]+col[10-ig]+col[10-ib]+"'>X</font>"; } |
choicewrite('<td bgcolor="'+color+'"><a href="javascript:parent.pickcolor('+"'"+ |
choicewrite('<td bgcolor="'+color+'"><a href="javascript:parent.pickcolor('+"'"+ |
color+"'"+')">'+selection+'</a></td>'); |
color+"'"+')">'+selection+'</a></td>'); |
|
|
Line 420 function draw() {
|
Line 425 function draw() {
|
choicewrite('</table>'); |
choicewrite('</table>'); |
} else { |
} else { |
if (pscat=='start') { |
if (pscat=='start') { |
tablestart('Starting or opening date and time'); |
tablestart('Date and time'); |
} |
} |
if (pscat=='end') { |
if (pscat=='end') { |
tablestart('Ending or closing date and time'); |
tablestart('Date and time'); |
} |
} |
if (pscat=='interval') { |
if (pscat=='interval') { |
tablestart('Time interval'); |
tablestart('Time interval'); |
Line 520 function draw() {
|
Line 525 function draw() {
|
tablestart('Default value or none'); |
tablestart('Default value or none'); |
choicewrite('</table>'); |
choicewrite('</table>'); |
} else { |
} else { |
if (pscat=='any') { |
if ((pscat=='any') || (pscat=='') || (typeof(pscat)=='undefined')) { |
tablestart('Text'); |
tablestart('Text'); |
|
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="stringval" size="20" value="'+svalue+ |
|
'" type="text" onChange="parent.stringeval()">'); |
} |
} |
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
if (pscat=='yesno') { |
choicewrite('<input name=stringval size=20 value="'+svalue+ |
tablestart('Yes/No'); |
'" name=stringval onChange="parent.stringeval()">'); |
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="stringval" value="yes"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'yes\')"'); |
|
if (svalue=='yes') { choicewrite(' checked'); } |
|
choicewrite('> Yes<br />'); |
|
choicewrite('<input name="stringval" value="no"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'no\')"'); |
|
if (svalue=='no') { choicewrite(' checked'); } |
|
choicewrite('> No<br />'); |
|
} |
|
if (pscat=='examtype') { |
|
tablestart('Exam Type'); |
|
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="stringval" value="online"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'online\')"'); |
|
if (svalue=='online') { choicewrite(' checked'); } |
|
choicewrite('> Online<br />'); |
|
choicewrite('<input name="stringval" value="checkout"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'checkout\')"'); |
|
if (svalue=='checkout') { choicewrite(' checked'); } |
|
choicewrite('> Check out<br />'); |
|
} |
|
if (pscat=='questiontype') { |
|
tablestart('Question Type'); |
|
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="stringval" value="problem"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'problem\')"'); |
|
if (svalue=='problem') { choicewrite(' checked'); } |
|
choicewrite('> Standard Problem<br />'); |
|
choicewrite('<input name="stringval" value="quiz"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'quiz\')"'); |
|
if (svalue=='quiz') { choicewrite(' checked'); } |
|
choicewrite('> Quiz<br />'); |
|
choicewrite('<input name="stringval" value="exam"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'exam\')"'); |
|
if (svalue=='exam') { choicewrite(' checked'); } |
|
choicewrite('> Exam<br />'); |
|
choicewrite('<input name="stringval" value="assess"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'assess\')"'); |
|
if (svalue=='assess') { choicewrite(' checked'); } |
|
choicewrite('> Assessment<br />'); |
|
choicewrite('<input name="stringval" value="survey"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'survey\')"'); |
|
if (svalue=='survey') { choicewrite(' checked'); } |
|
choicewrite('> Survey<br />'); |
|
choicewrite('<input name="stringval" value="form"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'form\')"'); |
|
if (svalue=='form') { choicewrite(' checked'); } |
|
choicewrite('> Input Form<br />'); |
|
choicewrite('<input name="stringval" value="library"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'library\')"'); |
|
if (svalue=='library') { choicewrite(' checked'); } |
|
choicewrite('> Library<br />'); |
|
} |
|
if (pscat=='ip') { |
|
tablestart('IP Number/Name'); |
|
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="stringval" size="20" value="'+svalue+ |
|
'" onChange="parent.stringeval()">'); |
|
} |
|
if (pscat=='fileext') { |
|
tablestart('Allowed File Extensions'); |
|
choicewrite('<tr bgcolor="#AAFFAA"><td>Value:</td><td colspan=2>'); |
|
choicewrite('<input name="radstringval" value="txt"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'txt\')"'); |
|
if (svalue=='txt') { choicewrite(' checked'); } |
|
choicewrite('> Plain Text<br />'); |
|
choicewrite('<input name="radstringval" value="png,jpg,jpeg,gif"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'png,jpg,jpeg,gif\')"'); |
|
if (svalue=='png,jpg,jpeg,gif') { choicewrite(' checked'); } |
|
choicewrite('> Picture File<br />'); |
|
choicewrite('<input name="radstringval" value="doc,xls,ppt"'+ |
|
' type="radio" onChange="parent.radiostringeval(\'doc,xls,ppt\')"'); |
|
if (svalue=='doc,xls,ppt') { choicewrite(' checked'); } |
|
choicewrite('> Office Document<br />'); |
|
choicewrite('<input name="stringval" size="20" value="'+svalue+ |
|
'" onChange="parent.stringeval()">'); |
|
} |
choicewrite('</td></table>'); |
choicewrite('</td></table>'); |
} |
} |
} |
} |
Line 534 function draw() {
|
Line 619 function draw() {
|
tablestart('Choose a Color'); |
tablestart('Choose a Color'); |
choicewrite('<table>'); |
choicewrite('<table>'); |
if (svalue) { |
if (svalue) { |
choicewrite('<tr><td colspan="10">Current choice:</td><td bgcolor="'+ |
choicewrite('<tr><td colspan="9">Current choice:</td><td bgcolor="'+ |
svalue+'" colspan="6"> </td></tr>'); |
svalue+'" colspan="2"> </td></tr>'); |
} |
} |
for (var ir=1; ir<=15; ir++) { |
for (var ir=0; ir<=10; ir++) { |
for (var ig=1; ig<=15; ig++) { |
for (var ig=0; ig<=10; ig++) { |
choicewrite('<tr>'); |
choicewrite('<tr>'); |
for (var ib=1; ib<=15; ib++) { |
for (var ib=0; ib<=10; ib++) { |
colorfield(ir,ig,ib); |
colorfield(ir,ig,ib); |
} |
} |
choicewrite('</tr>'); |
choicewrite('</tr>'); |
Line 717 function init() {
|
Line 802 function init() {
|
|
|
if (ptype=='string') { |
if (ptype=='string') { |
sopt('default','Default'); |
sopt('default','Default'); |
sopt('string','String Value'); |
sopt('any','String Value'); |
|
} |
|
|
|
if (ptype=='color') { |
|
sopt('default','Use Default Color'); |
|
sopt('custom','Use Custom Color'); |
} |
} |
|
|
selwrite('</select></form>'); |
selwrite('</select></form>'); |