Forum .LRN Q&A: Re: Res: Re: Problems integratin IMS-LD and IMS-QTI

Collapse
Posted by javier morales on
Hi Jose,

I tried to do what you said, and it's not working.

I defined the resource like imsqti_xmlv1p1 or imsqti_item_xmlv2p0, but it seems that it is another thing.

I define the imsmanifest.xml file from the test with this part:

...
        <resources>
                <resource identifier="RESOURCE1" type="imsqti_xmlv1p1" href="imsqti-impeval.xml">
                        <file href="imsqti-impeval.xml" />
                </resource>
        </resources>
...

Then in the imsmanifest from the course I define this test, as a new activity with one resource, like:

...                                        <imsld:learning-activity identifier="LA-task4.1" isvisible="true">
                                              <imsld:title>4.1. Impressionism Evaluation</imsld:title>
                                                <imsld:environment-ref ref="ENV-webquestart"/>
                                                <imsld:activity-description>
                                                        <imsld:item identifierref="resource-impressionism-eval" isvisible="true">
                                                                <imsld:title>Impressionism Eval</imsld:title>
                                                        </imsld:item>
                                                </imsld:activity-description>
                                                <imsld:complete-activity>
                                                        <imsld:user-choice />
                                                </imsld:complete-activity>
                                        </imsld:learning-activity>

...
                <resource type="imsqti_xmlv1p1" identifier="resource-impressionism-eval" href="resources/imsqti-impeval.zip">
                        <file href="resources/imsqti-impeval.zip"/>
                </resource>
...

Do I have to do anything else?? Where is the problem??

Thanks, javier

Hi Javier,

In the assessment tcl code, please check if you have the following code into the "as-callback-procs.tcl" file:

--------
ad_proc -public -callback imsld::import -impl qti {} {
this is the imsld qti importer
} {
if {$res_type == "imsqti_xmlv1p0" || $res_type == "imsqti_xmlv1p1" || $res_type =="imsqti_item_xmlv2p0"} {
return [as::qti::register_xml_object_id \
-xml_file $tmp_dir/$res_href \
-community_id $community_id]
}
}
--------

This code must be executed when parsing the manifest and a QTI resource is detected. If you have this code and you have checked that is being executed while parsing, then we should go deep into the problem.

Cheers,
Luis

Hi Luis,

I found in the file

/dotlrn/packages/assessment/tcl/as-callback-procs.tcl

the next:

...
ad_proc -public -callback imsld::import -impl qti {} {
    this is the imsld qti importer
} {
        if {$res_type == "imsqti_xmlv1p0" || $res_type == "imsqti_xmlv1p1" || $res_type =="imsqti_item_xmlv2p0"} {
            return [as::qti::register_xml_object_id \
                        -xml_file $tmp_dir/$res_href \
                        -community_id $community_id]
        }
}
...

It seems the same...

Now I know, that I have the same code, which is the way to check if it's being executed??

I'm new in this "world" of OpenACS and dotLRN and I really don't know if it's something of the platform or just, that I'm making any mistake in my code.

I'm trying to find a course that could upload without problems, but I didn't have lucky yet...

Regards, javier