Go to the source code of this file.
Namespaces | |
| namespace | ilias |
admin objects frameset | |
Functions | |
| getUserAgreement () | |
Variables | |
| $languages = $lng->getInstalledLanguages() | |
| $count = (int) round(count($languages) / 2) | |
| $num = 1 | |
| getUserAgreement | ( | ) |
Definition at line 109 of file view_usr_agreement.php.
References $ilias, $ilLog, and $lng.
{
global $lng, $ilias, $ilLog;
$tmpPath = getcwd();
$tmpsave = getcwd();
$agrPath = $tmpPath."/agreement";
chdir($agrPath);
$agreement = "agreement_".$lng->lang_key.".html";
// fall back to default language if selected translated user agreement of selected language was not found
if (!file_exists($agreement))
{
$ilLog->write("view_usr_agreement.php: Agreement file ".$agreement." has not been found (user language).");
$agreement = "agreement_".$lng->lang_default.".html";
}
// fall back to english if user agreement of selected language and
// user agreement of system language were not found
if (!file_exists($agreement))
{
$ilLog->write("view_usr_agreement.php: Agreement file ".$agreement." has not been found (system language).");
$agreement = "agreement_en.html";
}
if (file_exists($agreement))
{
if ($content = file($agreement))
{
foreach ($content as $key => $val)
{
$text .= trim(nl2br($val));
}
chdir($tmpsave);
return $text;
}
else
{
$ilias->raiseError($lng->txt("usr_agreement_empty"),$ilias->error_obj->MESSAGE);
}
}
else
{
$ilias->raiseError($lng->txt("file_not_found").": ".$agreement,
$ilias->error_obj->MESSAGE);
}
chdir($tmpsave);
}
| $count = (int) round(count($languages) / 2) |
Definition at line 48 of file view_usr_agreement.php.
Referenced by Spreadsheet_Excel_Writer_Worksheet::_storeExterncount(), ilStatistics::arithmetic_mean(), ilObjSystemFolderGUI::changeHeaderTitleObject(), ilSetup::checkClientLanguages(), ilObjCategoryGUI::createObject(), ilExerciseMembers::deliverReturnedFiles(), displayForm(), ilSetupGUI::displayHeader(), ilSetupGUI::displayLanguages(), ilObjCategoryGUI::editObject(), ilObjQuestionPoolGUI::executeCommand(), ilTemplate::fillVars(), ilStatistics::geometric_mean(), ilSCORMTree::getChilds(), ilTree::getChilds(), ilForum::getPostChilds(), ilStatistics::harmonic_mean(), ilObjTest::isComplete(), ilStatistics::median(), ilObjSysUserTrackingGUI::outputTrackingDataObject(), ilStatistics::quantile(), ilObjTestGUI::randomQuestionsObject(), ilStatistics::rank_median(), ilTableGUI::render(), ilObjTest::saveRandomQuestionpools(), ilElementList::selectDbAllLimited(), ilRepositoryGUI::showPossibleSubObjects(), ilObjUserFolderGUI::showPossibleSubObjects(), ilObjRoleFolderGUI::showPossibleSubObjects(), ilObjectGUI::showPossibleSubObjects(), ilLOListGUI::showPossibleSubObjects(), ilBookmarkAdministrationGUI::showPossibleSubObjects(), ilObjTestGUI::statusObject(), and ilTemplate::touchBlock().
| $languages = $lng->getInstalledLanguages() |
Definition at line 46 of file view_usr_agreement.php.
| $num = 1 |
Definition at line 49 of file view_usr_agreement.php.
Referenced by Spreadsheet_Excel_Writer_Parser::_convertNumber(), ilCourseContentInterface::cci_view(), ilObjContentObjectGUI::chapters(), ilObjLanguage::check(), ilObjLanguageFolder::checkAllLanguages(), ilLanguage::checkLanguage(), ilSetupGUI::displayClientList(), displayForm(), ilSetupGUI::displayHeader(), ilObjUserFolderGUI::displayList(), ilObjTypeDefinitionGUI::displayList(), ilObjSystemFolderGUI::displayList(), ilObjObjectFolderGUI::displayList(), ilObjLanguageFolderGUI::displayList(), ilObjectGUI::displayList(), ilLOListGUI::displayList(), ilSetupGUI::displayProcessPanel(), ilPersonalDesktopGUI::displayUsersOnline(), ilObjMediaObjectGUI::editFilesObject(), ilObjTypeDefinitionGUI::editObject(), ilObjGlossaryGUI::exportList(), ilObjContentObjectGUI::exportList(), ilObjSurveyQuestionPoolGUI::exportObject(), ilObjSurveyGUI::exportObject(), ilObjTestGUI::exportObject(), ilObjQuestionPoolGUI::exportObject(), ilObjForum::getCountNew(), ilObjSystemFolder::getHeaderTitleTranslations(), ilUtil::getObjectsByOperations(), ilObjTest::getQuestionCount(), ilObjCategory::getTranslations(), ilDOMXML::ilDOMXML(), ilObjLanguage::insert(), ilLanguage::insertLanguage(), iso_to_utf8(), ilFileSystemGUI::listFiles(), ilObjMediaPoolGUI::listMedia(), ilGlossaryPresentationGUI::listTermByGiven(), ilObjGlossaryGUI::listTerms(), ilObjSysUserTrackingGUI::outputTrackingDataObject(), ilObjContentObjectGUI::pages(), ilObjSurveyQuestionPoolGUI::permObject(), ilObjSurveyGUI::permObject(), ilObjectGUI::permObject(), ilObjTestGUI::permObject(), searchForm(), searchTest(), ilObjUserFolderGUI::searchUserObject(), ilRepositoryGUI::showCategories(), ilRepositoryGUI::showChats(), ilRepositoryGUI::showCourses(), ilLMPresentationGUI::showDownloadList(), ilRepositoryGUI::showExercises(), ilRepositoryGUI::showFiles(), ilRepositoryGUI::showFolders(), ilRepositoryGUI::showGlossaries(), ilRepositoryGUI::showGroups(), ilRepositoryGUI::showLearningResources(), ilRepositoryGUI::showMediaPools(), ilRepositoryGUI::showQuestionPools(), ilRepositoryGUI::showSurveyquestionpools(), ilRepositoryGUI::showSurveys(), ilRepositoryGUI::showTests(), ilObjSCORMLearningModuleGUI::showTrackingItem(), ilObjSCORMLearningModuleGUI::showTrackingItemPerUser(), ilObjSCORMLearningModuleGUI::showTrackingItems(), ilObjAICCLearningModuleGUI::showTrackingItems(), ilObjMediaObjectGUI::showUsagesObject(), ilStructureObjectGUI::subchap(), vd(), ilStructureObjectGUI::view(), ilEditClipboardGUI::view(), Spreadsheet_Excel_Writer_Worksheet::writeFormula(), Spreadsheet_Excel_Writer_Worksheet::writeNumber(), and XMLNestedSet::XMLNestedSet().
1.7.1