mirror of
https://github.com/acanas/swad-core.git
synced 2024-06-07 17:25:23 +02:00
Version 14.127.1
This commit is contained in:
parent
c0bc40c61a
commit
5843c57acf
|
@ -334,8 +334,9 @@ static void Asg_ShowOneAssignment (long AsgCod)
|
||||||
if (Gbl.CurrentCrs.Grps.NumGrps)
|
if (Gbl.CurrentCrs.Grps.NumGrps)
|
||||||
Asg_GetAndWriteNamesOfGrpsAssociatedToAsg (&Asg);
|
Asg_GetAndWriteNamesOfGrpsAssociatedToAsg (&Asg);
|
||||||
|
|
||||||
fprintf (Gbl.F.Out,"<p class=\"%s\" style=\"text-align:justify;\">"
|
fprintf (Gbl.F.Out,"<p class=\"%s\">"
|
||||||
"%s</p>"
|
"%s"
|
||||||
|
"</p>"
|
||||||
"</td>"
|
"</td>"
|
||||||
"</tr>",
|
"</tr>",
|
||||||
Asg.Hidden ? "DAT_LIGHT" :
|
Asg.Hidden ? "DAT_LIGHT" :
|
||||||
|
|
|
@ -358,7 +358,7 @@ static void Att_ShowOneAttEvent (struct AttendanceEvent *Att,bool ShowOnlyThisAt
|
||||||
if (Gbl.CurrentCrs.Grps.NumGrps)
|
if (Gbl.CurrentCrs.Grps.NumGrps)
|
||||||
Att_GetAndWriteNamesOfGrpsAssociatedToAttEvent (Att);
|
Att_GetAndWriteNamesOfGrpsAssociatedToAttEvent (Att);
|
||||||
|
|
||||||
fprintf (Gbl.F.Out,"<div class=\"%s\" style=\"text-align:justify;\">%s</div>",
|
fprintf (Gbl.F.Out,"<div class=\"%s\">%s</div>",
|
||||||
Att->Hidden ? "DAT_LIGHT" :
|
Att->Hidden ? "DAT_LIGHT" :
|
||||||
"DAT",
|
"DAT",
|
||||||
Txt);
|
Txt);
|
||||||
|
|
|
@ -103,11 +103,12 @@
|
||||||
/****************************** Public constants *****************************/
|
/****************************** Public constants *****************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 14.127 (2015/09/05)"
|
#define Log_PLATFORM_VERSION "SWAD 14.127.1 (2015/09/06)"
|
||||||
|
|
||||||
// Number of lines (includes comments but not blank lines) has been got with the following command:
|
// Number of lines (includes comments but not blank lines) has been got with the following command:
|
||||||
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
|
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
|
||||||
/*
|
/*
|
||||||
|
Version 14.127.1: Sep 06, 2015 Justify alignment is no longer used. (184259 lines)
|
||||||
Version 14.127: Sep 05, 2015 Changes in styles. (184273 lines)
|
Version 14.127: Sep 05, 2015 Changes in styles. (184273 lines)
|
||||||
Version 14.126.2: Sep 05, 2015 Changes in styles. (184250 lines)
|
Version 14.126.2: Sep 05, 2015 Changes in styles. (184250 lines)
|
||||||
Version 14.126.1: Sep 05, 2015 Changes in styles. (184213 lines)
|
Version 14.126.1: Sep 05, 2015 Changes in styles. (184213 lines)
|
||||||
|
|
18
swad_info.c
18
swad_info.c
|
@ -1577,8 +1577,7 @@ static void Inf_ShowPlainTxtInfo (Inf_InfoType_t InfoType)
|
||||||
Lay_WriteHeaderClassPhoto (3,false,false,Gbl.CurrentIns.Ins.InsCod,Gbl.CurrentDeg.Deg.DegCod,Gbl.CurrentCrs.Crs.CrsCod);
|
Lay_WriteHeaderClassPhoto (3,false,false,Gbl.CurrentIns.Ins.InsCod,Gbl.CurrentDeg.Deg.DegCod,Gbl.CurrentCrs.Crs.CrsCod);
|
||||||
|
|
||||||
fprintf (Gbl.F.Out,"<tr>"
|
fprintf (Gbl.F.Out,"<tr>"
|
||||||
"<td class=\"LEFT_MIDDLE\">"
|
"<td class=\"DAT LEFT_MIDDLE\">");
|
||||||
"<p class=\"DAT\" style=\"text-align:justify;\">");
|
|
||||||
|
|
||||||
/***** Convert to respectful HTML and insert links *****/
|
/***** Convert to respectful HTML and insert links *****/
|
||||||
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
||||||
|
@ -1589,8 +1588,7 @@ static void Inf_ShowPlainTxtInfo (Inf_InfoType_t InfoType)
|
||||||
fprintf (Gbl.F.Out,"%s",TxtHTML);
|
fprintf (Gbl.F.Out,"%s",TxtHTML);
|
||||||
|
|
||||||
/***** Finish table *****/
|
/***** Finish table *****/
|
||||||
fprintf (Gbl.F.Out,"</p>"
|
fprintf (Gbl.F.Out,"</td>"
|
||||||
"</td>"
|
|
||||||
"</tr>");
|
"</tr>");
|
||||||
Lay_EndRoundFrameTable ();
|
Lay_EndRoundFrameTable ();
|
||||||
}
|
}
|
||||||
|
@ -1746,22 +1744,20 @@ int Inf_WritePlainTextIntoHTMLBuffer (Inf_InfoType_t InfoType,char **HTMLBuffer)
|
||||||
Txt_INFO_TITLE[InfoType]); // Page title
|
Txt_INFO_TITLE[InfoType]); // Page title
|
||||||
|
|
||||||
/***** Write plain text into text buffer *****/
|
/***** Write plain text into text buffer *****/
|
||||||
fprintf (FileHTMLTmp,"<tr>"
|
fprintf (FileHTMLTmp,"<div class=\"DAT LEFT_MIDDLE\">\n");
|
||||||
"<td class=\"LEFT_MIDDLE\">"
|
|
||||||
"<p class=\"DAT\" style=\"text-align:justify;\">");
|
|
||||||
|
|
||||||
/* Convert to respectful HTML and insert links */
|
/* Convert to respectful HTML and insert links */
|
||||||
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
||||||
TxtHTML,Cns_MAX_BYTES_LONG_TEXT,false); // Convert from HTML to recpectful HTML
|
TxtHTML,Cns_MAX_BYTES_LONG_TEXT,false); // Convert from HTML to recpectful HTML
|
||||||
Str_InsertLinkInURLs (TxtHTML,Cns_MAX_BYTES_LONG_TEXT,60); // Insert links
|
Str_InsertLinkInURLs (TxtHTML,Cns_MAX_BYTES_LONG_TEXT,60); // Insert links
|
||||||
|
|
||||||
/* Write text */
|
/* Write text */
|
||||||
fprintf (FileHTMLTmp,"%s",TxtHTML);
|
fprintf (FileHTMLTmp,"%s",TxtHTML);
|
||||||
|
|
||||||
/***** Write end of page into file *****/
|
/***** Write end of page into file *****/
|
||||||
fprintf (FileHTMLTmp,"</p>\n"
|
fprintf (FileHTMLTmp,"</div>\n"
|
||||||
"</html>\n"
|
"</html>\n"
|
||||||
"</body>\n");
|
"</body>\n");
|
||||||
|
|
||||||
/***** Compute length of file *****/
|
/***** Compute length of file *****/
|
||||||
Length = (size_t) ftell (FileHTMLTmp);
|
Length = (size_t) ftell (FileHTMLTmp);
|
||||||
|
|
|
@ -135,7 +135,7 @@ static unsigned Svy_GetQstIndFromQstCod (long QstCod);
|
||||||
static unsigned Svy_GetNextQuestionIndexInSvy (long SvyCod);
|
static unsigned Svy_GetNextQuestionIndexInSvy (long SvyCod);
|
||||||
static void Svy_ListSvyQuestions (struct Survey *Svy,struct SurveyQuestion *SvyQst);
|
static void Svy_ListSvyQuestions (struct Survey *Svy,struct SurveyQuestion *SvyQst);
|
||||||
static void Svy_WriteParamEditQst (struct SurveyQuestion *SvyQst);
|
static void Svy_WriteParamEditQst (struct SurveyQuestion *SvyQst);
|
||||||
static void Svy_WriteQstStem (const char *Stem,const char *TextStyle);
|
static void Svy_WriteQstStem (const char *Stem);
|
||||||
static void Svy_WriteAnswersOfAQst (struct Survey *Svy,struct SurveyQuestion *SvyQst);
|
static void Svy_WriteAnswersOfAQst (struct Survey *Svy,struct SurveyQuestion *SvyQst);
|
||||||
static void Svy_DrawBarNumUsrs (unsigned NumUsrs,unsigned MaxUsrs);
|
static void Svy_DrawBarNumUsrs (unsigned NumUsrs,unsigned MaxUsrs);
|
||||||
static void Svy_ReceiveAndStoreUserAnswersToASurvey (long SvyCod);
|
static void Svy_ReceiveAndStoreUserAnswersToASurvey (long SvyCod);
|
||||||
|
@ -484,7 +484,7 @@ static void Svy_ShowOneSurvey (long SvyCod,struct SurveyQuestion *SvyQst,bool Sh
|
||||||
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
Str_ChangeFormat (Str_FROM_HTML,Str_TO_RIGOROUS_HTML,
|
||||||
Txt,Cns_MAX_BYTES_TEXT,false); // Convert from HTML to recpectful HTML
|
Txt,Cns_MAX_BYTES_TEXT,false); // Convert from HTML to recpectful HTML
|
||||||
Str_InsertLinkInURLs (Txt,Cns_MAX_BYTES_TEXT,60); // Insert links
|
Str_InsertLinkInURLs (Txt,Cns_MAX_BYTES_TEXT,60); // Insert links
|
||||||
fprintf (Gbl.F.Out,"<p class=\"%s\" style=\"text-align:justify;\">"
|
fprintf (Gbl.F.Out,"<p class=\"%s\">"
|
||||||
"%s"
|
"%s"
|
||||||
"</p>"
|
"</p>"
|
||||||
"</td>"
|
"</td>"
|
||||||
|
@ -3016,14 +3016,15 @@ static void Svy_ListSvyQuestions (struct Survey *Svy,struct SurveyQuestion *SvyQ
|
||||||
/* Write the question type (row[2]) */
|
/* Write the question type (row[2]) */
|
||||||
SvyQst->AnswerType = Svy_ConvertFromStrAnsTypDBToAnsTyp (row[2]);
|
SvyQst->AnswerType = Svy_ConvertFromStrAnsTypDBToAnsTyp (row[2]);
|
||||||
fprintf (Gbl.F.Out,"<td class=\"DAT_SMALL CENTER_TOP COLOR%u\">"
|
fprintf (Gbl.F.Out,"<td class=\"DAT_SMALL CENTER_TOP COLOR%u\">"
|
||||||
"%s",
|
"%s"
|
||||||
|
"</td>",
|
||||||
Gbl.RowEvenOdd,
|
Gbl.RowEvenOdd,
|
||||||
Txt_SURVEY_STR_ANSWER_TYPES[SvyQst->AnswerType]);
|
Txt_SURVEY_STR_ANSWER_TYPES[SvyQst->AnswerType]);
|
||||||
|
|
||||||
/* Write the stem (row[3]) */
|
/* Write the stem (row[3]) and the answers of this question */
|
||||||
Svy_WriteQstStem (row[3],"TEST_EDI");
|
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI LEFT_TOP COLOR%u\">",
|
||||||
|
Gbl.RowEvenOdd);
|
||||||
/* Write the answers of this question */
|
Svy_WriteQstStem (row[3]);
|
||||||
Svy_WriteAnswersOfAQst (Svy,SvyQst);
|
Svy_WriteAnswersOfAQst (Svy,SvyQst);
|
||||||
fprintf (Gbl.F.Out,"</td>"
|
fprintf (Gbl.F.Out,"</td>"
|
||||||
"</tr>");
|
"</tr>");
|
||||||
|
@ -3090,7 +3091,7 @@ static void Svy_WriteParamEditQst (struct SurveyQuestion *SvyQst)
|
||||||
/****************** Write the heading of a survey question *******************/
|
/****************** Write the heading of a survey question *******************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
static void Svy_WriteQstStem (const char *Stem,const char *TextStyle)
|
static void Svy_WriteQstStem (const char *Stem)
|
||||||
{
|
{
|
||||||
unsigned long LengthHeading;
|
unsigned long LengthHeading;
|
||||||
char *HeadingRigorousHTML;
|
char *HeadingRigorousHTML;
|
||||||
|
@ -3104,11 +3105,7 @@ static void Svy_WriteQstStem (const char *Stem,const char *TextStyle)
|
||||||
HeadingRigorousHTML,LengthHeading,false);
|
HeadingRigorousHTML,LengthHeading,false);
|
||||||
|
|
||||||
/* Write the stem */
|
/* Write the stem */
|
||||||
fprintf (Gbl.F.Out,"<td class=\"%s LEFT_TOP COLOR%u\">"
|
fprintf (Gbl.F.Out,"<tt>%s</tt>",HeadingRigorousHTML);
|
||||||
"<div style=\"text-align:justify;\">"
|
|
||||||
"<tt>%s</tt>"
|
|
||||||
"</div>",
|
|
||||||
TextStyle,Gbl.RowEvenOdd,HeadingRigorousHTML);
|
|
||||||
|
|
||||||
/* Free memory allocated for the stem */
|
/* Free memory allocated for the stem */
|
||||||
free ((void *) HeadingRigorousHTML);
|
free ((void *) HeadingRigorousHTML);
|
||||||
|
|
24
swad_test.c
24
swad_test.c
|
@ -983,7 +983,7 @@ void Tst_WriteQstStem (const char *Stem,const char *ClassStem)
|
||||||
StemRigorousHTML,StemLength,false);
|
StemRigorousHTML,StemLength,false);
|
||||||
|
|
||||||
/***** Write the stem *****/
|
/***** Write the stem *****/
|
||||||
fprintf (Gbl.F.Out,"<div class=\"%s\" style=\"text-align:justify;\">"
|
fprintf (Gbl.F.Out,"<div class=\"%s\">"
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
ClassStem,StemRigorousHTML);
|
ClassStem,StemRigorousHTML);
|
||||||
|
@ -1014,7 +1014,7 @@ void Tst_WriteQstFeedback (const char *Feedback,const char *ClassFeedback)
|
||||||
FeedbackRigorousHTML,FeedbackLength,false);
|
FeedbackRigorousHTML,FeedbackLength,false);
|
||||||
|
|
||||||
/***** Write the feedback *****/
|
/***** Write the feedback *****/
|
||||||
fprintf (Gbl.F.Out,"<div class=\"%s\" style=\"text-align:justify;\">"
|
fprintf (Gbl.F.Out,"<div class=\"%s\">"
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
ClassFeedback,FeedbackRigorousHTML);
|
ClassFeedback,FeedbackRigorousHTML);
|
||||||
|
@ -2768,19 +2768,14 @@ static void Tst_WriteAnswersOfAQstEdit (long QstCod)
|
||||||
|
|
||||||
/* Write the text of the answer */
|
/* Write the text of the answer */
|
||||||
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI LEFT_TOP\">"
|
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI LEFT_TOP\">"
|
||||||
"<div style=\"text-align:justify;\">"
|
|
||||||
"%s"
|
"%s"
|
||||||
"</div>"
|
|
||||||
"</td>",
|
"</td>",
|
||||||
Answer);
|
Answer);
|
||||||
|
|
||||||
/* Write the text of the feedback */
|
/* Write the text of the feedback */
|
||||||
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI_LIGHT LEFT_TOP\">");
|
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI_LIGHT LEFT_TOP\">");
|
||||||
if (LengthFeedback)
|
if (LengthFeedback)
|
||||||
fprintf (Gbl.F.Out,"<div style=\"text-align:justify;\">"
|
fprintf (Gbl.F.Out,"%s",Feedback);
|
||||||
"%s"
|
|
||||||
"</div>",
|
|
||||||
Feedback);
|
|
||||||
fprintf (Gbl.F.Out,"</td>"
|
fprintf (Gbl.F.Out,"</td>"
|
||||||
"</tr>");
|
"</tr>");
|
||||||
|
|
||||||
|
@ -3055,9 +3050,7 @@ static void Tst_WriteChoiceAnsSeeExam (unsigned NumQst,long QstCod,bool Shuffle)
|
||||||
|
|
||||||
/***** Write the option text *****/
|
/***** Write the option text *****/
|
||||||
fprintf (Gbl.F.Out,"<td class=\"TEST_EXA LEFT_TOP\">"
|
fprintf (Gbl.F.Out,"<td class=\"TEST_EXA LEFT_TOP\">"
|
||||||
"<div style=\"text-align:justify;\">"
|
|
||||||
"%s"
|
"%s"
|
||||||
"</div>"
|
|
||||||
"</td>"
|
"</td>"
|
||||||
"</tr>",
|
"</tr>",
|
||||||
Gbl.Test.Answer.Options[NumOpt].Text);
|
Gbl.Test.Answer.Options[NumOpt].Text);
|
||||||
|
@ -3219,16 +3212,14 @@ static void Tst_WriteChoiceAnsAssessExam (unsigned NumQst,MYSQL_RES *mysql_res,
|
||||||
|
|
||||||
/* Answer text and feedback */
|
/* Answer text and feedback */
|
||||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\">"
|
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\">"
|
||||||
"<div class=\"TEST_EXA\""
|
"<div class=\"TEST_EXA\">"
|
||||||
" style=\"text-align:justify;\">"
|
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
Gbl.Test.Answer.Options[Indexes[NumOpt]].Text);
|
Gbl.Test.Answer.Options[Indexes[NumOpt]].Text);
|
||||||
if (Gbl.Test.Config.FeedbackType == Tst_FEEDBACK_FULL_FEEDBACK)
|
if (Gbl.Test.Config.FeedbackType == Tst_FEEDBACK_FULL_FEEDBACK)
|
||||||
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback)
|
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback)
|
||||||
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback[0])
|
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback[0])
|
||||||
fprintf (Gbl.F.Out,"<div class=\"TEST_EXA_LIGHT\""
|
fprintf (Gbl.F.Out,"<div class=\"TEST_EXA_LIGHT\">"
|
||||||
" style=\"text-align:justify;\">"
|
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback);
|
Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback);
|
||||||
|
@ -3425,15 +3416,14 @@ static void Tst_WriteTextAnsAssessExam (unsigned NumQst,MYSQL_RES *mysql_res,
|
||||||
|
|
||||||
/* Answer text and feedback */
|
/* Answer text and feedback */
|
||||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\">"
|
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\">"
|
||||||
"<div class=\"ANS\" style=\"text-align:justify;\">"
|
"<div class=\"ANS\">"
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
Gbl.Test.Answer.Options[NumOpt].Text);
|
Gbl.Test.Answer.Options[NumOpt].Text);
|
||||||
if (Gbl.Test.Config.FeedbackType == Tst_FEEDBACK_FULL_FEEDBACK)
|
if (Gbl.Test.Config.FeedbackType == Tst_FEEDBACK_FULL_FEEDBACK)
|
||||||
if (Gbl.Test.Answer.Options[NumOpt].Feedback)
|
if (Gbl.Test.Answer.Options[NumOpt].Feedback)
|
||||||
if (Gbl.Test.Answer.Options[NumOpt].Feedback[0])
|
if (Gbl.Test.Answer.Options[NumOpt].Feedback[0])
|
||||||
fprintf (Gbl.F.Out,"<div class=\"TEST_EXA_LIGHT\""
|
fprintf (Gbl.F.Out,"<div class=\"TEST_EXA_LIGHT\">"
|
||||||
" style=\"text-align:justify;\">"
|
|
||||||
"%s"
|
"%s"
|
||||||
"</div>",
|
"</div>",
|
||||||
Gbl.Test.Answer.Options[NumOpt].Feedback);
|
Gbl.Test.Answer.Options[NumOpt].Feedback);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user