Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

Upgrading Script To Transfer From WebCT To Moodle: Difference between revisions

From MoodleDocs
No edit summary
 
No edit summary
Line 3: Line 3:
The initial course name (i.e. CHI2300_1) is used in the quizDB so it should be stored during this first step. It is added as a input type ="hidden" and stored in  global $data
The initial course name (i.e. CHI2300_1) is used in the quizDB so it should be stored during this first step. It is added as a input type ="hidden" and stored in  global $data


  echo "\n  <li>&lt;form action='./'><strong>$nxtfile</strong><br />Import this file using course code "
  echo "\n  &lt;li> &lt;form action='./'>&lt;strong>$nxtfile&lt;/strong><br />Import this file using course code "
. "<input type='text' name='crscode' maxlength='15' value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>"
  . " &lt;input type='text' name='crscode' maxlength='15'
      '''. "<input type='hidden' name='initialcrscode' maxlength='15' value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>"'''
      value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>"
  . "<input type='hidden' name='zipfile' value='".htmlspecialchars($nxtfile)."'/>"
      '''
  . "<input type='hidden' name='action' value='process'/>"
'''. "&lt;input type='hidden' name='initialcrscode' maxlength='15'
value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>"'''
. "&lt;input type='hidden' name='zipfile' value='".htmlspecialchars($nxtfile)."'/>"
 
. "&lt;input type='hidden' name='action' value='process'/>"

Revision as of 16:53, 30 October 2006

Description of the code modifications done initially most as a day-to-day work reports.

index.php

The initial course name (i.e. CHI2300_1) is used in the quizDB so it should be stored during this first step. It is added as a input type ="hidden" and stored in global $data

echo "\n  <li> <form action='./'><strong>$nxtfile</strong>
Import this file using course code " . " <input type='text' name='crscode' maxlength='15' value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>" . "<input type='hidden' name='initialcrscode' maxlength='15' value='".htmlspecialchars(preg_replace('/^(.*?)_COURSE.*$/', "$1", $nxtfile))."'/>" . "<input type='hidden' name='zipfile' value='".htmlspecialchars($nxtfile)."'/>"

. "<input type='hidden' name='action' value='process'/>"