[svn r18415] Minor - Logic change - Fixed import HotPotatoes tests due to the new button - see FS#3345

skala
Cristian Fasanando 17 years ago
parent 7fcbd839a7
commit 7955adf4ed
  1. 5
      main/exercice/hotpotatoes.lib.php
  2. 4
      main/exercice/hotpotatoes.php

@ -22,7 +22,7 @@
* Code library for HotPotatoes integration. * Code library for HotPotatoes integration.
* @package dokeos.exercise * @package dokeos.exercise
* @author Istvan Mandak * @author Istvan Mandak
* @version $Id: hotpotatoes.lib.php 13384 2007-10-04 09:08:37Z elixir_inter $ * @version $Id: hotpotatoes.lib.php 18415 2009-02-10 18:58:55Z cfasanando $
*/ */
@ -152,13 +152,14 @@ function GetFileName($fname)
*/ */
function ReadFileCont($full_file_path) function ReadFileCont($full_file_path)
{ {
if(is_file($full_file_path)) {
if (!($fp = fopen(urldecode($full_file_path), "r"))) { if (!($fp = fopen(urldecode($full_file_path), "r"))) {
// if (!($fp = fopen($full_file_path, "r"))) {
return ""; return "";
} }
$contents = fread($fp, filesize($full_file_path)); $contents = fread($fp, filesize($full_file_path));
fclose($fp); fclose($fp);
return $contents; return $contents;
}
} }
/** /**

@ -22,7 +22,7 @@
* Code for Hotpotatoes integration. * Code for Hotpotatoes integration.
* @package dokeos.exercise * @package dokeos.exercise
* @author Istvan Mandak * @author Istvan Mandak
* @version $Id: hotpotatoes.php 18210 2009-02-03 21:43:48Z herodoto $ * @version $Id: hotpotatoes.php 18415 2009-02-10 18:58:55Z cfasanando $
*/ */
@ -279,7 +279,7 @@ if(($is_allowedToEdit) && (($finish == 0) || ($finish == 2)))
echo '<td width="250">'; echo '<td width="250">';
echo '</td>'; echo '</td>';
echo '<td>'; echo '<td>';
echo '<button type="submit" name="submit">'.get_lang('Send').'</button>'; echo '<button type="submit" name="submit" value="'.get_lang('Send').'">'.get_lang('Send').'</button>';
echo '</td>'; echo '</td>';
echo '</tr>'; echo '</tr>';
echo '</table>'; echo '</table>';

Loading…
Cancel
Save