mirror of https://github.com/acanas/swad-core.git
Version 16.105
This commit is contained in:
parent
ee42c01666
commit
f7012b9921
|
@ -127,11 +127,13 @@ a:hover /* Default ==> underlined */
|
|||
}
|
||||
.HEAD_ROW_1_GREY
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#383838 0,#383838 26px,#404040 100%); /* Safari */
|
||||
background-image:linear-gradient(#383838 0,#383838 26px,#404040 100%);
|
||||
background-repeat:no-repeat;
|
||||
}
|
||||
.HEAD_ROW_1_BLUE
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#5fa5df 0,#4f90c8 26px,#4f90c8 100%); /* Safari */
|
||||
background-image:linear-gradient(#5fa5df 0,#4f90c8 26px,#4f90c8 100%);
|
||||
background-repeat:no-repeat;
|
||||
}
|
||||
|
@ -244,6 +246,7 @@ a:hover /* Default ==> underlined */
|
|||
}
|
||||
.HEAD_ROW_2_WHITE
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#cfcfce 0,white 40px,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#cfcfce 0,white 40px,white 100%);
|
||||
}
|
||||
.HEAD_ROW_2_GREY
|
||||
|
@ -469,14 +472,17 @@ a:hover /* Default ==> underlined */
|
|||
}
|
||||
.HEAD_ROW_3_GREY
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#404040 0,#404040 54px,white 54px,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#404040 0,#404040 54px,white 54px,white 100%);
|
||||
}
|
||||
.HEAD_ROW_3_BLUE
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#4f90c8 0,#4f90c8 54px,white 54px,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#4f90c8 0,#4f90c8 54px,white 54px,white 100%);
|
||||
}
|
||||
.HEAD_ROW_3_YELLOW
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#201420 0,#201420 54px,white 54px,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#201420 0,#201420 54px,white 54px,white 100%);
|
||||
}
|
||||
@media only screen and (max-width: 480px)
|
||||
|
@ -1228,10 +1234,12 @@ a:hover /* Default ==> underlined */
|
|||
}
|
||||
.BT_SUBMIT:hover
|
||||
{
|
||||
background-image:-webkit-linear-gradient(rgba(0,0,0,0),rgba(0,0,0,0.2)); /* Safari */
|
||||
background-image:linear-gradient(rgba(0,0,0,0),rgba(0,0,0,0.2));
|
||||
}
|
||||
.BT_SUBMIT_INLINE:hover
|
||||
{
|
||||
background-image:-webkit-linear-gradient(rgba(0,0,0,0),rgba(0,0,0,0.2)); /* Safari */
|
||||
background-image:linear-gradient(rgba(0,0,0,0),rgba(0,0,0,0.2));
|
||||
}
|
||||
.BUTTONS_AFTER_ALERT
|
||||
|
@ -1247,6 +1255,7 @@ a:hover /* Default ==> underlined */
|
|||
box-sizing:border-box;
|
||||
margin:0 auto 10px auto;
|
||||
padding:10px;
|
||||
background-image:-webkit-linear-gradient(rgba(238,216,108,0.8) 0%,rgba(248,237,149,0.8) 15%,rgba(250,240,152,0.8) 100%); /* Safari */
|
||||
background-image:linear-gradient(rgba(238,216,108,0.8) 0%,rgba(248,237,149,0.8) 15%,rgba(250,240,152,0.8) 100%);
|
||||
box-shadow:0 8px 10px -5px rgba(125,113,0,0.8);
|
||||
text-align:left;
|
||||
|
@ -1257,6 +1266,7 @@ a:hover /* Default ==> underlined */
|
|||
box-sizing:border-box;
|
||||
margin:0 auto 10px auto;
|
||||
padding:10px;
|
||||
background-image:-webkit-linear-gradient(rgba(238,216,108,0.4) 0%,rgba(248,237,149,0.4) 15%,rgba(250,240,152,0.4) 100%); /* Safari */
|
||||
background-image:linear-gradient(rgba(238,216,108,0.4) 0%,rgba(248,237,149,0.4) 15%,rgba(250,240,152,0.4) 100%);
|
||||
box-shadow:0 8px 10px -5px rgba(125,113,0,0.4);
|
||||
text-align:left;
|
||||
|
@ -1634,11 +1644,13 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
|
||||
.BG_MSG_BLUE
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
}
|
||||
.BG_MSG_GREEN
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
}
|
||||
|
@ -2447,6 +2459,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
.MSG_TIT_REM {color:#AFC4CC; font-size:13pt;}
|
||||
.MSG_TIT_BG
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#4D88A1;
|
||||
|
@ -2454,6 +2467,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
}
|
||||
.MSG_TIT_BG_NEW
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#4D88A1;
|
||||
|
@ -2462,6 +2476,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
}
|
||||
.MSG_TIT_BG_REM
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#f3fcff 0,#f3fcff 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#f3fcff 0,#f3fcff 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#AFC4CC;
|
||||
|
@ -2472,6 +2487,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
.MSG_AUT_NEW {color:#4D88A1; font-size:11pt; font-weight:bold;}
|
||||
.MSG_AUT_BG
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#eaf3f6 0,#eaf3f6 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#4D88A1;
|
||||
|
@ -2479,6 +2495,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
}
|
||||
.MSG_AUT_BG_NEW
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#f5ffd7 0,#f5ffd7 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#4D88A1;
|
||||
|
@ -2487,6 +2504,7 @@ a:hover img.CENTRE_PHOTO_SHOW
|
|||
}
|
||||
.MSG_AUT_BG_REM
|
||||
{
|
||||
background-image:-webkit-linear-gradient(#f3fcff 0,#f3fcff 80%,white 100%); /* Safari */
|
||||
background-image:linear-gradient(#f3fcff 0,#f3fcff 80%,white 100%);
|
||||
background-repeat:no-repeat;
|
||||
color:#AFC4CC;
|
|
@ -148,9 +148,9 @@ static void Acc_ShowFormCheckIfIHaveAccount (const char *Title)
|
|||
Act_FormStart (ActChkUsrAcc);
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"<input type=\"text\" name=\"ID\""
|
||||
" size=\"18\" maxlength=\"%u\" value=\"\" />",
|
||||
" size=\"18\" maxlength=\"%u\" value=\"\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_ID,
|
||||
ID_MAX_LENGTH_USR_ID);
|
||||
Lay_PutConfirmButton (Txt_Check);
|
||||
|
|
|
@ -2205,10 +2205,10 @@ void Ctr_RequestPhoto (void)
|
|||
|
||||
/***** Upload photo *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"file\" name=\"%s\" accept=\"image/*\""
|
||||
" onchange=\"document.getElementById('%s').submit();\" />",
|
||||
" onchange=\"document.getElementById('%s').submit();\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_File_with_the_photo,
|
||||
Fil_NAME_OF_PARAM_FILENAME_ORG,
|
||||
|
|
|
@ -182,18 +182,21 @@
|
|||
// TODO: Fix bug in notification content about files sent to plugins like SWADroid: do not write internal name (for example "comun"). Call instead Brw_GetFileNameToShow or similar.
|
||||
|
||||
// TODO: Draw future dates in attendance, surveys, assignments in blue?
|
||||
// TODO: Fix bug in generate a test: after entering a number of questions with empty tags and type of answers, number of questions is not remembered
|
||||
|
||||
/*****************************************************************************/
|
||||
/****************************** Public constants *****************************/
|
||||
/*****************************************************************************/
|
||||
|
||||
#define Log_PLATFORM_VERSION "SWAD 16.104.3 (2016-12-19)"
|
||||
#define CSS_FILE "swad16.104.css"
|
||||
#define Log_PLATFORM_VERSION "SWAD 16.105 (2016-12-20)"
|
||||
#define CSS_FILE "swad16.105.css"
|
||||
#define JS_FILE "swad16.101.js"
|
||||
|
||||
// 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
|
||||
/*
|
||||
Version 16.105: Dec 20, 2016 Changes in behaviour of labels in forms.
|
||||
Changes in layout for Safari browser. (211237 lines)
|
||||
Version 16.104.3: Dec 19, 2016 Changes in search input fields. (211196 lines)
|
||||
Version 16.104.2: Dec 19, 2016 New links to phones. (211194 lines)
|
||||
Version 16.104.1: Dec 19, 2016 New address element. (211187 lines)
|
||||
|
|
|
@ -301,7 +301,8 @@ void Dat_PutFormStartEndClientLocalDateTimes (time_t TimeUTC[2],
|
|||
"<table class=\"CELLS_PAD_2\">"
|
||||
"<tr>"
|
||||
"<td class=\"LEFT_TOP\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_START_END_TIME[StartEndTime]);
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_START_END_TIME[StartEndTime]);
|
||||
|
||||
/* Date-time */
|
||||
Dat_WriteFormClientLocalDateTimeFromTimeUTC (Id[StartEndTime],
|
||||
|
|
|
@ -93,7 +93,7 @@ void DT_WriteSelectorDegreeTypes (void)
|
|||
DT_GetListDegreeTypes ();
|
||||
|
||||
/* List degree types */
|
||||
fprintf (Gbl.F.Out,"<select name=\"OthDegTypCod\""
|
||||
fprintf (Gbl.F.Out,"<select id=\"OthDegTypCod\" name=\"OthDegTypCod\""
|
||||
" onchange=\"document.getElementById('%s').submit();\">",
|
||||
Gbl.Form.Id);
|
||||
|
||||
|
|
|
@ -1121,7 +1121,8 @@ void Dpt_WriteSelectorDepartment (long InsCod)
|
|||
Dpt_GetListDepartments (InsCod);
|
||||
|
||||
/* List departments */
|
||||
fprintf (Gbl.F.Out,"<select name=\"DptCod\" style=\"width:375px;\""
|
||||
fprintf (Gbl.F.Out,"<select id=\"DptCod\" name=\"DptCod\""
|
||||
" style=\"width:375px;\""
|
||||
" onchange=\"document.getElementById('%s').submit();\">",
|
||||
Gbl.Form.Id);
|
||||
|
||||
|
|
|
@ -299,11 +299,11 @@ void Enr_WriteFormToReqAnotherUsrID (Act_Action_t NextAction)
|
|||
/***** Form to request user's ID, @nickname or email address *****/
|
||||
Act_FormStart (NextAction);
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s RIGHT_MIDDLE\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"text\" name=\"OtherUsrIDNickOrEMail\""
|
||||
" size=\"18\" maxlength=\"%u\""
|
||||
" required=\"required\" />",
|
||||
" required=\"required\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_nick_email_or_ID,
|
||||
Usr_MAX_BYTES_USR_LOGIN);
|
||||
|
@ -2109,7 +2109,7 @@ static void Enr_ShowEnrollmentRequestsGivenRoles (unsigned RolesSelected)
|
|||
/* Scope (whole platform, current centre, current degree or current course) */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"ScopeEnr\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
|
|
|
@ -8061,10 +8061,10 @@ static void Brw_PutFormToCreateAFolder (const char *FileNameToShow)
|
|||
/***** Folder *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"<input type=\"text\" name=\"NewFolderName\""
|
||||
" size=\"30\" maxlength=\"40\" value=\"\""
|
||||
" required=\"required\" />",
|
||||
" required=\"required\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Folder);
|
||||
|
||||
/* Button to send and end frame *****/
|
||||
|
@ -8304,12 +8304,13 @@ static void Brw_PutFormToCreateALink (const char *FileNameToShow)
|
|||
fprintf (Gbl.F.Out,"<table>"
|
||||
"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"<label for=\"NewLinkURL\" class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<input type=\"url\" name=\"NewLinkURL\""
|
||||
"<input type=\"url\""
|
||||
" id=\"NewLinkURL\" name=\"NewLinkURL\""
|
||||
" size=\"40\" maxlength=\"%u\" value=\"\""
|
||||
" required=\"required\" />"
|
||||
"</td>"
|
||||
|
@ -8320,10 +8321,13 @@ static void Brw_PutFormToCreateALink (const char *FileNameToShow)
|
|||
/***** Link name *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s (%s): </label>"
|
||||
"<label for=\"NewLinkName\" class=\"%s\">"
|
||||
"%s (%s): "
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<input type=\"text\" name=\"NewLinkName\""
|
||||
"<input type=\"text\""
|
||||
" id=\"NewLinkName\" name=\"NewLinkName\""
|
||||
" size=\"40\" maxlength=\"100\" value=\"\" />"
|
||||
"</td>"
|
||||
"</tr>"
|
||||
|
|
|
@ -113,7 +113,7 @@ void Ind_ReqIndicatorsCourses (void)
|
|||
/* Scope */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"ScopeInd\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
|
@ -124,7 +124,7 @@ void Ind_ReqIndicatorsCourses (void)
|
|||
/* Compute stats for a type of degree */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"OthDegTypCod\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"DAT LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Types_of_degree);
|
||||
|
@ -138,7 +138,7 @@ void Ind_ReqIndicatorsCourses (void)
|
|||
/* Compute stats for courses with teachers belonging to any department or to a particular departament? */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"DptCod\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Department);
|
||||
|
@ -159,11 +159,12 @@ void Ind_ReqIndicatorsCourses (void)
|
|||
|
||||
/* Selection of the number of indicators */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<td class=\"RIGHT_TOP %s\">"
|
||||
"%s:"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_TOP\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_No_of_indicators);
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_No_of_indicators);
|
||||
Ind_ShowNumCoursesWithIndicators (NumCrssWithIndicatorYes,NumCrss,true);
|
||||
fprintf (Gbl.F.Out,"</td>"
|
||||
"</tr>");
|
||||
|
@ -614,8 +615,10 @@ static void Ind_ShowNumCoursesWithIndicators (unsigned NumCrssWithIndicatorYes[1
|
|||
if (PutForm)
|
||||
{
|
||||
fprintf (Gbl.F.Out,"<td class=\"%s\">"
|
||||
"<input type=\"checkbox\" name=\"Indicators\" value=\"%u\"",
|
||||
Class,Ind);
|
||||
"<input type=\"checkbox\""
|
||||
" id=\"Indicators%u\" name=\"Indicators\""
|
||||
" value=\"%u\"",
|
||||
Class,Ind,Ind);
|
||||
if (Gbl.Stat.IndicatorsSelected[Ind])
|
||||
fprintf (Gbl.F.Out," checked=\"checked\"");
|
||||
fprintf (Gbl.F.Out," onchange=\"document.getElementById('%s').submit();\" />"
|
||||
|
@ -623,7 +626,7 @@ static void Ind_ShowNumCoursesWithIndicators (unsigned NumCrssWithIndicatorYes[1
|
|||
Gbl.Form.Id);
|
||||
}
|
||||
fprintf (Gbl.F.Out,"<td class=\"%s\">"
|
||||
"%u"
|
||||
"<label for=\"Indicators%u\">%u</label>"
|
||||
"</td>"
|
||||
"<td class=\"%s\">"
|
||||
"%u"
|
||||
|
@ -633,7 +636,7 @@ static void Ind_ShowNumCoursesWithIndicators (unsigned NumCrssWithIndicatorYes[1
|
|||
"</td>"
|
||||
"</tr>",
|
||||
Class,
|
||||
Ind,
|
||||
Ind,Ind,
|
||||
Class,
|
||||
NumCrssWithIndicatorYes[Ind],
|
||||
Class,
|
||||
|
|
|
@ -292,10 +292,10 @@ void Log_RequestLogo (Sco_Scope_t Scope)
|
|||
|
||||
/***** Upload logo *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"file\" name=\"%s\""
|
||||
" onchange=\"document.getElementById('%s').submit();\" />",
|
||||
" onchange=\"document.getElementById('%s').submit();\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_File_with_the_logo,
|
||||
Fil_NAME_OF_PARAM_FILENAME_ORG,
|
||||
|
|
|
@ -2571,10 +2571,10 @@ void Msg_ShowFormToFilterMsgs (void)
|
|||
/***** Filter authors/recipients *****/
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"search\" name=\"FilterFromTo\""
|
||||
" size=\"20\" maxlength=\"%u\" value=\"%s\" />"
|
||||
"</label>"
|
||||
"</td>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
TxtFromTo[Gbl.Msg.TypeOfMessages],
|
||||
|
@ -2583,10 +2583,10 @@ void Msg_ShowFormToFilterMsgs (void)
|
|||
/***** Filter message content *****/
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"search\" name=\"FilterContent\""
|
||||
" size=\"20\" maxlength=\"%u\" value=\"%s\" />"
|
||||
"</label>"
|
||||
"</td>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_MSG_Message,
|
||||
|
@ -2934,10 +2934,8 @@ static void Msg_ShowASentOrReceivedMessage (long MsgNum,long MsgCod)
|
|||
"</td>");
|
||||
|
||||
/***** Write "From:" *****/
|
||||
fprintf (Gbl.F.Out,"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"MSG_TIT\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
fprintf (Gbl.F.Out,"<td class=\"RIGHT_TOP MSG_TIT\">"
|
||||
"%s: "
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_TOP\">",
|
||||
Txt_MSG_From);
|
||||
|
@ -2947,10 +2945,8 @@ static void Msg_ShowASentOrReceivedMessage (long MsgNum,long MsgCod)
|
|||
|
||||
/***** Write "To:" *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"MSG_TIT\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"<td class=\"RIGHT_TOP MSG_TIT\">"
|
||||
"%s: "
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_TOP\">",
|
||||
Txt_MSG_To);
|
||||
|
@ -2960,10 +2956,8 @@ static void Msg_ShowASentOrReceivedMessage (long MsgNum,long MsgCod)
|
|||
|
||||
/***** Write "Message:" *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"MSG_TIT\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"<td class=\"RIGHT_TOP MSG_TIT\">"
|
||||
"%s: "
|
||||
"</td>",
|
||||
Txt_MSG_Message);
|
||||
|
||||
|
|
|
@ -252,10 +252,10 @@ void Pwd_ShowFormSendNewPwd (void)
|
|||
|
||||
/***** User's ID/nickname *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"text\" name=\"UsrId\""
|
||||
" size=\"8\" maxlength=\"%u\" value=\"%s\" />",
|
||||
" size=\"8\" maxlength=\"%u\" value=\"%s\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_nick_email_or_ID,
|
||||
Usr_MAX_LENGTH_USR_LOGIN,Gbl.Usrs.Me.UsrIdLogin);
|
||||
|
||||
|
|
|
@ -333,10 +333,10 @@ static void Pho_ReqPhoto (const struct UsrData *UsrDat,const char *PhotoURL)
|
|||
|
||||
/***** Form to upload photo *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"file\" name=\"%s\" accept=\"image/*\""
|
||||
" onchange=\"document.getElementById('%s').submit();\" />",
|
||||
" onchange=\"document.getElementById('%s').submit();\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_File_with_the_photo,
|
||||
Fil_NAME_OF_PARAM_FILENAME_ORG,
|
||||
|
|
|
@ -174,10 +174,10 @@ static void Prf_RequestUserProfileWithDefaultNickname (const char *DefaultNickna
|
|||
|
||||
/***** Form to request user's @nickname *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"text\" name=\"usr\""
|
||||
" size=\"18\" maxlength=\"%u\" value=\"@%s\" />",
|
||||
" size=\"18\" maxlength=\"%u\" value=\"@%s\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_Nickname,
|
||||
Nck_MAX_BYTES_NICKNAME_WITH_ARROBA,
|
||||
|
|
|
@ -1409,10 +1409,8 @@ static void Rec_ShowLinkToPrintPreviewOfRecords (void)
|
|||
Act_LinkFormSubmit (Txt_Print,The_ClassFormBold[Gbl.Prefs.Theme],NULL);
|
||||
Lay_PutIconWithText ("print64x64.png",Txt_Print,Txt_Print);
|
||||
fprintf (Gbl.F.Out,"</a>"
|
||||
"<span class=\"%s\">(</span>"
|
||||
"<select name=\"RecsPerPag\">",
|
||||
"<label class=\"%s\">(<select name=\"RecsPerPag\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme]);
|
||||
|
||||
for (i = 1;
|
||||
i <= 10;
|
||||
i++)
|
||||
|
@ -1422,9 +1420,8 @@ static void Rec_ShowLinkToPrintPreviewOfRecords (void)
|
|||
fprintf (Gbl.F.Out," selected=\"selected\"");
|
||||
fprintf (Gbl.F.Out,">%u</option>",i);
|
||||
}
|
||||
fprintf (Gbl.F.Out,"</select>"
|
||||
"<span class=\"%s\"> %s)</span>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_record_cards_per_page);
|
||||
fprintf (Gbl.F.Out,"</select> %s)</label>",
|
||||
Txt_record_cards_per_page);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
|
@ -356,7 +356,8 @@ void Rol_WriteSelectorRoles (unsigned RolesAllowed,unsigned RolesSelected,
|
|||
Role++)
|
||||
if ((RolesAllowed & (1 << Role)))
|
||||
{
|
||||
fprintf (Gbl.F.Out,"<input type=\"checkbox\" name=\"Role\" value=\"%u\"",
|
||||
fprintf (Gbl.F.Out,"<label>"
|
||||
"<input type=\"checkbox\" name=\"Role\" value=\"%u\"",
|
||||
(unsigned) Role);
|
||||
|
||||
if ((RolesSelected & (1 << Role)))
|
||||
|
@ -369,7 +370,8 @@ void Rol_WriteSelectorRoles (unsigned RolesAllowed,unsigned RolesSelected,
|
|||
fprintf (Gbl.F.Out," onchange=\"document.getElementById('%s').submit();\"",
|
||||
Gbl.Form.Id);
|
||||
|
||||
fprintf (Gbl.F.Out," />%s<br />",
|
||||
fprintf (Gbl.F.Out," />%s</label>"
|
||||
"<br />",
|
||||
Txt_ROLES_PLURAL_abc[Role][Usr_SEX_UNKNOWN]);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -84,7 +84,7 @@ void Sco_PutSelectorScope (const char *ParamName,bool SendOnChange)
|
|||
Sco_Scope_t Scope;
|
||||
bool WriteScope;
|
||||
|
||||
fprintf (Gbl.F.Out,"<select name=\"%s\"",ParamName);
|
||||
fprintf (Gbl.F.Out,"<select id=\"%s\" name=\"%s\"",ParamName,ParamName);
|
||||
if (SendOnChange)
|
||||
fprintf (Gbl.F.Out," onchange=\"document.getElementById('%s').submit();\"",
|
||||
Gbl.Form.Id);
|
||||
|
|
|
@ -237,7 +237,7 @@ static void Sch_PutFormToSearchWithWhatToSearchAndScope (Act_Action_t Action,Sco
|
|||
/***** Scope (whole platform, current country, current institution,
|
||||
current centre, current degree or current course) *****/
|
||||
fprintf (Gbl.F.Out,"<div class=\"CENTER_MIDDLE\">"
|
||||
"<label class=\"%s\">%s: </label>",
|
||||
"<label class=\"%s\">%s: ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
Gbl.Scope.Allowed = 1 << Sco_SCOPE_SYS |
|
||||
1 << Sco_SCOPE_CTY |
|
||||
|
@ -248,7 +248,8 @@ static void Sch_PutFormToSearchWithWhatToSearchAndScope (Act_Action_t Action,Sco
|
|||
Gbl.Scope.Default = DefaultScope;
|
||||
Sco_GetScope ("ScopeSch");
|
||||
Sco_PutSelectorScope ("ScopeSch",false);
|
||||
fprintf (Gbl.F.Out,"</div>");
|
||||
fprintf (Gbl.F.Out,"</label>"
|
||||
"</div>");
|
||||
|
||||
/***** String to find *****/
|
||||
Sch_PutInputStringToSearch (NULL);
|
||||
|
|
|
@ -457,8 +457,7 @@ void Sta_AskShowCrsHits (void)
|
|||
fprintf (Gbl.F.Out,"<table class=\"CELLS_PAD_2\""
|
||||
" style=\"margin:0 auto;\">"
|
||||
"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<td class=\"RIGHT_TOP %s\">%s:"
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"%s LEFT_TOP\">"
|
||||
"<table>",
|
||||
|
@ -478,9 +477,7 @@ void Sta_AskShowCrsHits (void)
|
|||
|
||||
/***** Option a) Listing of clicks distributed by some metric *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"RIGHT_TOP %s\">%s:</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_TOP\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Show);
|
||||
|
||||
|
@ -498,7 +495,7 @@ void Sta_AskShowCrsHits (void)
|
|||
/* Selection of count type (number of pages generated, accesses per user, etc.) */
|
||||
Sta_WriteSelectorCountType ();
|
||||
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\"> %s </label>"
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\"> %s "
|
||||
"<select id=\"GroupedBy\" name=\"GroupedBy\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_distributed_by);
|
||||
for (ClicksGroupedBy = Sta_CLICKS_CRS_PER_USR;
|
||||
|
@ -512,7 +509,7 @@ void Sta_AskShowCrsHits (void)
|
|||
fprintf (Gbl.F.Out,">%s",Txt_STAT_CLICKS_GROUPED_BY[ClicksGroupedBy]);
|
||||
}
|
||||
fprintf (Gbl.F.Out,"</select>"
|
||||
"<br />");
|
||||
"</label><br />");
|
||||
|
||||
/***** Option b) Listing of detailed clicks to this course *****/
|
||||
fprintf (Gbl.F.Out,"<input type=\"radio\" name=\"GroupedOrDetailed\" value=\"%u\"",
|
||||
|
@ -619,10 +616,10 @@ void Sta_AskShowGblHits (void)
|
|||
/***** Users' roles whose accesses we want to see *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"Role\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_MIDDLE\">"
|
||||
"<select name=\"Role\">",
|
||||
"<select id=\"Role\" name=\"Role\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Users);
|
||||
for (RoleStat = (Sta_Role_t) 0;
|
||||
RoleStat < Sta_NUM_ROLES_STAT;
|
||||
|
@ -643,7 +640,7 @@ void Sta_AskShowGblHits (void)
|
|||
/***** Clicks made from anywhere, current centre, current degree or current course *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"ScopeSta\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
|
@ -662,14 +659,14 @@ void Sta_AskShowGblHits (void)
|
|||
/***** Count type for the statistic *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"CountType\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_TOP\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Show);
|
||||
Sta_WriteSelectorCountType ();
|
||||
|
||||
/***** Type of statistic *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\"> %s </label>",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\"> %s ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_distributed_by);
|
||||
|
||||
if (Gbl.Stat.ClicksGroupedBy < Sta_CLICKS_GBL_PER_DAYS ||
|
||||
|
@ -688,6 +685,7 @@ void Sta_AskShowGblHits (void)
|
|||
fprintf (Gbl.F.Out,">%s",Txt_STAT_CLICKS_GROUPED_BY[ClicksGroupedBy]);
|
||||
}
|
||||
fprintf (Gbl.F.Out,"</select>"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>"
|
||||
"</table>");
|
||||
|
@ -743,10 +741,10 @@ static void Sta_WriteSelectorAction (void)
|
|||
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"StatAct\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td colspan=\"2\" class=\"LEFT_TOP\">"
|
||||
"<select name=\"StatAct\" id=\"StatAct\""
|
||||
"<select id=\"StatAct\" name=\"StatAct\""
|
||||
" style=\"width:375px;\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Action);
|
||||
for (Action = (Act_Action_t) 0;
|
||||
|
|
|
@ -1861,7 +1861,7 @@ void Svy_RequestCreatOrEditSvy (void)
|
|||
/***** Scope of the survey *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"ScopeSvy\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
|
@ -1875,10 +1875,10 @@ void Svy_RequestCreatOrEditSvy (void)
|
|||
/***** Survey title *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"Title\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<input type=\"text\" name=\"Title\""
|
||||
"<input type=\"text\" id=\"Title\" name=\"Title\""
|
||||
" size=\"45\" maxlength=\"%u\" value=\"%s\""
|
||||
" required=\"required\" />"
|
||||
"</td>"
|
||||
|
@ -1893,10 +1893,11 @@ void Svy_RequestCreatOrEditSvy (void)
|
|||
/***** Survey text *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<label for=\"Txt\" class=\"%s\">%s:</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_TOP\">"
|
||||
"<textarea name=\"Txt\" cols=\"60\" rows=\"10\">",
|
||||
"<textarea id=\"Txt\" name=\"Txt\""
|
||||
" cols=\"60\" rows=\"10\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_Description);
|
||||
if (!ItsANewSurvey)
|
||||
|
@ -1907,8 +1908,7 @@ void Svy_RequestCreatOrEditSvy (void)
|
|||
|
||||
/***** Users' roles who can answer the survey *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">%s:</label>"
|
||||
"<td class=\"RIGHT_TOP %s\">%s:"
|
||||
"</td>"
|
||||
"<td class=\"DAT LEFT_MIDDLE\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
|
@ -3292,7 +3292,7 @@ static void Svy_ListSvyQuestions (struct Survey *Svy,struct SurveyQuestion *SvyQ
|
|||
Txt_SURVEY_STR_ANSWER_TYPES[SvyQst->AnswerType]);
|
||||
|
||||
/* Write the stem (row[3]) and the answers of this question */
|
||||
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI LEFT_TOP COLOR%u\">",
|
||||
fprintf (Gbl.F.Out,"<td class=\"DAT LEFT_TOP COLOR%u\">",
|
||||
Gbl.RowEvenOdd);
|
||||
Svy_WriteQstStem (row[3]);
|
||||
Svy_WriteAnswersOfAQst (Svy,SvyQst,PutFormAnswerSurvey);
|
||||
|
@ -3386,7 +3386,8 @@ static void Svy_WriteQstStem (const char *Stem)
|
|||
|
||||
static void Svy_WriteAnswersOfAQst (struct Survey *Svy,struct SurveyQuestion *SvyQst,bool PutFormAnswerSurvey)
|
||||
{
|
||||
unsigned NumAns,NumAnswers;
|
||||
unsigned NumAnswers;
|
||||
unsigned NumAns;
|
||||
MYSQL_RES *mysql_res;
|
||||
MYSQL_ROW row;
|
||||
unsigned NumUsrsThisAnswer;
|
||||
|
@ -3431,20 +3432,24 @@ static void Svy_WriteAnswersOfAQst (struct Survey *Svy,struct SurveyQuestion *Sv
|
|||
(unsigned) SvyQst->QstCod,NumAnswers);
|
||||
else // SvyQst->AnswerType == Svy_ANS_MULTIPLE_CHOICE
|
||||
fprintf (Gbl.F.Out,"checkbox\"");
|
||||
fprintf (Gbl.F.Out," name=\"Ans%010u\" value=\"%u\" />"
|
||||
fprintf (Gbl.F.Out," id=\"Ans%010u_%010u\" name=\"Ans%010u\""
|
||||
" value=\"%u\" />"
|
||||
"</td>",
|
||||
(unsigned) SvyQst->QstCod,NumAns);
|
||||
(unsigned) SvyQst->QstCod,NumAns,(unsigned) SvyQst->QstCod,
|
||||
NumAns);
|
||||
}
|
||||
|
||||
/* Write the number of option */
|
||||
fprintf (Gbl.F.Out,"<td class=\"DAT LEFT_TOP\" style=\"width:50px;\">"
|
||||
"%u)"
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\" style=\"width:50px;\">"
|
||||
"<label for=\"Ans%010u_%010u\" class=\"DAT\">%u)</label>"
|
||||
"</td>",
|
||||
NumAns + 1);
|
||||
(unsigned) SvyQst->QstCod,NumAns,NumAns + 1);
|
||||
|
||||
/* Write the text of the answer */
|
||||
fprintf (Gbl.F.Out,"<td class=\"TEST_EDI LEFT_TOP\">%s</td>",
|
||||
Answer);
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_TOP\">"
|
||||
"<label for=\"Ans%010u_%010u\" class=\"DAT\">%s</label>"
|
||||
"</td>",
|
||||
(unsigned) SvyQst->QstCod,NumAns,Answer);
|
||||
|
||||
/* Show stats of this answer */
|
||||
if (Svy->Status.ICanViewResults)
|
||||
|
|
92
swad_test.c
92
swad_test.c
|
@ -323,14 +323,17 @@ void Tst_ShowFormAskTst (void)
|
|||
/***** Number of questions to generate ****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"<label for=\"NumQst\" class=\"%s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<input type=\"text\" name=\"NumQst\""
|
||||
" size=\"3\" maxlength=\"3\" value=\"%u\"",
|
||||
"<input type=\"number\""
|
||||
" id=\"NumQst\" name=\"NumQst\""
|
||||
" min=\"%u\" max=\"%u\" value=\"%u\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_No_of_questions,
|
||||
Gbl.Test.Config.Min,
|
||||
Gbl.Test.Config.Max,
|
||||
Gbl.Test.Config.Def);
|
||||
if (Gbl.Test.Config.Min == Gbl.Test.Config.Max)
|
||||
fprintf (Gbl.F.Out," disabled=\"disabled\"");
|
||||
|
@ -1068,44 +1071,47 @@ static void Tst_PutFormToEditQstImage (struct Image *Image,int NumImgInForm,
|
|||
fprintf (Gbl.F.Out,"<div class=\"TEST_FORM_EDIT_IMG\">");
|
||||
|
||||
/***** Choice 1: No image *****/
|
||||
fprintf (Gbl.F.Out,"<input type=\"radio\" name=\"%s\" value=\"%u\"",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"<input type=\"radio\" name=\"%s\" value=\"%u\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
ParamUploadImg.Action,Img_ACTION_NO_IMAGE);
|
||||
if (OptionsDisabled)
|
||||
fprintf (Gbl.F.Out," disabled=\"disabled\"");
|
||||
fprintf (Gbl.F.Out," />"
|
||||
"<label class=\"%s\">"
|
||||
"%s"
|
||||
"</label>"
|
||||
"<br />",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_No_image);
|
||||
|
||||
/***** Choice 2: Current image *****/
|
||||
fprintf (Gbl.F.Out,"<input type=\"radio\" name=\"%s\" value=\"%u\" checked=\"checked\"",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"<input type=\"radio\" name=\"%s\" value=\"%u\""
|
||||
" checked=\"checked\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
ParamUploadImg.Action,Img_ACTION_KEEP_IMAGE);
|
||||
if (OptionsDisabled)
|
||||
fprintf (Gbl.F.Out," disabled=\"disabled\"");
|
||||
fprintf (Gbl.F.Out," />"
|
||||
"<label class=\"%s\">"
|
||||
"%s"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_Current_image);
|
||||
Img_ShowImage (Image,ClassContainer,ClassImg);
|
||||
|
||||
/***** Choice 3: Change/new image *****/
|
||||
UniqueId++;
|
||||
fprintf (Gbl.F.Out,"<input type=\"radio\" id=\"chg_img_%u\" name=\"%s\""
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"<input type=\"radio\" id=\"chg_img_%u\" name=\"%s\""
|
||||
" value=\"%u\"",
|
||||
UniqueId,ParamUploadImg.Action,Img_ACTION_CHANGE_IMAGE); // Replace existing image by new image
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
UniqueId,ParamUploadImg.Action,
|
||||
Img_ACTION_CHANGE_IMAGE); // Replace existing image by new image
|
||||
if (OptionsDisabled)
|
||||
fprintf (Gbl.F.Out," disabled=\"disabled\"");
|
||||
fprintf (Gbl.F.Out," />"
|
||||
"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"<input type=\"file\" name=\"%s\" accept=\"image/*\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Change_image,
|
||||
Txt_Change_image,
|
||||
ParamUploadImg.File);
|
||||
if (OptionsDisabled)
|
||||
fprintf (Gbl.F.Out," disabled=\"disabled\"");
|
||||
|
@ -1615,10 +1621,8 @@ static void Tst_ShowFormSelTags (unsigned long NumRows,MYSQL_RES *mysql_res,
|
|||
|
||||
/***** Label *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<td class=\"RIGHT_TOP %s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Tags);
|
||||
|
||||
|
@ -1631,13 +1635,15 @@ static void Tst_ShowFormSelTags (unsigned long NumRows,MYSQL_RES *mysql_res,
|
|||
"<tr>");
|
||||
if (!ShowOnlyEnabledTags)
|
||||
fprintf (Gbl.F.Out,"<td></td>");
|
||||
fprintf (Gbl.F.Out,"<td class=\"%s LEFT_MIDDLE\">"
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"<input type=\"checkbox\" name=\"AllTags\" value=\"Y\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme]);
|
||||
if (Gbl.Test.Tags.All)
|
||||
fprintf (Gbl.F.Out," checked=\"checked\"");
|
||||
fprintf (Gbl.F.Out," onclick=\"togglecheckChildren(this,'ChkTag');\" />"
|
||||
" %s"
|
||||
" %s"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>",
|
||||
Txt_All_tags);
|
||||
|
@ -1666,7 +1672,8 @@ static void Tst_ShowFormSelTags (unsigned long NumRows,MYSQL_RES *mysql_res,
|
|||
fprintf (Gbl.F.Out,"\" class=\"ICO20x20\" />"
|
||||
"</td>");
|
||||
}
|
||||
fprintf (Gbl.F.Out,"<td class=\"DAT LEFT_MIDDLE\">"
|
||||
fprintf (Gbl.F.Out,"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"DAT\">"
|
||||
"<input type=\"checkbox\" name=\"ChkTag\" value=\"%s\"",
|
||||
row[1]);
|
||||
if (Gbl.Test.Tags.List)
|
||||
|
@ -1680,7 +1687,8 @@ static void Tst_ShowFormSelTags (unsigned long NumRows,MYSQL_RES *mysql_res,
|
|||
}
|
||||
}
|
||||
fprintf (Gbl.F.Out," onclick=\"checkParent(this,'AllTags');\" />"
|
||||
" %s"
|
||||
" %s"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>",
|
||||
row[1]);
|
||||
|
@ -2248,10 +2256,8 @@ static void Tst_ShowFormAnswerTypes (unsigned NumCols)
|
|||
|
||||
/***** Label *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<td class=\"RIGHT_TOP %s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Types_of_answers);
|
||||
|
||||
|
@ -2262,13 +2268,15 @@ static void Tst_ShowFormAnswerTypes (unsigned NumCols)
|
|||
fprintf (Gbl.F.Out," class=\"LEFT_TOP\">"
|
||||
"<table class=\"CELLS_PAD_2\">"
|
||||
"<tr>"
|
||||
"<td class=\"%s LEFT_MIDDLE\">"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"%s\">"
|
||||
"<input type=\"checkbox\" name=\"AllAnsTypes\" value=\"Y\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme]);
|
||||
if (Gbl.Test.AllAnsTypes)
|
||||
fprintf (Gbl.F.Out," checked=\"checked\"");
|
||||
fprintf (Gbl.F.Out," onclick=\"togglecheckChildren(this,'AnswerType');\" />"
|
||||
" %s"
|
||||
" %s"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>",
|
||||
Txt_All_types_of_answers);
|
||||
|
@ -2279,7 +2287,8 @@ static void Tst_ShowFormAnswerTypes (unsigned NumCols)
|
|||
AnsType++)
|
||||
{
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"DAT LEFT_MIDDLE\">"
|
||||
"<td class=\"LEFT_MIDDLE\">"
|
||||
"<label class=\"DAT\">"
|
||||
"<input type=\"checkbox\" name=\"AnswerType\" value=\"%u\"",
|
||||
(unsigned) AnsType);
|
||||
Ptr = Gbl.Test.ListAnsTypes;
|
||||
|
@ -2290,7 +2299,8 @@ static void Tst_ShowFormAnswerTypes (unsigned NumCols)
|
|||
fprintf (Gbl.F.Out," checked=\"checked\"");
|
||||
}
|
||||
fprintf (Gbl.F.Out," onclick=\"checkParent(this,'AllAnsTypes');\" />"
|
||||
" %s"
|
||||
" %s"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>",
|
||||
Txt_TST_STR_ANSWER_TYPES[AnsType]);
|
||||
|
@ -4495,10 +4505,8 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
|
||||
/***** Write the tags *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<td class=\"RIGHT_TOP %s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_TOP\">"
|
||||
"<table class=\"CELLS_PAD_2\">",
|
||||
|
@ -4560,13 +4568,13 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
/***** Stem and image *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<label for=\"Stem\" class=\"%s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"LEFT_TOP\">"
|
||||
"<textarea name=\"Stem\" class=\"STEM\" rows=\"5\""
|
||||
" required=\"required\">"
|
||||
"<textarea id=\"Stem\" name=\"Stem\""
|
||||
" class=\"STEM\" rows=\"5\" required=\"required\">"
|
||||
"%s"
|
||||
"</textarea><br />",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
|
@ -4580,8 +4588,7 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
|
||||
/***** Feedback *****/
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s (%s):"
|
||||
"</label><br />"
|
||||
"%s (%s):<br />"
|
||||
"<textarea name=\"Feedback\" class=\"STEM\" rows=\"2\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_Feedback,Txt_optional);
|
||||
|
@ -4589,15 +4596,14 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
if (Feedback[0])
|
||||
fprintf (Gbl.F.Out,"%s",Feedback);
|
||||
fprintf (Gbl.F.Out,"</textarea>"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"</tr>");
|
||||
|
||||
/***** Type of answer *****/
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<td class=\"RIGHT_TOP %s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"%s LEFT_TOP\">",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
|
@ -4607,12 +4613,14 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
AnsType < Tst_NUM_ANS_TYPES;
|
||||
AnsType++)
|
||||
{
|
||||
fprintf (Gbl.F.Out,"<input type=\"radio\" name=\"AnswerType\" value=\"%u\"",
|
||||
fprintf (Gbl.F.Out,"<label>"
|
||||
"<input type=\"radio\" name=\"AnswerType\" value=\"%u\"",
|
||||
(unsigned) AnsType);
|
||||
if (AnsType == Gbl.Test.AnswerType)
|
||||
fprintf (Gbl.F.Out," checked=\"checked\"");
|
||||
fprintf (Gbl.F.Out," onclick=\"enableDisableAns(this.form);\" />"
|
||||
"%s <br />",
|
||||
"%s "
|
||||
"</label><br />",
|
||||
Txt_TST_STR_ANSWER_TYPES[AnsType]);
|
||||
}
|
||||
fprintf (Gbl.F.Out,"</td>"
|
||||
|
@ -4622,13 +4630,13 @@ static void Tst_PutFormEditOneQst (char *Stem,char *Feedback)
|
|||
/* Integer answer */
|
||||
fprintf (Gbl.F.Out,"<tr>"
|
||||
"<td class=\"RIGHT_TOP\">"
|
||||
"<label class=\"%s\">"
|
||||
"<label for=\"AnsInt\" class=\"%s\">"
|
||||
"%s:"
|
||||
"</label>"
|
||||
"</td>"
|
||||
"<td class=\"%s LEFT_TOP\">"
|
||||
"%s: "
|
||||
"<input type=\"text\" name=\"AnsInt\""
|
||||
"<input type=\"text\" id=\"AnsInt\" name=\"AnsInt\""
|
||||
" size=\"11\" maxlength=\"11\" value=\"%ld\"",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Answers,
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Integer_number,
|
||||
|
|
|
@ -143,10 +143,10 @@ void TsI_ShowFormImportQstsFromXML (void)
|
|||
/***** Write a form to import questions *****/
|
||||
Act_FormStart (ActImpTstQst);
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"%s: "
|
||||
"</label>"
|
||||
"%s: "
|
||||
"<input type=\"file\" name=\"%s\" accept=\".xml\""
|
||||
" onchange=\"document.getElementById('%s').submit();\" />",
|
||||
" onchange=\"document.getElementById('%s').submit();\" />"
|
||||
"</label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],
|
||||
Txt_XML_file,
|
||||
Fil_NAME_OF_PARAM_FILENAME_ORG,
|
||||
|
|
27
swad_user.c
27
swad_user.c
|
@ -6447,12 +6447,13 @@ void Usr_ListDataAdms (void)
|
|||
NULL,Hlp_USERS_Administrators);
|
||||
|
||||
/***** Form to select range of administrators *****/
|
||||
fprintf (Gbl.F.Out,"<div class=\"CENTER_MIDDLE\">"
|
||||
"<label class=\"%s\">%s: </label>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
fprintf (Gbl.F.Out,"<div class=\"CENTER_MIDDLE\">");
|
||||
Act_FormStart (ActLstOth);
|
||||
Sco_PutSelectorScope ("ScopeUsr",true);
|
||||
Usr_PutParamListWithPhotos ();
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
Sco_PutSelectorScope ("ScopeUsr",true);
|
||||
fprintf (Gbl.F.Out,"</label>");
|
||||
Act_FormEnd ();
|
||||
fprintf (Gbl.F.Out,"</div>");
|
||||
|
||||
|
@ -6935,9 +6936,10 @@ void Usr_SeeGuests (void)
|
|||
Usr_PutParamUsrListType (Gbl.Usrs.Me.ListType);
|
||||
Usr_PutParamColsClassPhoto ();
|
||||
Usr_PutParamListWithPhotos ();
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: </label>",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
Sco_PutSelectorScope ("ScopeUsr",true);
|
||||
fprintf (Gbl.F.Out,"</label>");
|
||||
Act_FormEnd ();
|
||||
fprintf (Gbl.F.Out,"</div>");
|
||||
break;
|
||||
|
@ -7090,9 +7092,10 @@ void Usr_SeeStudents (void)
|
|||
Usr_PutParamUsrListType (Gbl.Usrs.Me.ListType);
|
||||
Usr_PutParamColsClassPhoto ();
|
||||
Usr_PutParamListWithPhotos ();
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: </label>",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
Sco_PutSelectorScope ("ScopeUsr",true);
|
||||
fprintf (Gbl.F.Out,"</label>");
|
||||
Act_FormEnd ();
|
||||
fprintf (Gbl.F.Out,"</div>");
|
||||
break;
|
||||
|
@ -7248,9 +7251,10 @@ void Usr_SeeTeachers (void)
|
|||
Usr_PutParamUsrListType (Gbl.Usrs.Me.ListType);
|
||||
Usr_PutParamColsClassPhoto ();
|
||||
Usr_PutParamListWithPhotos ();
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: </label>",
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">%s: ",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_Scope);
|
||||
Sco_PutSelectorScope ("ScopeUsr",true);
|
||||
fprintf (Gbl.F.Out,"</label>");
|
||||
Act_FormEnd ();
|
||||
fprintf (Gbl.F.Out,"</div>");
|
||||
|
||||
|
@ -7784,9 +7788,10 @@ void Usr_PutSelectorNumColsClassPhoto (void)
|
|||
unsigned Cols;
|
||||
|
||||
/***** Start selector *****/
|
||||
fprintf (Gbl.F.Out,"<select name=\"ColsClassPhoto\""
|
||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||
"<select name=\"ColsClassPhoto\""
|
||||
" onchange=\"document.getElementById('%s').submit();\">",
|
||||
Gbl.Form.Id);
|
||||
The_ClassForm[Gbl.Prefs.Theme],Gbl.Form.Id);
|
||||
|
||||
/***** Put a row in selector for every number from 1 to Usr_CLASS_PHOTO_COLS_MAX *****/
|
||||
for (Cols = 1;
|
||||
|
@ -7801,8 +7806,8 @@ void Usr_PutSelectorNumColsClassPhoto (void)
|
|||
|
||||
/***** End selector *****/
|
||||
fprintf (Gbl.F.Out,"</select>"
|
||||
"<span class=\"%s\">%s</span>",
|
||||
The_ClassForm[Gbl.Prefs.Theme],Txt_columns);
|
||||
"%s</label>",
|
||||
Txt_columns);
|
||||
}
|
||||
|
||||
/*****************************************************************************/
|
||||
|
|
Loading…
Reference in New Issue