[Fusionforge-commits] r18544 - trunk/src/www/survey/include

Marc-Etienne VARGENAU vargenau at fusionforge.org
Mon Dec 2 17:59:43 CET 2013


Author: vargenau
Date: 2013-12-02 17:59:43 +0100 (Mon, 02 Dec 2013)
New Revision: 18544

Modified:
   trunk/src/www/survey/include/SurveyHTML.class.php
Log:
Use CSS; add HTML 5 required

Modified: trunk/src/www/survey/include/SurveyHTML.class.php
===================================================================
--- trunk/src/www/survey/include/SurveyHTML.class.php	2013-12-02 16:25:30 UTC (rev 18543)
+++ trunk/src/www/survey/include/SurveyHTML.class.php	2013-12-02 16:59:43 UTC (rev 18544)
@@ -127,11 +127,10 @@
 		$ret.='<input type="hidden" name="question_id" value="'.$question_id.'" />';
 		$ret.='<input type="hidden" name="form_key" value="' . form_generate_key() . '" />';
 		$ret.=_('Question')._(':').'<br />';
-		$ret.='<input type="text" name="question" value="'.$question.'" size="60" maxlength="150" /></p>';
+		$ret.='<input required="required" type="text" name="question" value="'.$question.'" size="60" maxlength="150" /></p>';
 		$ret.='<p>'. _('Question Type')._(':').'<br />';
 
-		$result = db_query_params ('SELECT * FROM survey_question_types',
-					   array());
+		$result = db_query_params ('SELECT * FROM survey_question_types', array());
 		$ret.= html_build_select_box($result,'question_type',$question_type,false);
 
 		$ret.='</p><p><input type="submit" name="submit" value="'.$question_button.'" /></p>' . "\n";
@@ -609,7 +608,7 @@
 				}
 				$ret.= $this->drawGraph($Question->getID(), 'hbar', $legendArr, $valuesArr);
 			} else {
-				$ret.= '<table style="padding-left: 3em" width="100%">';
+				$ret.= '<table style="padding-left: 3em; width: 100%">';
 
 				for ($j=5; $j>=0; $j--) {
 					$percent = (float)$results[$j]*100/$votes;
@@ -636,7 +635,7 @@
 				}
 				$ret.= $this->drawGraph($Question->getID(), 'pie', $legendArr, $valuesArr);
 			} else {
-				$ret.= '<table style="padding-left: 3em" width="100%">';
+				$ret.= '<table style="padding-left: 3em; width: 100%">';
 				for ($j=1; $j<=3; $j++) {
 					$result_per[$j] = (float)$res[$j]*100/$votes;
 					$ret.= $this->_makeBar($arr_name[$j].' ('.$res[$j].')', $result_per[$j], $arr_color[$j]);




More information about the Fusionforge-commits mailing list