--- loncom/publisher/publisher.html 2003/12/10 00:32:56 1.35 +++ loncom/publisher/publisher.html 2004/04/07 18:02:47 1.37 @@ -81,9 +81,27 @@ function getcurseed() { return 0; } +function getproblemtype() { + if (parent.LONCAPAToBePublished.document.lonhomework) { + var optionelement; + var valueIndex=0; + for (var optionIndex=0; + optionIndex < parent.LONCAPAToBePublished.document.lonhomework.problemtype.options.length; + optionIndex++) + { + optionElement=parent.LONCAPAToBePublished.document.lonhomework.problemtype.options[optionIndex]; + if (optionElement.selected) { + return optionElement.value; + } + } + } + return 0; +} + function getpostdata() { document.printout.postdata.value=frameloc(); document.printout.curseed.value=getcurseed(); + document.printout.problemtype.value=getproblemtype(); document.printout.submit(); } @@ -116,6 +134,7 @@ function getpostdata() { + @@ -150,7 +169,7 @@ function getpostdata() { - +