當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Topic::setTopicID方法代碼示例

本文整理匯總了PHP中Topic::setTopicID方法的典型用法代碼示例。如果您正苦於以下問題:PHP Topic::setTopicID方法的具體用法?PHP Topic::setTopicID怎麽用?PHP Topic::setTopicID使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Topic的用法示例。


在下文中一共展示了Topic::setTopicID方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: getStatisticInfoPie

     // Versuche anzeigen mit bestandenen
     $value = getStatisticInfoPie($t_id);
     if ($value[0][1] == 0 && $value[1][1] == 0) {
         echo '<div class="h8 centered">' . Global_07 . '</div>';
     } else {
         showPie($value);
     }
     break;
 case 'topTen':
     // die besten 10 antworten
     $questions = 0;
     $questions = getQuestions($t_id);
     if (count($questions) == 0) {
         echo '<div class="h8 centered">' . Global_07 . "</div>";
     } else {
         $topics->setTopicID($t_id);
         $topics->setTopic($t_id);
         $Topic = $topics->getTopicName();
         echo "<br /><h2> " . Statistic_01 . " " . stripslashes($Topic) . "<br /></h2>";
         getTopTenCorrect($questions);
     }
     break;
 case 'flopTen':
     // die 10 schlechtest beantworteten Fragen
     $questions = 0;
     $questions = getQuestions($t_id);
     if (count($questions) == 0) {
         echo '<div class="h8 centered">' . Global_07 . "</div>";
     } else {
         $topics->setTopicID($t_id);
         $topics->setTopic($t_id);
開發者ID:eruedin,項目名稱:cats,代碼行數:31,代碼來源:statistic.php

示例2: array

             } else {
                 echo " <meta http-equiv='refresh' content='0; url=?site=topic&amp;action=new_topic&amp;error={$reply}' />";
             }
         }
     }
     break;
 case 'new_topic':
     // neues Topic
     if ($error) {
         $topics->setError($error);
     }
     $topics->newForm();
     break;
 case 'setTopicInactive':
     //inaktiv setzen
     $topics->setTopicID($t_id);
     $topics->setInactiveTopic();
     echo " <meta http-equiv='refresh' content='0; url=?site=topic' />";
     break;
 case 'setTopicAvtive':
     //aktivieren
     $topics->setTopicID($t_id);
     $topics->setActiveTopic();
     echo " <meta http-equiv='refresh' content='0; url=?site=topic' />";
     break;
 case 'delTopic':
     // Löschen eines Themas
     $questionArray = array();
     reallyDelTopic($t_id);
     if ($_REQUEST['submit'] == Global_13) {
         $topics->setTopicID($t_id);
開發者ID:eruedin,項目名稱:cats,代碼行數:31,代碼來源:topic.php

示例3: unset

 unset($_SESSION['values']['t_id']);
 unset($_SESSION['values']['return_site']);
 // Auswahl der gewählten Aktionen
 switch ($action) {
     case 'getQuestions':
         // Fragebogen genererien
         // Überbrüfung auf integer / Wertzuweisung
         $topic = 0;
         if (isset($_REQUEST["t_id"])) {
             $topic = abs(intval($_REQUEST["t_id"]));
         }
         // Session Variable leeren
         if (isset($_SESSION['values']['answerList'])) {
             unset($_SESSION['values']['answerList']);
         }
         $topics->setTopicID($topic);
         $numOfQu = $topics->getNumOfQu();
         $percentage = $topics->getRawToPass();
         $myQuiz->setTopicID($topic);
         $myQuiz->setQuestionLimit($numOfQu);
         $myQuiz->setRawToPass($percentage);
         $value = $myQuiz->generateQuestions();
         if ($value != 'notEnoughQuestions') {
             $myQuiz->getDBAnswers();
             $myQuiz->showQuiz();
             $t_id = $myQuiz->getTopicID();
         }
         break;
     case 'evaluate':
         // Fragebogen auswerten
         //Wertzuweisung und Initalisierung
開發者ID:eruedin,項目名稱:cats,代碼行數:31,代碼來源:start_test.php


注:本文中的Topic::setTopicID方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。