Skip to content

Commit

Permalink
Dev Some text fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
c-schmitz committed Feb 4, 2020
1 parent 5a39b15 commit 9a46fcf
Show file tree
Hide file tree
Showing 11 changed files with 22 additions and 21 deletions.
4 changes: 2 additions & 2 deletions application/controllers/admin/questionedit.php
Expand Up @@ -158,9 +158,9 @@ public function view($surveyid, $gid = null, $qid = null, $landOnSideMenuTab = '
"noCodeWarning" =>
gT("Please put in a valid code. Only letters and numbers are allowed and it has to start with a letter. For example [Question1]"),
"alreadyTaken" =>
gT("This code is already taken. Duplicate codes are not allowed."),
gT("This code is already used - duplicate codes are not allowed."),
"codeTooLong" =>
gT("Question code cannot be longer than 20 digits."),
gT("A question code cannot be longer than 20 characters."),
"Question cannot be stored. Please check the subquestion codes for duplicates or empty codes." =>
gT("Question cannot be stored. Please check the subquestion codes for duplicates or empty codes."),
"Question cannot be stored. Please check the answer option for duplicates or empty titles." =>
Expand Down
6 changes: 3 additions & 3 deletions application/core/plugins/statFunctions/statFunctions.php
Expand Up @@ -20,7 +20,7 @@
*/
class statFunctions extends PluginBase
{
protected static $description = 'Add some function in expression manager to get count from other responses';
protected static $description = 'Add some function in Expression Manager to get count from other responses';
protected static $name = 'statCountFunctions';

public function init()
Expand All @@ -35,7 +35,7 @@ public function newValidFunctions()
'statCountIf' => array(
'\statFunctions\countFunctions::statCountIf',
null, // No javascript function : set as static function
$this->gT("Count the response done with value equal to a specific value"), // Description for admin
$this->gT("Count the number of complete responses with a value equal to a specific value"), // Description for admin
'integer statCountIf(QuestionCode.sgqa, value[, submitted = true])', // Extra description
'https://www.limesurvey.org', // Help url
2, // Number of argument unsure it work here … , minimum 2, allow 3
Expand All @@ -44,7 +44,7 @@ public function newValidFunctions()
'statCount' => array(
'\statFunctions\countFunctions::statCount',
null, // No javascript function : set as static function
$this->gT("Count previous response done not empty"), // Description for admin
$this->gT("Count the number of complete responses which are not empty"), // Description for admin
'integer statCount(QuestionCode.sgqa[, submitted = true])', // Extra description
'https://www.limesurvey.org', // Help url
1, // Number of argument (time to make a good description of EM …) minimum 1, allow 2
Expand Down
7 changes: 4 additions & 3 deletions application/models/QuestionTheme.php
Expand Up @@ -820,16 +820,17 @@ static public function getQuestionXMLPathForBaseType($type)
public static function convertLS3toLS4($sXMLDirectoryPath)
{
$sXMLDirectoryPath = str_replace('\\', '/', $sXMLDirectoryPath);
$sConfigPath = $sXMLDirectoryPath . DIRECTORY_SEPARATOR . 'config.xml';
$bOldEntityLoaderState = libxml_disable_entity_loader(true);
$sQuestionConfigFilePath = App()->getConfig('rootdir') . DIRECTORY_SEPARATOR . $sXMLDirectoryPath . DIRECTORY_SEPARATOR . 'config.xml';
$sQuestionConfigFilePath = App()->getConfig('rootdir') . DIRECTORY_SEPARATOR . $sConfigPath;
$sQuestionConfigFile = file_get_contents($sQuestionConfigFilePath); // @see: Now that entity loader is disabled, we can't use simplexml_load_file; so we must read the file with file_get_contents and convert it as a string

if (!$sQuestionConfigFile) {
libxml_disable_entity_loader($bOldEntityLoaderState);
return $aSuccess = [
'message' => sprintf(
gT('No Configuration could be found for %s/config.xml'),
$sXMLDirectoryPath
gT('Configuration file %s could not be found or read.'),
$sConfigPath
),
'success' => false
];
Expand Down
8 changes: 4 additions & 4 deletions application/models/User.php
Expand Up @@ -109,14 +109,14 @@ public function attributeLabels() {
'users_name' => gT('Username'),
'password' => gT('Password'),
'full_name' => gT('Full name'),
'parent_id' => gT('Parent User'),
'parent_id' => gT('Parent user'),
'lang' => gT('Language'),
'email' => gT('Email'),
'htmleditormode' => gT('Editormode'),
'htmleditormode' => gT('Editor mode'),
'templateeditormode' => gT('Template editor mode'),
'questionselectormode' => gT('Question selector mode'),
'one_time_pw' => gT('One time password'),
'dateformat' => gT('Dateformat'),
'one_time_pw' => gT('One-time password'),
'dateformat' => gT('Date format'),
'created' => gT('Created at'),
'modified' => gT('Modified at'),
'lastLogin' => gT('Last recorded login'),
Expand Down
4 changes: 2 additions & 2 deletions application/views/admin/survey/Question/editQuestion_view.php
Expand Up @@ -75,7 +75,7 @@
'groupStructureArray' => $aQuestionTypeGroups,
'value' => $oQuestion->type,
'debug' => YII_DEBUG,
'currentSelected' => $selectedQuestion['title'] ?? gT('Invalid Question'),
'currentSelected' => $selectedQuestion['title'] ?? gT('Invalid question'),
'optionArray' => [
'selectedClass' => $selectedQuestion['settings']->class ?? 'invalid_question',
'onUpdate' => [
Expand Down Expand Up @@ -250,7 +250,7 @@
<div class=" btn-group" id="question_type_button">
<button type="button" class="btn btn-default" disabled aria-haspopup="true" aria-expanded="false">
<span class="buttontext" id="selector__editView_question_type_description">
<?= $selectedQuestion['title'] ?? gT('Invalid Question'); ?>
<?= $selectedQuestion['title'] ?? gT('Invalid question'); ?>
<?php if (YII_DEBUG): ?>
<em class="small">
Type code: <?php echo $oQuestion->type; ?>
Expand Down
Expand Up @@ -49,7 +49,7 @@
$this->widget('ext.LimeGridView.LimeGridView', array(
'id' => 'question-group-grid',
'dataProvider' => $model->search(),
'emptyText'=>gT('No survey pages found.'),
'emptyText'=>gT('No question groups found.'),
'summaryText'=>gT('Displaying {start}-{end} of {count} result(s).') .' '.sprintf(gT('%s rows per page'),
CHtml::dropDownList(
'pageSize',
Expand Down
2 changes: 1 addition & 1 deletion application/views/admin/survey/activateSurvey_view.php
Expand Up @@ -36,7 +36,7 @@
</p>

<p>
<button class="btn btn-default" id="ajaxAllConsistency"><?=gT("Solve all issues")?></button>
<button class="btn btn-default" id="ajaxAllConsistency"><?=gT("Resolve all issues")?></button>
<a class="btn btn-default" href="<?php echo $this->createUrl("admin/survey/sa/view/surveyid/$surveyid"); ?>" role="button">
<?php eT("Return to survey"); ?>
</a>
Expand Down
4 changes: 2 additions & 2 deletions application/views/admin/survey/topbar/question_topbar.php
Expand Up @@ -414,7 +414,7 @@
'class' => 'btn-default',
'id' => 'import-button',
'icon' => 'icon-import',
'name' => gT('Import Question'),
'name' => gT('Import question'),
];
} else {
// survey active
Expand All @@ -423,7 +423,7 @@
'class' => 'btn-default readonly',
'id' => 'import-button',
'icon' => 'icon-import',
'name' => gT('Import Question'),
'name' => gT('Import question'),
];
}
array_push($topbar['alignment']['left']['buttons'], $buttons['import']);
Expand Down
2 changes: 1 addition & 1 deletion application/views/admin/tutorialentries/index.php
Expand Up @@ -8,7 +8,7 @@
<div class="container-fluid ls-space padding left-50 right-50">
<div class="ls-flex-column ls-space padding left-35 right-35">
<div class="col-12 h1 pagetitle">
<?php eT('Tutorialentries')?>
<?php eT('Tutorial entries')?>
</div>
<div class="col-12">
<a class="btn btn-primary pull-right col-xs-6 col-sm-3 col-md-2" id="createnewtutorialentry" >
Expand Down
2 changes: 1 addition & 1 deletion application/views/admin/user/personalsettings.php
Expand Up @@ -60,7 +60,7 @@
'groupStructureArray' => $aQuestionTypeGroups,
'value' => $currentPreselectedQuestiontype,
'debug' => YII_DEBUG,
'currentSelected' => $selectedQuestion['title'] ?? gT('Invalid Question'),
'currentSelected' => $selectedQuestion['title'] ?? gT('Invalid question'),
'buttonClasses' => ['btn-primary'],
'optionArray' => [
'selectedClass' => $selectedQuestion['settings']->class ?? 'invalid_question',
Expand Down
2 changes: 1 addition & 1 deletion application/views/installer/dbconfig_view.php
Expand Up @@ -63,7 +63,7 @@ function checkDbEngine(){
<div id="InstallerConfigForm_dbengine_row" class="form-group">
<?= CHtml::activeLabelEx($model, 'dbengine'); ?>
<?= CHtml::activeDropDownList($model, 'dbengine', $model->dbEngines, array('prompt'=>gT("Select"), 'autocomplete'=>'off', 'class' => 'form-control')); ?>
<div class="alert alert-warning"><?= gT('Warning! Using InnoDb instead of MyIsam will reduce the possible maximum number of questions in your surveys. Please read more about MyIsam vs InnoDB table column limitations in our manual before selecting InnoDB.'); ?></div>
<div class="alert alert-warning"><?= gT('Warning! Using InnoDB instead of MyISAM will reduce the possible maximum number of questions in your surveys. Please read more about MyISAM vs InnoDB table column limitations in our manual before selecting InnoDB.'); ?></div>
</div>

<div id="InstallerConfigForm_dblocation_row" class="form-group">
Expand Down

0 comments on commit 9a46fcf

Please sign in to comment.