Skip to content

Commit

Permalink
Dev Fixed some invalid concatenation
Browse files Browse the repository at this point in the history
  • Loading branch information
c-schmitz committed Nov 22, 2017
1 parent 9934922 commit f804ed9
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 15 deletions.
2 changes: 1 addition & 1 deletion application/controllers/admin/globalsettings.php
Expand Up @@ -317,7 +317,7 @@ private function _saveSettings()
setGlobalSetting('rpc_publish_api', (bool) $_POST['rpc_publish_api']);
setGlobalSetting('characterset', $_POST['characterset']);
setGlobalSetting('sideMenuBehaviour', Yii::app()->getRequest()->getPost('sideMenuBehaviour', 'adaptive'));
$savetime = ((float) $_POST['timeadjust']) * 60.' minutes'; //makes sure it is a number, at least 0
$savetime = intval((float) $_POST['timeadjust'] * 60).' minutes'; //makes sure it is a number, at least 0
if ((substr($savetime, 0, 1) != '-') && (substr($savetime, 0, 1) != '+')) {
$savetime = '+'.$savetime;
}
Expand Down
26 changes: 13 additions & 13 deletions application/helpers/export_helper.php
Expand Up @@ -131,10 +131,10 @@ function SPSSExportData($iSurveyID, $iLength, $na = '', $q = '\'', $header = FAL
case 'Y': // Yes/No Question Type
switch ($row[$fieldno]) {
case 'Y':
echo($q.1.$q);
echo($q.'1'.$q);
break;
case 'N':
echo($q.2.$q);
echo($q.'2'.$q);
break;
default:
echo($na);
Expand All @@ -143,10 +143,10 @@ function SPSSExportData($iSurveyID, $iLength, $na = '', $q = '\'', $header = FAL
case 'G': //Gender
switch ($row[$fieldno]) {
case 'F':
echo($q.1.$q);
echo($q.'1'.$q);
break;
case 'M':
echo($q.2.$q);
echo($q.'2'.$q);
break;
default:
echo($na);
Expand All @@ -155,13 +155,13 @@ function SPSSExportData($iSurveyID, $iLength, $na = '', $q = '\'', $header = FAL
case 'C': //Yes/No/Uncertain
switch ($row[$fieldno]) {
case 'Y':
echo($q.1.$q);
echo($q.'1'.$q);
break;
case 'N':
echo($q.2.$q);
echo($q.'2'.$q);
break;
case 'U':
echo($q.3.$q);
echo($q.'3'.$q);
break;
default:
echo($na);
Expand All @@ -170,13 +170,13 @@ function SPSSExportData($iSurveyID, $iLength, $na = '', $q = '\'', $header = FAL
case 'E': //Increase / Same / Decrease
switch ($row[$fieldno]) {
case 'I':
echo($q.1.$q);
echo($q.'1'.$q);
break;
case 'S':
echo($q.2.$q);
echo($q.'2'.$q);
break;
case 'D':
echo($q.3.$q);
echo($q.'3'.$q);
break;
default:
echo($na);
Expand All @@ -186,9 +186,9 @@ function SPSSExportData($iSurveyID, $iLength, $na = '', $q = '\'', $header = FAL
case 'M':
if (substr($field['code'], -7) != 'comment' && substr($field['code'], -5) != 'other') {
if ($row[$fieldno] == 'Y') {
echo($q.1.$q);
echo($q.'1'.$q);
} elseif (isset($row[$fieldno])) {
echo($q.0.$q);
echo($q.'0'.$q);
} else {
echo($na);
}
Expand Down Expand Up @@ -363,7 +363,7 @@ function SPSSGetValues($field = array(), $qidattributes = null, $language) {
$answers['size'] = $size;
return $answers;
} else {
/* Not managed (currently): url, IP, */
/* Not managed (currently): url, IP, … */
return;
}
}
Expand Down
1 change: 0 additions & 1 deletion third_party/doctrine/instantiator
Submodule instantiator deleted from 7af806

0 comments on commit f804ed9

Please sign in to comment.