Annotation of loncom/homework/templates/examupload.problem, revision 1.6

1.1       www         1: <problem>
                      2: <displaytitle />
1.4       albertel    3: <parameter name="scoreformat" description="Format for display of score" default="0f" type="string" />
1.1       www         4: <script type="loncapa/perl">
                      5: $weight=&EXT('resource.0.weight');
1.3       albertel    6: if ((!defined($weight)) || ($weight eq '')) { $weight=1; }
1.1       www         7: $awarded=&EXT('user.resource.resource.0.awarded');
                      8: if (!defined($awarded)) { $awarded=0; }
1.4       albertel    9: $scoreformat=&EXT('resource.0.scoreformat');
                     10: if (!defined($scoreformat) || $scoreformat eq '') { $scoreformat="2f"; }
1.1       www        11: </script>
                     12: <startouttext />
1.4       albertel   13: You have <display>&format($awarded*$weight,$scoreformat)</display> out of $weight possible points.
1.6     ! www        14: <instructorcomment>
        !            15: <font color="red">
        !            16: <br />If non-integer points are used (e.g., 3.5), make sure to change the
        !            17: display format in PPRM, or the result will be displayed in rounded form.
        !            18: </font>
        !            19: </instructorcomment>
1.1       www        20: <endouttext />
1.5       albertel   21: <block condition="0"><numericalresponse id='score' /></block>
1.1       www        22: </problem>

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>