Skip to content

Commit

Permalink
Fixed a orientation bug in the login mask for login button
Browse files Browse the repository at this point in the history
Fixed import of attributes from v1.0 surveys
Fixed access denied error message on survey import



git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/phpsurveyor@2452 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
c-schmitz committed Feb 27, 2007
1 parent 0bdb1e2 commit aed7c81
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
7 changes: 3 additions & 4 deletions admin/access_denied.php
Expand Up @@ -115,14 +115,13 @@
$accesssummary .= "<p>".$clang->gT("You are not allowed to delete this group!")."</p>";
$accesssummary .= "<a href='$scriptname?action=editusergroups'>".$clang->gT("Continue")."</a><br />&nbsp;\n";
}


/*elseif(returnglobal('action') == "importsurvey")
elseif($action == "importsurvey")
{
$accesssummary .= "<p>".$clang->gT("You are not allowed to import a survey!")."</p>";
$accesssummary .= "<a href='$scriptname?sid={$sid}'>".$clang->gT("Continue")."</a><br />&nbsp;\n";
}
elseif(returnglobal('action') == "importgroup")

/*elseif(returnglobal('action') == "importgroup")
{
$accesssummary .= "<p>".$clang->gT("You are not allowed to import a group!")."</p>";
$accesssummary .= "<a href='$scriptname?sid={$sid}'>".$clang->gT("Continue")."</a><br />&nbsp;\n";
Expand Down
7 changes: 4 additions & 3 deletions admin/importsurvey.php
Expand Up @@ -284,11 +284,12 @@ function array_combine($a, $b) {
}
for ($i=0; $i<=$stoppoint+1; $i++)
{
if ($i<$stoppoint-2 || $i==count($bigarray)-1) {$question_attributesarray[] = $bigarray[$i];}
if ($i<$stoppoint-2) {$question_attributesarray[] = $bigarray[$i];}
unset($bigarray[$i]);
}
$bigarray = array_values($bigarray);


//ASSESSMENTS
if (array_search("# SURVEYS_LANGUAGESETTINGS TABLE\n", $bigarray))
{
Expand Down Expand Up @@ -369,7 +370,7 @@ function array_combine($a, $b) {

// Use the existing surveyid if it does not already exists
// This allows the URL links to the survey to keep working because the sid did not change
$newsid = $surveyid;
$newsid = $surveyid;
$isquery = "SELECT sid FROM {$dbprefix}surveys WHERE sid=$newsid";
$isresult = db_execute_assoc($isquery);
if ($isresult->RecordCount()>0)
Expand Down Expand Up @@ -1019,7 +1020,7 @@ function array_combine($a, $b) {
$importsurvey .= "<strong>".$clang->gT("Import of Survey is completed.")."</strong><br />\n";
$importsurvey .= "</td></tr></table><br />\n";
unlink($the_full_file_path);

unset ($surveyid); // Crazy but necessary because else the html script will search for user rights

function convertToArray($stringtoconvert, $seperator, $start, $end)
// this function is still used to read SQL files from version 1.0 or older
Expand Down
2 changes: 1 addition & 1 deletion admin/login_check.php
Expand Up @@ -86,7 +86,7 @@
<tr>
<td>&nbsp;</td>
<td align='center'><input type='hidden' name='action' value='login' />
<td align='center'><input type='hidden' name='refererargs' value='".$refererargs."' />
<input type='hidden' name='refererargs' value='".$refererargs."' />
<input class='action' type='submit' value='Login' /><br />&nbsp;\n</td>
</tr>
<tr>
Expand Down

0 comments on commit aed7c81

Please sign in to comment.