mirror of https://github.com/acanas/swad-core.git
Version18.89.2
This commit is contained in:
parent
70067d5236
commit
15ae621148
|
@ -2467,80 +2467,51 @@ a:hover img.CENTRE_PHOTO_SHOW
|
||||||
margin:0 0 0 1em;
|
margin:0 0 0 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.TEST_IMG_SHOW_STEM_CONTAINER
|
.TEST_MED_SHOW_CONTAINER
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
margin:10px 0;
|
margin:10px 0;
|
||||||
}
|
}
|
||||||
.TEST_IMG_SHOW_STEM
|
.TEST_MED_SHOW
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
border-radius:4px;
|
border-radius:4px;
|
||||||
}
|
}
|
||||||
.TEST_IMG_SHOW_ANS_CONTAINER
|
.TEST_MED_EDIT_LIST_CONTAINER
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
margin:10px 0;
|
|
||||||
}
|
|
||||||
.TEST_IMG_SHOW_ANS
|
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
border-radius:4px;
|
|
||||||
}
|
|
||||||
.TEST_IMG_EDIT_LIST_STEM_CONTAINER
|
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
margin:5px 0;
|
margin:5px 0;
|
||||||
}
|
}
|
||||||
.TEST_IMG_EDIT_LIST_STEM
|
.TEST_MED_EDIT_LIST
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
border-radius:2px;
|
|
||||||
}
|
|
||||||
.TEST_IMG_EDIT_LIST_ANS_CONTAINER
|
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
margin:5px 0;
|
|
||||||
}
|
|
||||||
.TEST_IMG_EDIT_LIST_ANS
|
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
border-radius:2px;
|
border-radius:2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.TEST_FORM_EDIT_MED
|
.TEST_MED_EDIT_FORM
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
margin:15px 0;
|
margin:15px 0;
|
||||||
text-align:left;
|
text-align:left;
|
||||||
vertical-align:top;
|
vertical-align:top;
|
||||||
}
|
}
|
||||||
|
.TEST_MED_INPUT
|
||||||
|
{
|
||||||
|
box-sizing:border-box;
|
||||||
|
margin:0 auto;
|
||||||
|
width:480px;
|
||||||
|
}
|
||||||
|
|
||||||
.TEST_IMG_EDIT_ONE_STEM_CONTAINER
|
.TEST_MED_EDIT_ONE_CONTAINER
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
}
|
}
|
||||||
.TEST_IMG_EDIT_ONE_STEM
|
.TEST_MED_EDIT_ONE
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
border-radius:4px;
|
|
||||||
}
|
|
||||||
.TEST_IMG_EDIT_ONE_ANS_CONTAINER
|
|
||||||
{
|
|
||||||
box-sizing:border-box;
|
|
||||||
width:100%;
|
|
||||||
}
|
|
||||||
.TEST_IMG_EDIT_ONE_ANS
|
|
||||||
{
|
{
|
||||||
box-sizing:border-box;
|
box-sizing:border-box;
|
||||||
width:100%;
|
width:100%;
|
||||||
|
@ -2747,12 +2718,6 @@ a:hover img.CENTRE_PHOTO_SHOW
|
||||||
}
|
}
|
||||||
|
|
||||||
/*********************** Media (image/video) uploading ***********************/
|
/*********************** Media (image/video) uploading ***********************/
|
||||||
.MED_UPL_CON /* Upload container */
|
|
||||||
{
|
|
||||||
text-align:center;
|
|
||||||
margin-bottom:6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.MED_PLAY
|
.MED_PLAY
|
||||||
{
|
{
|
||||||
position:relative;
|
position:relative;
|
|
@ -464,10 +464,12 @@ En OpenSWAD:
|
||||||
ps2pdf source.ps destination.pdf
|
ps2pdf source.ps destination.pdf
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 18.89.1 (2019-03-26)"
|
#define Log_PLATFORM_VERSION "SWAD 18.89.2 (2019-03-27)"
|
||||||
#define CSS_FILE "swad18.88.css"
|
#define CSS_FILE "swad18.89.2.css"
|
||||||
#define JS_FILE "swad18.88.js"
|
#define JS_FILE "swad18.88.js"
|
||||||
/*
|
/*
|
||||||
|
Version 18.89.2: Mar 27, 2019 Help link when writing a test question.
|
||||||
|
Changes in multimedia attachment form. (241111 lines)
|
||||||
Version 18.89.1: Mar 26, 2019 Corrections in help links after recent changes. (241090 lines)
|
Version 18.89.1: Mar 26, 2019 Corrections in help links after recent changes. (241090 lines)
|
||||||
Version 18.89: Mar 26, 2019 Corrections in help links after recent changes.
|
Version 18.89: Mar 26, 2019 Corrections in help links after recent changes.
|
||||||
Module swad_preference is renamed swad_setting. (241090 lines)
|
Module swad_preference is renamed swad_setting. (241090 lines)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// swad_firewall.c: firewall to mitigate mitigate denial of service attacks
|
// swad_firewall.c: firewall to mitigate denial of service attacks
|
||||||
|
|
||||||
/*
|
/*
|
||||||
SWAD (Shared Workspace At a Distance),
|
SWAD (Shared Workspace At a Distance),
|
||||||
|
@ -105,7 +105,7 @@ void FW_CheckFirewallAndExitIfBanned (void)
|
||||||
Gbl.IP);
|
Gbl.IP);
|
||||||
|
|
||||||
/***** Exit with status 403 if banned *****/
|
/***** Exit with status 403 if banned *****/
|
||||||
/* RFC 6585 suggests "429 Too Many Requests", according to
|
/* RFC 6585 suggests "403 Forbidden", according to
|
||||||
https://stackoverflow.com/questions/7447283/proper-http-status-to-return-for-hacking-attempts
|
https://stackoverflow.com/questions/7447283/proper-http-status-to-return-for-hacking-attempts
|
||||||
https://tools.ietf.org/html/rfc2616#section-10.4.4 */
|
https://tools.ietf.org/html/rfc2616#section-10.4.4 */
|
||||||
if (NumCurrentBans)
|
if (NumCurrentBans)
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
// swad_firewall.h: firewall to mitigate mitigate denial of service attacks
|
// swad_firewall.h: firewall to mitigate denial of service attacks
|
||||||
|
|
||||||
#ifndef _SWAD_FW
|
#ifndef _SWAD_FW
|
||||||
#define _SWAD_FW
|
#define _SWAD_FW
|
||||||
|
|
|
@ -2928,8 +2928,8 @@ static void Gam_ListOneOrMoreQuestionsForEdition (struct Game *Game,
|
||||||
|
|
||||||
/* Show media */
|
/* Show media */
|
||||||
Med_ShowMedia (&Gbl.Test.Media,
|
Med_ShowMedia (&Gbl.Test.Media,
|
||||||
"TEST_IMG_EDIT_LIST_STEM_CONTAINER",
|
"TEST_MED_EDIT_LIST_STEM_CONTAINER",
|
||||||
"TEST_IMG_EDIT_LIST_STEM");
|
"TEST_MED_EDIT_LIST_STEM");
|
||||||
|
|
||||||
/* Show feedback (row[3]) */
|
/* Show feedback (row[3]) */
|
||||||
Tst_WriteQstFeedback (row[3],"TEST_EDI_LIGHT");
|
Tst_WriteQstFeedback (row[3],"TEST_EDI_LIGHT");
|
||||||
|
@ -3561,8 +3561,8 @@ static void Gam_PlayGameShowQuestionAndAnswers (bool ShowAnswers)
|
||||||
|
|
||||||
/* Show media */
|
/* Show media */
|
||||||
Med_ShowMedia (&Gbl.Test.Media,
|
Med_ShowMedia (&Gbl.Test.Media,
|
||||||
"TEST_IMG_EDIT_LIST_STEM_CONTAINER",
|
"TEST_MED_EDIT_LIST_STEM_CONTAINER",
|
||||||
"TEST_IMG_EDIT_LIST_STEM");
|
"TEST_MED_EDIT_LIST_STEM");
|
||||||
|
|
||||||
/* Write answers? */
|
/* Write answers? */
|
||||||
if (ShowAnswers)
|
if (ShowAnswers)
|
||||||
|
|
|
@ -29,6 +29,27 @@
|
||||||
#define L 3 // English
|
#define L 3 // English
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
const char *Hlp_Multimedia =
|
||||||
|
#if L==1
|
||||||
|
"Multimedia.es";
|
||||||
|
#elif L==2
|
||||||
|
"Multimedia.en";
|
||||||
|
#elif L==3
|
||||||
|
"Multimedia.en";
|
||||||
|
#elif L==4
|
||||||
|
"Multimedia.es";
|
||||||
|
#elif L==5
|
||||||
|
"Multimedia.en";
|
||||||
|
#elif L==6
|
||||||
|
"Multimedia.es";
|
||||||
|
#elif L==7
|
||||||
|
"Multimedia.en";
|
||||||
|
#elif L==8
|
||||||
|
"Multimedia.en";
|
||||||
|
#elif L==9
|
||||||
|
"Multimedia.en";
|
||||||
|
#endif
|
||||||
|
|
||||||
/***** START tab *****/
|
/***** START tab *****/
|
||||||
|
|
||||||
const char *Hlp_START_Search =
|
const char *Hlp_START_Search =
|
||||||
|
@ -1180,6 +1201,27 @@ const char *Hlp_ASSESSMENT_Tests =
|
||||||
"ASSESSMENT.Tests.en";
|
"ASSESSMENT.Tests.en";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
const char *Hlp_ASSESSMENT_Tests_writing_a_question =
|
||||||
|
#if L==1
|
||||||
|
"ASSESSMENT.Tests.es#escribir-una-pregunta";
|
||||||
|
#elif L==2
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#elif L==3
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#elif L==4
|
||||||
|
"ASSESSMENT.Tests.es#escribir-una-pregunta";
|
||||||
|
#elif L==5
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#elif L==6
|
||||||
|
"ASSESSMENT.Tests.es#escribir-una-pregunta";
|
||||||
|
#elif L==7
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#elif L==8
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#elif L==9
|
||||||
|
"ASSESSMENT.Tests.en#writing-a-question";
|
||||||
|
#endif
|
||||||
|
|
||||||
const char *Hlp_ASSESSMENT_Tests_test_results =
|
const char *Hlp_ASSESSMENT_Tests_test_results =
|
||||||
#if L==1
|
#if L==1
|
||||||
"ASSESSMENT.Tests.es#resultados-de-tests";
|
"ASSESSMENT.Tests.es#resultados-de-tests";
|
||||||
|
|
12
swad_media.c
12
swad_media.c
|
@ -36,6 +36,7 @@
|
||||||
#include <sys/wait.h> // For the macro WEXITSTATUS
|
#include <sys/wait.h> // For the macro WEXITSTATUS
|
||||||
#include <unistd.h> // For unlink, lstat
|
#include <unistd.h> // For unlink, lstat
|
||||||
|
|
||||||
|
#include "swad_box.h"
|
||||||
#include "swad_config.h"
|
#include "swad_config.h"
|
||||||
#include "swad_cookie.h"
|
#include "swad_cookie.h"
|
||||||
#include "swad_database.h"
|
#include "swad_database.h"
|
||||||
|
@ -324,6 +325,8 @@ void Med_GetMediaDataByCod (struct Media *Media)
|
||||||
|
|
||||||
void Med_PutMediaUploader (int NumMediaInForm,const char *ClassInput)
|
void Med_PutMediaUploader (int NumMediaInForm,const char *ClassInput)
|
||||||
{
|
{
|
||||||
|
extern const char *Hlp_Multimedia;
|
||||||
|
extern const char *Txt_Multimedia;
|
||||||
extern const char *Txt_Image_video;
|
extern const char *Txt_Image_video;
|
||||||
extern const char *Txt_Title_attribution;
|
extern const char *Txt_Title_attribution;
|
||||||
extern const char *Txt_Link;
|
extern const char *Txt_Link;
|
||||||
|
@ -336,8 +339,9 @@ void Med_PutMediaUploader (int NumMediaInForm,const char *ClassInput)
|
||||||
/***** Create unique id for this media uploader *****/
|
/***** Create unique id for this media uploader *****/
|
||||||
Frm_SetUniqueId (Id);
|
Frm_SetUniqueId (Id);
|
||||||
|
|
||||||
/***** Start container *****/
|
/***** Start box *****/
|
||||||
fprintf (Gbl.F.Out,"<div class=\"MED_UPL_CON\">"); // container
|
Box_StartBox (NULL,Txt_Multimedia,NULL,
|
||||||
|
Hlp_Multimedia,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Action to perform on media *****/
|
/***** Action to perform on media *****/
|
||||||
Par_PutHiddenParamUnsigned (ParamUploadMedia.Action,(unsigned) Med_ACTION_NEW_MEDIA);
|
Par_PutHiddenParamUnsigned (ParamUploadMedia.Action,(unsigned) Med_ACTION_NEW_MEDIA);
|
||||||
|
@ -451,8 +455,8 @@ void Med_PutMediaUploader (int NumMediaInForm,const char *ClassInput)
|
||||||
/***** End input fields *****/
|
/***** End input fields *****/
|
||||||
fprintf (Gbl.F.Out,"</div>"); // input fields
|
fprintf (Gbl.F.Out,"</div>"); // input fields
|
||||||
|
|
||||||
/***** End container *****/
|
/***** End box *****/
|
||||||
fprintf (Gbl.F.Out,"</div>"); // container
|
Box_EndBox ();
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
60
swad_test.c
60
swad_test.c
|
@ -161,9 +161,6 @@ static void Tst_WriteQstAndAnsTest (Tst_ActionToDoWithQuestions_t ActionToDoWith
|
||||||
unsigned NumQst,long QstCod,MYSQL_ROW row,
|
unsigned NumQst,long QstCod,MYSQL_ROW row,
|
||||||
double *ScoreThisQst,bool *AnswerIsNotBlank);
|
double *ScoreThisQst,bool *AnswerIsNotBlank);
|
||||||
static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
||||||
const char *ClassContainer,
|
|
||||||
const char *ClassMedia,
|
|
||||||
const char *ClassMediaInput,
|
|
||||||
bool OptionsDisabled);
|
bool OptionsDisabled);
|
||||||
static void Tst_UpdateScoreQst (long QstCod,float ScoreThisQst,bool AnswerIsNotBlank);
|
static void Tst_UpdateScoreQst (long QstCod,float ScoreThisQst,bool AnswerIsNotBlank);
|
||||||
static void Tst_UpdateMyNumAccessTst (unsigned NumAccessesTst);
|
static void Tst_UpdateMyNumAccessTst (unsigned NumAccessesTst);
|
||||||
|
@ -1056,8 +1053,8 @@ static void Tst_WriteQstAndAnsTest (Tst_ActionToDoWithQuestions_t ActionToDoWith
|
||||||
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
||||||
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
||||||
Med_ShowMedia (&Gbl.Test.Media,
|
Med_ShowMedia (&Gbl.Test.Media,
|
||||||
"TEST_IMG_SHOW_STEM_CONTAINER",
|
"TEST_MED_SHOW_CONTAINER",
|
||||||
"TEST_IMG_SHOW_STEM");
|
"TEST_MED_SHOW");
|
||||||
|
|
||||||
/***** Write answers depending on shuffle (row[3]) and feedback (row[5]) *****/
|
/***** Write answers depending on shuffle (row[3]) and feedback (row[5]) *****/
|
||||||
switch (ActionToDoWithQuestions)
|
switch (ActionToDoWithQuestions)
|
||||||
|
@ -1125,9 +1122,6 @@ void Tst_WriteQstStem (const char *Stem,const char *ClassStem)
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
||||||
const char *ClassContainer,
|
|
||||||
const char *ClassMedia,
|
|
||||||
const char *ClassMediaInput,
|
|
||||||
bool OptionsDisabled)
|
bool OptionsDisabled)
|
||||||
{
|
{
|
||||||
extern const char *The_ClassFormInBox[The_NUM_THEMES];
|
extern const char *The_ClassFormInBox[The_NUM_THEMES];
|
||||||
|
@ -1143,7 +1137,7 @@ static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
||||||
Med_SetParamNames (&ParamUploadMedia,NumMediaInForm);
|
Med_SetParamNames (&ParamUploadMedia,NumMediaInForm);
|
||||||
|
|
||||||
/***** Start container *****/
|
/***** Start container *****/
|
||||||
fprintf (Gbl.F.Out,"<div class=\"TEST_FORM_EDIT_MED\">");
|
fprintf (Gbl.F.Out,"<div class=\"TEST_MED_EDIT_FORM\">");
|
||||||
|
|
||||||
/***** Choice 1: No media *****/
|
/***** Choice 1: No media *****/
|
||||||
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
fprintf (Gbl.F.Out,"<label class=\"%s\">"
|
||||||
|
@ -1169,7 +1163,9 @@ static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
||||||
"%s"
|
"%s"
|
||||||
"</label>",
|
"</label>",
|
||||||
Txt_Current_image_video);
|
Txt_Current_image_video);
|
||||||
Med_ShowMedia (Media,ClassContainer,ClassMedia);
|
Med_ShowMedia (Media,
|
||||||
|
"TEST_MED_EDIT_ONE_CONTAINER",
|
||||||
|
"TEST_MED_EDIT_ONE");
|
||||||
|
|
||||||
/***** Choice 3: Change media *****/
|
/***** Choice 3: Change media *****/
|
||||||
UniqueId++;
|
UniqueId++;
|
||||||
|
@ -1185,14 +1181,14 @@ static void Tst_PutFormToEditQstMedia (struct Media *Media,int NumMediaInForm,
|
||||||
"%s: "
|
"%s: "
|
||||||
"</label>",
|
"</label>",
|
||||||
Txt_Change_image_video);
|
Txt_Change_image_video);
|
||||||
Med_PutMediaUploader (NumMediaInForm,ClassMediaInput);
|
Med_PutMediaUploader (NumMediaInForm,"TEST_MED_INPUT");
|
||||||
|
|
||||||
/***** End container *****/
|
/***** End container *****/
|
||||||
fprintf (Gbl.F.Out,"</div>");
|
fprintf (Gbl.F.Out,"</div>");
|
||||||
}
|
}
|
||||||
else // No current image
|
else // No current image
|
||||||
/***** Attached media *****/
|
/***** Attached media *****/
|
||||||
Med_PutMediaUploader (NumMediaInForm,ClassMediaInput);
|
Med_PutMediaUploader (NumMediaInForm,"TEST_MED_INPUT");
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -1788,7 +1784,7 @@ static void Tst_ShowFormSelTags (unsigned long NumRows,MYSQL_RES *mysql_res,
|
||||||
|
|
||||||
static void Tst_ShowFormEditTags (void)
|
static void Tst_ShowFormEditTags (void)
|
||||||
{
|
{
|
||||||
extern const char *Hlp_ASSESSMENT_Tests;
|
extern const char *Hlp_ASSESSMENT_Tests_writing_a_question;
|
||||||
extern const char *Txt_No_test_questions;
|
extern const char *Txt_No_test_questions;
|
||||||
extern const char *Txt_Tags;
|
extern const char *Txt_Tags;
|
||||||
MYSQL_RES *mysql_res;
|
MYSQL_RES *mysql_res;
|
||||||
|
@ -1801,7 +1797,7 @@ static void Tst_ShowFormEditTags (void)
|
||||||
{
|
{
|
||||||
/***** Start box and table *****/
|
/***** Start box and table *****/
|
||||||
Box_StartBoxTable (NULL,Txt_Tags,NULL,
|
Box_StartBoxTable (NULL,Txt_Tags,NULL,
|
||||||
Hlp_ASSESSMENT_Tests,Box_NOT_CLOSABLE,2);
|
Hlp_ASSESSMENT_Tests_writing_a_question,Box_NOT_CLOSABLE,2);
|
||||||
|
|
||||||
/***** Show tags *****/
|
/***** Show tags *****/
|
||||||
for (NumRow = 0;
|
for (NumRow = 0;
|
||||||
|
@ -2986,8 +2982,8 @@ static void Tst_ListOneOrMoreQuestionsForEdition (unsigned long NumRows,
|
||||||
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
||||||
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
||||||
Med_ShowMedia (&Gbl.Test.Media,
|
Med_ShowMedia (&Gbl.Test.Media,
|
||||||
"TEST_IMG_EDIT_LIST_STEM_CONTAINER",
|
"TEST_MED_EDIT_LIST_CONTAINER",
|
||||||
"TEST_IMG_EDIT_LIST_STEM");
|
"TEST_MED_EDIT_LIST");
|
||||||
|
|
||||||
/* Write feedback (row[5]) and answers */
|
/* Write feedback (row[5]) and answers */
|
||||||
Tst_WriteQstFeedback (row[5],"TEST_EDI_LIGHT");
|
Tst_WriteQstFeedback (row[5],"TEST_EDI_LIGHT");
|
||||||
|
@ -3222,8 +3218,8 @@ static void Tst_ListOneOrMoreQuestionsForSelection (long GamCod,
|
||||||
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
Gbl.Test.Media.MedCod = Str_ConvertStrCodToLongCod (row[6]);
|
||||||
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
Med_GetMediaDataByCod (&Gbl.Test.Media);
|
||||||
Med_ShowMedia (&Gbl.Test.Media,
|
Med_ShowMedia (&Gbl.Test.Media,
|
||||||
"TEST_IMG_EDIT_LIST_STEM_CONTAINER",
|
"TEST_MED_EDIT_LIST_CONTAINER",
|
||||||
"TEST_IMG_EDIT_LIST_STEM");
|
"TEST_MED_EDIT_LIST");
|
||||||
|
|
||||||
/* Write feedback (row[5]) */
|
/* Write feedback (row[5]) */
|
||||||
Tst_WriteQstFeedback (row[5],"TEST_EDI_LIGHT");
|
Tst_WriteQstFeedback (row[5],"TEST_EDI_LIGHT");
|
||||||
|
@ -3412,8 +3408,8 @@ static void Tst_WriteAnswersEdit (long QstCod)
|
||||||
"%s",
|
"%s",
|
||||||
Answer);
|
Answer);
|
||||||
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
||||||
"TEST_IMG_EDIT_LIST_ANS_CONTAINER",
|
"TEST_MED_EDIT_LIST_CONTAINER",
|
||||||
"TEST_IMG_EDIT_LIST_ANS");
|
"TEST_MED_EDIT_LIST");
|
||||||
fprintf (Gbl.F.Out,"</div>");
|
fprintf (Gbl.F.Out,"</div>");
|
||||||
|
|
||||||
/* Write the text of the feedback */
|
/* Write the text of the feedback */
|
||||||
|
@ -3769,8 +3765,8 @@ static void Tst_WriteChoiceAnsViewTest (unsigned NumQst,long QstCod,bool Shuffle
|
||||||
NumQst,NumOpt,
|
NumQst,NumOpt,
|
||||||
Gbl.Test.Answer.Options[NumOpt].Text);
|
Gbl.Test.Answer.Options[NumOpt].Text);
|
||||||
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
||||||
"TEST_IMG_SHOW_ANS_CONTAINER",
|
"TEST_MED_SHOW_CONTAINER",
|
||||||
"TEST_IMG_SHOW_ANS");
|
"TEST_MED_SHOW");
|
||||||
fprintf (Gbl.F.Out,"</td>"
|
fprintf (Gbl.F.Out,"</td>"
|
||||||
"</tr>");
|
"</tr>");
|
||||||
}
|
}
|
||||||
|
@ -3956,8 +3952,8 @@ static void Tst_WriteChoiceAnsAssessTest (struct UsrData *UsrDat,
|
||||||
"%s",
|
"%s",
|
||||||
Gbl.Test.Answer.Options[Indexes[NumOpt]].Text);
|
Gbl.Test.Answer.Options[Indexes[NumOpt]].Text);
|
||||||
Med_ShowMedia (&Gbl.Test.Answer.Options[Indexes[NumOpt]].Media,
|
Med_ShowMedia (&Gbl.Test.Answer.Options[Indexes[NumOpt]].Media,
|
||||||
"TEST_IMG_SHOW_ANS_CONTAINER",
|
"TEST_MED_SHOW_CONTAINER",
|
||||||
"TEST_IMG_SHOW_ANS");
|
"TEST_MED_SHOW");
|
||||||
fprintf (Gbl.F.Out,"</div>");
|
fprintf (Gbl.F.Out,"</div>");
|
||||||
if (Gbl.Test.Config.Feedback == Tst_FEEDBACK_FULL_FEEDBACK)
|
if (Gbl.Test.Config.Feedback == Tst_FEEDBACK_FULL_FEEDBACK)
|
||||||
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback)
|
if (Gbl.Test.Answer.Options[Indexes[NumOpt]].Feedback)
|
||||||
|
@ -4120,8 +4116,8 @@ static void Tst_WriteChoiceAnsViewGame (struct Game *Game,
|
||||||
NumQst,NumOpt,Class,
|
NumQst,NumOpt,Class,
|
||||||
Gbl.Test.Answer.Options[NumOpt].Text);
|
Gbl.Test.Answer.Options[NumOpt].Text);
|
||||||
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
Med_ShowMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
||||||
"TEST_IMG_SHOW_ANS_CONTAINER",
|
"TEST_MED_SHOW_CONTAINER",
|
||||||
"TEST_IMG_SHOW_ANS");
|
"TEST_MED_SHOW");
|
||||||
fprintf (Gbl.F.Out,"</td>"
|
fprintf (Gbl.F.Out,"</td>"
|
||||||
"</tr>");
|
"</tr>");
|
||||||
|
|
||||||
|
@ -4915,7 +4911,7 @@ void Tst_ShowFormEditOneQst (void)
|
||||||
static void Tst_PutFormEditOneQst (char Stem[Cns_MAX_BYTES_TEXT + 1],
|
static void Tst_PutFormEditOneQst (char Stem[Cns_MAX_BYTES_TEXT + 1],
|
||||||
char Feedback[Cns_MAX_BYTES_TEXT + 1])
|
char Feedback[Cns_MAX_BYTES_TEXT + 1])
|
||||||
{
|
{
|
||||||
extern const char *Hlp_ASSESSMENT_Tests;
|
extern const char *Hlp_ASSESSMENT_Tests_writing_a_question;
|
||||||
extern const char *The_ClassFormInBox[The_NUM_THEMES];
|
extern const char *The_ClassFormInBox[The_NUM_THEMES];
|
||||||
extern const char *Txt_Question_code_X;
|
extern const char *Txt_Question_code_X;
|
||||||
extern const char *Txt_New_question;
|
extern const char *Txt_New_question;
|
||||||
|
@ -4955,11 +4951,11 @@ static void Tst_PutFormEditOneQst (char Stem[Cns_MAX_BYTES_TEXT + 1],
|
||||||
Txt_Question_code_X,
|
Txt_Question_code_X,
|
||||||
Gbl.Test.QstCod);
|
Gbl.Test.QstCod);
|
||||||
Box_StartBox (NULL,Gbl.Title,Tst_PutIconToRemoveOneQst,
|
Box_StartBox (NULL,Gbl.Title,Tst_PutIconToRemoveOneQst,
|
||||||
Hlp_ASSESSMENT_Tests,Box_NOT_CLOSABLE);
|
Hlp_ASSESSMENT_Tests_writing_a_question,Box_NOT_CLOSABLE);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
Box_StartBox (NULL,Txt_New_question,NULL,
|
Box_StartBox (NULL,Txt_New_question,NULL,
|
||||||
Hlp_ASSESSMENT_Tests,Box_NOT_CLOSABLE);
|
Hlp_ASSESSMENT_Tests_writing_a_question,Box_NOT_CLOSABLE);
|
||||||
|
|
||||||
/***** Start form *****/
|
/***** Start form *****/
|
||||||
Frm_StartForm (ActRcvTstQst);
|
Frm_StartForm (ActRcvTstQst);
|
||||||
|
@ -5061,9 +5057,6 @@ static void Tst_PutFormEditOneQst (char Stem[Cns_MAX_BYTES_TEXT + 1],
|
||||||
Txt_Stem,
|
Txt_Stem,
|
||||||
Stem);
|
Stem);
|
||||||
Tst_PutFormToEditQstMedia (&Gbl.Test.Media,-1,
|
Tst_PutFormToEditQstMedia (&Gbl.Test.Media,-1,
|
||||||
"TEST_IMG_EDIT_ONE_STEM_CONTAINER",
|
|
||||||
"TEST_IMG_EDIT_ONE_STEM",
|
|
||||||
"STEM", // Title / attribution
|
|
||||||
false);
|
false);
|
||||||
|
|
||||||
/***** Feedback *****/
|
/***** Feedback *****/
|
||||||
|
@ -5276,9 +5269,6 @@ static void Tst_PutFormEditOneQst (char Stem[Cns_MAX_BYTES_TEXT + 1],
|
||||||
/* Media */
|
/* Media */
|
||||||
Tst_PutFormToEditQstMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
Tst_PutFormToEditQstMedia (&Gbl.Test.Answer.Options[NumOpt].Media,
|
||||||
(int) NumOpt,
|
(int) NumOpt,
|
||||||
"TEST_IMG_EDIT_ONE_ANS_CONTAINER",
|
|
||||||
"TEST_IMG_EDIT_ONE_ANS",
|
|
||||||
"ANSWER", // Form inputs
|
|
||||||
OptionsDisabled);
|
OptionsDisabled);
|
||||||
|
|
||||||
/* Feedback */
|
/* Feedback */
|
||||||
|
|
21
swad_text.c
21
swad_text.c
|
@ -23190,6 +23190,27 @@ const char *Txt_MSGS_Sent =
|
||||||
"Enviadas";
|
"Enviadas";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
const char *Txt_Multimedia =
|
||||||
|
#if L==1 // ca
|
||||||
|
"Multimèdia";
|
||||||
|
#elif L==2 // de
|
||||||
|
"Multimedia";
|
||||||
|
#elif L==3 // en
|
||||||
|
"Multimedia";
|
||||||
|
#elif L==4 // es
|
||||||
|
"Multimedia";
|
||||||
|
#elif L==5 // fr
|
||||||
|
"Multimédia";
|
||||||
|
#elif L==6 // gn
|
||||||
|
"Multimedia";
|
||||||
|
#elif L==7 // it
|
||||||
|
"Multimedialità";
|
||||||
|
#elif L==8 // pl
|
||||||
|
"Multimedia";
|
||||||
|
#elif L==9 // pt
|
||||||
|
"Multimédia";
|
||||||
|
#endif
|
||||||
|
|
||||||
const char *Txt_Multiple_enrolment = // (to a type of group)
|
const char *Txt_Multiple_enrolment = // (to a type of group)
|
||||||
#if L==1 // ca
|
#if L==1 // ca
|
||||||
"¿Adscripción múltiple?"; // Necessita traduccio
|
"¿Adscripción múltiple?"; // Necessita traduccio
|
||||||
|
|
Loading…
Reference in New Issue