Version 20.94.10: Jun 29, 2021 Code refactoring related to HTML output.

This commit is contained in:
acanas 2021-06-29 15:25:42 +02:00
parent 06f41515fd
commit 36170e5cb0
52 changed files with 1433 additions and 1422 deletions

View File

@ -637,7 +637,7 @@ static bool API_GetSomeUsrDataFromUsrCod (struct UsrData *UsrDat,long CrsCod)
ID_GetListIDsFromUsrCod (UsrDat);
/***** Get user's nickname *****/
Nck_GetNicknameFromUsrCod (UsrDat->UsrCod,UsrDat->Nickname);
Nck_DB_GetNicknameFromUsrCod (UsrDat->UsrCod,UsrDat->Nickname);
/***** Get user's role *****/
if (CrsCod > 0)
@ -722,7 +722,7 @@ int swad__createAccount (struct soap *soap,
true); // I am creating my own account
/***** Save nickname *****/
Nck_UpdateNickInDB (Gbl.Usrs.Me.UsrDat.UsrCod,NewNickWithoutArr);
Nck_DB_UpdateNick (Gbl.Usrs.Me.UsrDat.UsrCod,NewNickWithoutArr);
Str_Copy (Gbl.Usrs.Me.UsrDat.Nickname,NewNickWithoutArr,
sizeof (Gbl.Usrs.Me.UsrDat.Nickname) - 1);
@ -1919,7 +1919,7 @@ static void API_CopyListUsers (struct soap *soap,
ICanSeeUsrID = ID_ICanSeeOtherUsrIDs (&UsrDat);
/* Get nickname */
Nck_GetNicknameFromUsrCod (UsrDat.UsrCod,UsrDat.Nickname);
Nck_DB_GetNicknameFromUsrCod (UsrDat.UsrCod,UsrDat.Nickname);
/* Copy user's data into output structure */
API_CopyUsrData (soap,

View File

@ -497,7 +497,7 @@ static void ID_PutLinkToConfirmID (struct UsrData *UsrDat,unsigned NumID,
NextAction = ActCnfID_Oth;
break;
}
Frm_StartFormAnchor (NextAction,Anchor);
Frm_BeginFormAnchor (NextAction,Anchor);
if (Gbl.Action.Original != ActUnk)
{
Par_PutHiddenParamLong (NULL,"OriginalActCod",
@ -705,7 +705,7 @@ static void ID_ShowFormChangeUsrID (bool ItsMe,bool IShouldFillInID)
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
if (ItsMe)
Frm_StartFormAnchor (ActChgMyID,ID_ID_SECTION_ID);
Frm_BeginFormAnchor (ActChgMyID,ID_ID_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
@ -721,7 +721,7 @@ static void ID_ShowFormChangeUsrID (bool ItsMe,bool IShouldFillInID)
NextAction = ActNewID_Oth;
break;
}
Frm_StartFormAnchor (NextAction,ID_ID_SECTION_ID);
Frm_BeginFormAnchor (NextAction,ID_ID_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
HTM_INPUT_TEXT ("NewID",ID_MAX_BYTES_USR_ID,

View File

@ -86,7 +86,7 @@ static void MAC_PutFormToEditMACAddress (Act_Action_t NextAction,const char *Anc
void (*FuncParams) (void *Args),void *Args)
{
/* Form to enter a new MAC address */
Frm_StartFormAnchor (NextAction,Anchor);
Frm_BeginFormAnchor (NextAction,Anchor);
FuncParams (Args);
HTM_INPUT_TEXT ("NewMAC",MAC_LENGTH_MAC_ADDRESS,((struct MAC_Params *) Args)->MACstr,
HTM_SUBMIT_ON_CHANGE,

View File

@ -223,39 +223,47 @@ void MFU_WriteBigMFUActions (struct MFU_ListMFUActions *ListMFUActions)
Box_BoxBegin (NULL,Txt_My_frequent_actions,
NULL,NULL,
Hlp_ANALYTICS_Frequent,Box_NOT_CLOSABLE);
HTM_DIV_Begin ("id=\"MFU_actions_big\"");
/***** Write list of frequently used actions *****/
HTM_UL_Begin ("class=\"LIST_LEFT\"");
for (NumAct = 0;
NumAct < ListMFUActions->NumActions;
NumAct++)
{
Action = ListMFUActions->Actions[NumAct];
/***** Begin container *****/
HTM_DIV_Begin ("id=\"MFU_actions_big\"");
if ((Title = Act_GetTitleAction (Action)) != NULL)
{
/* Action string */
Str_Copy (TabStr,Txt_TABS_TXT[Act_GetTab (Act_GetSuperAction (Action))],
sizeof (TabStr) - 1);
Str_Copy (MenuStr,Title,sizeof (MenuStr) - 1);
snprintf (TabMenuStr,sizeof (TabMenuStr),"%s &gt; %s",TabStr,MenuStr);
/***** Begin list of frequently used actions *****/
HTM_UL_Begin ("class=\"LIST_LEFT\"");
/* Icon and text */
HTM_LI_Begin ("class=\"ICO_HIGHLIGHT\"");
Frm_BeginForm (Action);
HTM_BUTTON_SUBMIT_Begin (TabMenuStr,The_ClassFormLinkInBoxNoWrap[Gbl.Prefs.Theme],NULL);
HTM_IMG (Gbl.Prefs.URLIconSet,Act_GetIcon (Action),MenuStr,
NULL);
HTM_TxtF ("&nbsp;%s",TabMenuStr);
HTM_BUTTON_End ();
Frm_EndForm ();
HTM_LI_End ();
}
}
for (NumAct = 0;
NumAct < ListMFUActions->NumActions;
NumAct++)
{
Action = ListMFUActions->Actions[NumAct];
if ((Title = Act_GetTitleAction (Action)) != NULL)
{
/* Action string */
Str_Copy (TabStr,Txt_TABS_TXT[Act_GetTab (Act_GetSuperAction (Action))],
sizeof (TabStr) - 1);
Str_Copy (MenuStr,Title,sizeof (MenuStr) - 1);
snprintf (TabMenuStr,sizeof (TabMenuStr),"%s &gt; %s",TabStr,MenuStr);
/* Icon and text */
HTM_LI_Begin ("class=\"ICO_HIGHLIGHT\"");
Frm_BeginForm (Action);
HTM_BUTTON_SUBMIT_Begin (TabMenuStr,The_ClassFormLinkInBoxNoWrap[Gbl.Prefs.Theme],NULL);
HTM_IMG (Gbl.Prefs.URLIconSet,Act_GetIcon (Action),MenuStr,
NULL);
HTM_TxtF ("&nbsp;%s",TabMenuStr);
HTM_BUTTON_End ();
Frm_EndForm ();
HTM_LI_End ();
}
}
/***** End list of frequently used actions *****/
HTM_UL_End ();
/***** End container *****/
HTM_DIV_End ();
/***** End box *****/
HTM_DIV_End ();
Box_BoxEnd ();
}
@ -277,41 +285,45 @@ void MFU_WriteSmallMFUActions (struct MFU_ListMFUActions *ListMFUActions)
/***** Start div and link *****/
HTM_DIV_Begin ("id=\"MFU_actions\"");
Frm_BeginForm (ActMFUAct);
HTM_BUTTON_SUBMIT_Begin (Txt_My_frequent_actions,"BT_LINK MFU_TITLE",NULL);
HTM_TxtF ("%s",Txt_Frequent_ACTIONS);
HTM_BUTTON_End ();
Frm_EndForm ();
/***** Write list of frequently used actions *****/
HTM_UL_Begin (NULL);
for (NumAct = 0;
NumAct < ListMFUActions->NumActions;
NumAct++)
{
Action = ListMFUActions->Actions[NumAct];
if ((Title = Act_GetTitleAction (Action)) != NULL)
{
/* Action string */
Str_Copy (TabStr,Txt_TABS_TXT[Act_GetTab (Act_GetSuperAction (Action))],
sizeof (TabStr) - 1);
Str_Copy (MenuStr,Title,sizeof (MenuStr) - 1);
snprintf (TabMenuStr,sizeof (TabMenuStr),"%s &gt; %s",TabStr,MenuStr);
/* Icon and text */
HTM_LI_Begin ("class=\"ICO_HIGHLIGHT\"");
Frm_BeginForm (Action);
HTM_BUTTON_SUBMIT_Begin (TabMenuStr,"BT_LINK",NULL);
HTM_IMG (Gbl.Prefs.URLIconSet,Act_GetIcon (Action),MenuStr,
NULL);
HTM_TxtF ("&nbsp;%s",MenuStr);
Frm_BeginForm (ActMFUAct);
HTM_BUTTON_SUBMIT_Begin (Txt_My_frequent_actions,"BT_LINK MFU_TITLE",NULL);
HTM_TxtF ("%s",Txt_Frequent_ACTIONS);
HTM_BUTTON_End ();
Frm_EndForm ();
HTM_LI_End ();
}
}
HTM_UL_End ();
Frm_EndForm ();
/***** Begin list of frequently used actions *****/
HTM_UL_Begin (NULL);
for (NumAct = 0;
NumAct < ListMFUActions->NumActions;
NumAct++)
{
Action = ListMFUActions->Actions[NumAct];
if ((Title = Act_GetTitleAction (Action)) != NULL)
{
/* Action string */
Str_Copy (TabStr,Txt_TABS_TXT[Act_GetTab (Act_GetSuperAction (Action))],
sizeof (TabStr) - 1);
Str_Copy (MenuStr,Title,sizeof (MenuStr) - 1);
snprintf (TabMenuStr,sizeof (TabMenuStr),"%s &gt; %s",TabStr,MenuStr);
/* Icon and text */
HTM_LI_Begin ("class=\"ICO_HIGHLIGHT\"");
Frm_BeginForm (Action);
HTM_BUTTON_SUBMIT_Begin (TabMenuStr,"BT_LINK",NULL);
HTM_IMG (Gbl.Prefs.URLIconSet,Act_GetIcon (Action),MenuStr,
NULL);
HTM_TxtF ("&nbsp;%s",MenuStr);
HTM_BUTTON_End ();
Frm_EndForm ();
HTM_LI_End ();
}
}
/***** End list of frequently used actions *****/
HTM_UL_End ();
/***** End div *****/
HTM_DIV_End ();

View File

@ -471,7 +471,7 @@ void Acc_ShowFormChgMyAccount (void)
/***** Get current user's nickname and email address
It's necessary because current nickname or email could be just updated *****/
Nck_GetNicknameFromUsrCod (Gbl.Usrs.Me.UsrDat.UsrCod,Gbl.Usrs.Me.UsrDat.Nickname);
Nck_DB_GetNicknameFromUsrCod (Gbl.Usrs.Me.UsrDat.UsrCod,Gbl.Usrs.Me.UsrDat.Nickname);
Mai_GetEmailFromUsrCod (&Gbl.Usrs.Me.UsrDat);
/***** Check nickname, email and ID *****/
@ -529,7 +529,7 @@ void Acc_ShowFormChgOtherUsrAccount (void)
{
/***** Get user's nickname and email address
It's necessary because nickname or email could be just updated *****/
Nck_GetNicknameFromUsrCod (Gbl.Usrs.Other.UsrDat.UsrCod,Gbl.Usrs.Other.UsrDat.Nickname);
Nck_DB_GetNicknameFromUsrCod (Gbl.Usrs.Other.UsrDat.UsrCod,Gbl.Usrs.Other.UsrDat.Nickname);
Mai_GetEmailFromUsrCod (&Gbl.Usrs.Other.UsrDat);
/***** Show user's record *****/
@ -610,7 +610,7 @@ bool Acc_CreateMyNewAccountAndLogIn (void)
true); // I am creating my own account
/***** Save nickname *****/
Nck_UpdateNickInDB (Gbl.Usrs.Me.UsrDat.UsrCod,NewNickWithoutArr);
Nck_DB_UpdateNick (Gbl.Usrs.Me.UsrDat.UsrCod,NewNickWithoutArr);
Str_Copy (Gbl.Usrs.Me.UsrDat.Nickname,NewNickWithoutArr,
sizeof (Gbl.Usrs.Me.UsrDat.Nickname) - 1);

View File

@ -993,7 +993,7 @@ void Asg_RemoveAssignment (void)
Asg_DB_RemoveAssignment (Asg.AsgCod);
/***** Mark possible notifications as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_ASSIGNMENT,Asg.AsgCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_ASSIGNMENT,Asg.AsgCod);
/***** Write message to show the change made *****/
Ale_ShowAlert (Ale_SUCCESS,Txt_Assignment_X_removed,

View File

@ -2626,7 +2626,7 @@ static void Att_PutButtonToShowDetails (const struct Att_Events *Events)
/***** Button to show more details *****/
/* Begin form */
Frm_StartFormAnchor (Gbl.Action.Act,Att_ATTENDANCE_DETAILS_ID);
Frm_BeginFormAnchor (Gbl.Action.Act,Att_ATTENDANCE_DETAILS_ID);
Par_PutHiddenParamChar ("ShowDetails",'Y');
Grp_PutParamsCodGrps ();
Usr_PutHiddenParSelectedUsrsCods (&Gbl.Usrs.Selected);
@ -2684,7 +2684,7 @@ static void Att_ListEventsToSelect (const struct Att_Events *Events,
depending on the events selected *****/
if (NormalView)
{
Frm_StartFormAnchor (Gbl.Action.Act,Att_ATTENDANCE_TABLE_ID);
Frm_BeginFormAnchor (Gbl.Action.Act,Att_ATTENDANCE_TABLE_ID);
Grp_PutParamsCodGrps ();
Usr_PutHiddenParSelectedUsrsCods (&Gbl.Usrs.Selected);
}

View File

@ -448,7 +448,7 @@ static void Bld_ListBuildingsForEdition (const struct Bld_Buildings *Buildings)
/* Building short name */
HTM_TD_Begin ("class=\"LM\"");
Frm_StartFormAnchor (ActRenBldSho,Anchor);
Frm_BeginFormAnchor (ActRenBldSho,Anchor);
Bld_PutParamBldCod (&Building->BldCod);
HTM_INPUT_TEXT ("ShortName",Bld_MAX_CHARS_SHRT_NAME,Building->ShrtName,
HTM_SUBMIT_ON_CHANGE,
@ -458,7 +458,7 @@ static void Bld_ListBuildingsForEdition (const struct Bld_Buildings *Buildings)
/* Building full name */
HTM_TD_Begin ("class=\"LM\"");
Frm_StartFormAnchor (ActRenBldFul,Anchor);
Frm_BeginFormAnchor (ActRenBldFul,Anchor);
Bld_PutParamBldCod (&Building->BldCod);
HTM_INPUT_TEXT ("FullName",Bld_MAX_CHARS_FULL_NAME,Building->FullName,
HTM_SUBMIT_ON_CHANGE,
@ -468,7 +468,7 @@ static void Bld_ListBuildingsForEdition (const struct Bld_Buildings *Buildings)
/* Building location */
HTM_TD_Begin ("class=\"LM\"");
Frm_StartFormAnchor (ActRenBldLoc,Anchor);
Frm_BeginFormAnchor (ActRenBldLoc,Anchor);
Bld_PutParamBldCod (&Building->BldCod);
HTM_INPUT_TEXT ("Location",Bld_MAX_CHARS_LOCATION,Building->Location,
HTM_SUBMIT_ON_CHANGE,

View File

@ -465,7 +465,7 @@ void Cfe_RemoveCallForExam1 (void)
Cfe_DB_MarkACallForExamAsDeleted (ExaCod);
/***** Mark possible notifications as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_CALL_FOR_EXAM,ExaCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_CALL_FOR_EXAM,ExaCod);
/***** Mark possible social note as unavailable *****/
Tml_DB_MarkNoteAsUnavailable (TL_NOTE_CALL_FOR_EXAM,ExaCod);
@ -983,7 +983,7 @@ static void Cfe_ShowCallForExam (struct Cfe_CallsForExams *CallsForExams,
if (TypeViewCallForExam == Cfe_FORM_VIEW)
{
/***** Begin form *****/
Frm_StartFormAnchor (ActRcvCfe,Anchor);
Frm_BeginFormAnchor (ActRcvCfe,Anchor);
if (ExaCod > 0) // Existing call for exam
Cfe_PutHiddenParamExaCod (ExaCod);
}

View File

@ -602,13 +602,14 @@ TODO: FIX BUG, URGENT! En las fechas como par
TODO: En las encuestas, que los estudiantes no puedan ver los resultados hasta que no finalice el plazo.
*/
#define Log_PLATFORM_VERSION "SWAD 20.94.9 (2021-06-28)"
#define Log_PLATFORM_VERSION "SWAD 20.94.10 (2021-06-29)"
#define CSS_FILE "swad20.45.css"
#define JS_FILE "swad20.69.1.js"
/*
TODO: Rename CENTRE to CENTER in help wiki.
TODO: Rename ASSESSMENT.Announcements to ASSESSMENT.Calls_for_exams
Version 20.94.10: Jun 29, 2021 Code refactoring related to HTML output. (313860 lines)
Version 20.94.9: Jun 29, 2021 Query moved from module swad_menu to module swad_setting. (313848 lines)
Version 20.94.8: Jun 29, 2021 Queries moved to module swad_group_database. (313834 lines)
Version 20.94.7: Jun 28, 2021 Queries moved to module swad_group_database. (313782 lines)

View File

@ -76,7 +76,7 @@ void Coo_EditMyPrefsOnCookies (void)
/***** Edit my preference about cookies *****/
/* Begin form */
Frm_StartFormAnchor (ActChgCooPrf,Coo_COOKIES_ID);
Frm_BeginFormAnchor (ActChgCooPrf,Coo_COOKIES_ID);
/* Begin container */
HTM_DIV_Begin ("class=\"%s\"",

View File

@ -321,7 +321,7 @@ static void Enr_NotifyAfterEnrolment (struct UsrData *UsrDat,Rol_Role_t NewRole)
NotifyByEmail = CreateNotif && !ItsMe &&
(UsrDat->NtfEvents.SendEmail & (1 << NotifyEvent));
if (CreateNotif)
Ntf_StoreNotifyEventToOneUser (NotifyEvent,UsrDat,-1L,
Ntf_DB_StoreNotifyEventToOneUser (NotifyEvent,UsrDat,-1L,
(Ntf_Status_t) (NotifyByEmail ? Ntf_STATUS_BIT_EMAIL :
0),
Gbl.Hierarchy.Ins.InsCod,
@ -2371,7 +2371,7 @@ static void Enr_RemUsrEnrolmentRequestInCrs (long UsrCod,long CrsCod)
{
/***** Mark possible notifications as removed
Important: do this before removing the request *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_ENROLMENT_REQUEST,ReqCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_ENROLMENT_REQUEST,ReqCod);
/***** Remove enrolment request *****/
Enr_DB_RemRequest (ReqCod);

View File

@ -634,7 +634,7 @@ static void ExaRes_ListExamsToSelect (struct Exa_Exams *Exams)
/***** Begin form to update the results
depending on the exams selected *****/
Frm_StartFormAnchor (Gbl.Action.Act,ExaRes_RESULTS_TABLE_ID);
Frm_BeginFormAnchor (Gbl.Action.Act,ExaRes_RESULTS_TABLE_ID);
Grp_PutParamsCodGrps ();
Usr_PutHiddenParSelectedUsrsCods (&Gbl.Usrs.Selected);

View File

@ -1424,7 +1424,7 @@ void ExaSes_PutButtonNewSession (struct Exa_Exams *Exams,long ExaCod)
extern const char *Txt_New_session;
Exams->ExaCod = ExaCod;
Frm_StartFormAnchor (ActReqNewExaSes,ExaSes_NEW_SESSION_SECTION_ID);
Frm_BeginFormAnchor (ActReqNewExaSes,ExaSes_NEW_SESSION_SECTION_ID);
Exa_PutParams (Exams);
Btn_PutConfirmButton (Txt_New_session);
Frm_EndForm ();

View File

@ -1102,7 +1102,7 @@ static void ExaSet_ListOneOrMoreSetsForEdition (struct Exa_Exams *Exams,
HTM_ARTICLE_Begin (Anchor);
if (ICanEditSets)
{
Frm_StartFormAnchor (ActChgTitExaSet,Anchor);
Frm_BeginFormAnchor (ActChgTitExaSet,Anchor);
ExaSet_PutParamsOneSet (Exams);
HTM_INPUT_TEXT ("Title",ExaSet_MAX_CHARS_TITLE,Set.Title,
HTM_SUBMIT_ON_CHANGE,
@ -1130,7 +1130,7 @@ static void ExaSet_ListOneOrMoreSetsForEdition (struct Exa_Exams *Exams,
HTM_TD_Begin ("class=\"RT COLOR%u\"",Gbl.RowEvenOdd);
if (ICanEditSets)
{
Frm_StartFormAnchor (ActChgNumQstExaSet,Anchor);
Frm_BeginFormAnchor (ActChgNumQstExaSet,Anchor);
ExaSet_PutParamsOneSet (Exams);
HTM_INPUT_LONG ("NumQstsToPrint",0,UINT_MAX,(long) Set.NumQstsToPrint,
HTM_SUBMIT_ON_CHANGE,false,

View File

@ -9829,24 +9829,24 @@ void Brw_ShowFileMetadata (void)
case Brw_SHOW_DOC_GRP:
case Brw_ADMI_DOC_CRS:
case Brw_ADMI_DOC_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_DOCUMENT_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_DOCUMENT_FILE,
FileMetadata.FilCod);
break;
case Brw_ADMI_TCH_CRS:
case Brw_ADMI_TCH_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TEACHERS_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TEACHERS_FILE,
FileMetadata.FilCod);
break;
case Brw_ADMI_SHR_CRS:
case Brw_ADMI_SHR_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_SHARED_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_SHARED_FILE,
FileMetadata.FilCod);
break;
case Brw_SHOW_MRK_CRS:
case Brw_SHOW_MRK_GRP:
case Brw_ADMI_MRK_CRS:
case Brw_ADMI_MRK_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_MARKS_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_MARKS_FILE,
FileMetadata.FilCod);
break;
default:
@ -9988,24 +9988,24 @@ void Brw_DownloadFile (void)
case Brw_SHOW_DOC_GRP:
case Brw_ADMI_DOC_CRS:
case Brw_ADMI_DOC_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_DOCUMENT_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_DOCUMENT_FILE,
FileMetadata.FilCod);
break;
case Brw_ADMI_TCH_CRS:
case Brw_ADMI_TCH_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TEACHERS_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TEACHERS_FILE,
FileMetadata.FilCod);
break;
case Brw_ADMI_SHR_CRS:
case Brw_ADMI_SHR_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_SHARED_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_SHARED_FILE,
FileMetadata.FilCod);
break;
case Brw_SHOW_MRK_CRS:
case Brw_SHOW_MRK_GRP:
case Brw_ADMI_MRK_CRS:
case Brw_ADMI_MRK_GRP:
Ntf_MarkNotifAsRemoved (Ntf_EVENT_MARKS_FILE,
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_MARKS_FILE,
FileMetadata.FilCod);
break;
default:
@ -11750,7 +11750,7 @@ void Brw_RemoveGrpZones (long CrsCod,long GrpCod)
char PathGrpFileZones[PATH_MAX + 1];
/***** Set notifications about files in this group zone as removed *****/
Ntf_MarkNotifFilesInGroupAsRemoved (GrpCod);
Ntf_DB_MarkNotifFilesInGroupAsRemoved (GrpCod);
/***** Remove files in the group from database *****/
Brw_RemoveGrpFilesFromDB (GrpCod);

View File

@ -410,7 +410,7 @@ static void Fol_ShowNumberOfFollowingOrFollowers (const struct UsrData *UsrDat,
if (NumUsrs)
{
/* Form to list users */
Frm_StartFormAnchor (Action,Fol_FOLLOW_SECTION_ID);
Frm_BeginFormAnchor (Action,Fol_FOLLOW_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
HTM_BUTTON_SUBMIT_Begin (Title,
(Gbl.Action.Act == Action) ? "BT_LINK FOLLOW_NUM_B" :
@ -436,7 +436,7 @@ static void Fol_ShowNumberOfFollowingOrFollowers (const struct UsrData *UsrDat,
if (NumUsrs)
{
/* Form to list users */
Frm_StartFormAnchor (Action,Fol_FOLLOW_SECTION_ID);
Frm_BeginFormAnchor (Action,Fol_FOLLOW_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
HTM_BUTTON_SUBMIT_Begin (Title,
(Gbl.Action.Act == Action) ? The_ClassFormLinkOutBoxBold[Gbl.Prefs.Theme] :
@ -1123,7 +1123,7 @@ static void Fol_FollowUsr (struct UsrData *UsrDat)
If this followed wants to receive notifications by email,
activate the sending of a notification *****/
if (CreateNotif)
Ntf_StoreNotifyEventToOneUser (Ntf_EVENT_FOLLOWER,UsrDat,Gbl.Usrs.Me.UsrDat.UsrCod,
Ntf_DB_StoreNotifyEventToOneUser (Ntf_EVENT_FOLLOWER,UsrDat,Gbl.Usrs.Me.UsrDat.UsrCod,
(Ntf_Status_t) (NotifyByEmail ? Ntf_STATUS_BIT_EMAIL :
0),
Gbl.Hierarchy.Ins.InsCod,

View File

@ -68,7 +68,7 @@ void Frm_BeginForm (Act_Action_t NextAction)
Frm_BeginFormAnchorOnSubmit (NextAction,NULL,NULL);
}
void Frm_StartFormAnchor (Act_Action_t NextAction,const char *Anchor)
void Frm_BeginFormAnchor (Act_Action_t NextAction,const char *Anchor)
{
Frm_BeginFormAnchorOnSubmit (NextAction,Anchor,NULL);
}

View File

@ -55,7 +55,7 @@ void Frm_BeginForm (Act_Action_t NextAction);
void Frm_BeginFormOnSubmit (Act_Action_t NextAction,const char *OnSubmit);
void Frm_BeginFormAnchorOnSubmit (Act_Action_t NextAction,const char *Anchor,const char *OnSubmit);
void Frm_BeginFormUnique (Act_Action_t NextAction);
void Frm_StartFormAnchor (Act_Action_t NextAction,const char *Anchor);
void Frm_BeginFormAnchor (Act_Action_t NextAction,const char *Anchor);
void Frm_BeginFormUniqueAnchor (Act_Action_t NextAction,const char *Anchor);
void Frm_BeginFormUniqueAnchorOnSubmit (Act_Action_t NextAction,const char *Anchor,const char *OnSubmit);
void Frm_BeginFormId (Act_Action_t NextAction,const char *Id);

View File

@ -1299,7 +1299,7 @@ static void For_ShowAForumPost (struct For_Forums *Forums,
if (ICanModerateForum)
{
Frm_StartFormAnchor (Enabled ? For_ActionsDisPstFor[Forums->Forum.Type] :
Frm_BeginFormAnchor (Enabled ? For_ActionsDisPstFor[Forums->Forum.Type] :
For_ActionsEnbPstFor[Forums->Forum.Type],
For_FORUM_POSTS_SECTION_ID);
For_PutParamsForum (Forums);
@ -2104,7 +2104,7 @@ static void For_WriteLinkToForum (const struct For_Forums *Forums,
Ico_PutIcon ("paste.svg",Txt_Copy_not_allowed,"CONTEXT_OPT ICO_HIDDEN ICO16x16");
else
{
Frm_StartFormAnchor (For_ActionsPasThrFor[Forum->Type],
Frm_BeginFormAnchor (For_ActionsPasThrFor[Forum->Type],
For_FORUM_THREADS_SECTION_ID);
For_PutAllHiddenParamsForum (1, // Page of threads = first
1, // Page of posts = first
@ -2119,7 +2119,7 @@ static void For_WriteLinkToForum (const struct For_Forums *Forums,
}
/***** Write link to forum *****/
Frm_StartFormAnchor (For_ActionsSeeFor[Forum->Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[Forum->Type],
For_FORUM_THREADS_SECTION_ID);
For_PutAllHiddenParamsForum (1, // Page of threads = first
1, // Page of posts = first
@ -2557,7 +2557,7 @@ static void For_ShowForumThreadsHighlightingOneThread (struct For_Forums *Forums
{
HTM_TH_Begin (1,2,"CM");
Frm_StartFormAnchor (For_ActionsSeeFor[Forums->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[Forums->Forum.Type],
For_FORUM_THREADS_SECTION_ID);
For_PutAllHiddenParamsForum (Forums->CurrentPageThrs, // Page of threads = current
1, // Page of posts = first
@ -3574,7 +3574,7 @@ static void For_ListForumThrs (struct For_Forums *Forums,
if (ICanMoveThreads)
{
HTM_BR ();
Frm_StartFormAnchor (For_ActionsCutThrFor[Forums->Forum.Type],
Frm_BeginFormAnchor (For_ActionsCutThrFor[Forums->Forum.Type],
For_FORUM_THREADS_SECTION_ID);
For_PutAllHiddenParamsForum (Forums->CurrentPageThrs, // Page of threads = current
1, // Page of posts = first
@ -4057,13 +4057,13 @@ static void For_WriteFormForumPst (struct For_Forums *Forums,
/***** Begin form *****/
if (IsReply) // Form to write a reply to a post of an existing thread
{
Frm_StartFormAnchor (For_ActionsRecRepFor[Forums->Forum.Type],
Frm_BeginFormAnchor (For_ActionsRecRepFor[Forums->Forum.Type],
For_FORUM_POSTS_SECTION_ID);
For_PutAllHiddenParamsNewPost (Forums);
}
else // Form to write the first post of a new thread
{
Frm_StartFormAnchor (For_ActionsRecThrFor[Forums->Forum.Type],
Frm_BeginFormAnchor (For_ActionsRecThrFor[Forums->Forum.Type],
For_FORUM_POSTS_SECTION_ID);
For_PutAllHiddenParamsNewThread (Forums);
}
@ -4304,8 +4304,8 @@ void For_RemovePost (void)
Med_MediaDestructor (&Media);
/***** Mark possible notifications as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_FORUM_POST_COURSE,Forums.PstCod);
Ntf_MarkNotifAsRemoved (Ntf_EVENT_FORUM_REPLY ,Forums.PstCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_FORUM_POST_COURSE,Forums.PstCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_FORUM_REPLY ,Forums.PstCod);
/***** Mark possible social note as unavailable *****/
switch (Forums.Forum.Type) // Only if forum is public for any logged user

View File

@ -2581,7 +2581,7 @@ void Gam_PutButtonNewMatch (struct Gam_Games *Games,long GamCod)
{
extern const char *Txt_New_match;
Frm_StartFormAnchor (ActReqNewMch,Mch_NEW_MATCH_SECTION_ID);
Frm_BeginFormAnchor (ActReqNewMch,Mch_NEW_MATCH_SECTION_ID);
Games->GamCod = GamCod;
Gam_PutParams (Games);

View File

@ -388,7 +388,7 @@ void Grp_ShowFormToSelectSeveralGroups (void (*FuncParams) (void *Args),void *Ar
/***** Begin form to update the students listed
depending on the groups selected *****/
Frm_StartFormAnchor (Gbl.Action.Act, // Repeat current action
Frm_BeginFormAnchor (Gbl.Action.Act, // Repeat current action
Usr_USER_LIST_SECTION_ID);
Usr_PutParamsPrefsAboutUsrList ();
if (FuncParams)
@ -1265,7 +1265,7 @@ static void Grp_ListGroupTypesForEdition (void)
/* Name of group type */
HTM_TD_Begin ("class=\"LM\"");
Frm_StartFormAnchor (ActRenGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Frm_BeginFormAnchor (ActRenGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Grp_PutParamGrpTypCod (&Gbl.Crs.Grps.GrpTypes.LstGrpTypes[NumGrpTyp].GrpTypCod);
HTM_INPUT_TEXT ("GrpTypName",Grp_MAX_CHARS_GROUP_TYPE_NAME,
Gbl.Crs.Grps.GrpTypes.LstGrpTypes[NumGrpTyp].GrpTypName,
@ -1276,7 +1276,7 @@ static void Grp_ListGroupTypesForEdition (void)
/* Is it mandatory to register in any group? */
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActChgMdtGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Frm_BeginFormAnchor (ActChgMdtGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Grp_PutParamGrpTypCod (&Gbl.Crs.Grps.GrpTypes.LstGrpTypes[NumGrpTyp].GrpTypCod);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"name=\"MandatoryEnrolment\""
@ -1293,7 +1293,7 @@ static void Grp_ListGroupTypesForEdition (void)
/* Is it possible to register in multiple groups? */
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActChgMulGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Frm_BeginFormAnchor (ActChgMulGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Grp_PutParamGrpTypCod (&Gbl.Crs.Grps.GrpTypes.LstGrpTypes[NumGrpTyp].GrpTypCod);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"name=\"MultipleEnrolment\""
@ -1310,7 +1310,7 @@ static void Grp_ListGroupTypesForEdition (void)
/* Open time */
HTM_TD_Begin ("class=\"LM\"");
Frm_StartFormAnchor (ActChgTimGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Frm_BeginFormAnchor (ActChgTimGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Grp_PutParamGrpTypCod (&Gbl.Crs.Grps.GrpTypes.LstGrpTypes[NumGrpTyp].GrpTypCod);
HTM_TABLE_BeginCenterPadding (2);
HTM_TR_Begin (NULL);
@ -1460,7 +1460,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Icon to open/close group *****/
HTM_TD_Begin ("class=\"BM\"");
Frm_StartFormAnchor (Grp->Open ? ActCloGrp :
Frm_BeginFormAnchor (Grp->Open ? ActCloGrp :
ActOpeGrp,
Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
@ -1475,7 +1475,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Icon to activate file zones for this group *****/
HTM_TD_Begin ("class=\"BM\"");
Frm_StartFormAnchor (Grp->FileZones ? ActDisFilZonGrp :
Frm_BeginFormAnchor (Grp->FileZones ? ActDisFilZonGrp :
ActEnaFilZonGrp,
Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
@ -1491,7 +1491,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Group type *****/
/* Start selector */
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActChgGrpTyp,Grp_GROUPS_SECTION_ID);
Frm_BeginFormAnchor (ActChgGrpTyp,Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"name=\"GrpTypCod\" style=\"width:100px;\"");
@ -1514,7 +1514,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Group name *****/
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActRenGrp,Grp_GROUPS_SECTION_ID);
Frm_BeginFormAnchor (ActRenGrp,Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
HTM_INPUT_TEXT ("GrpName",Grp_MAX_CHARS_GROUP_NAME,Grp->GrpName,
HTM_SUBMIT_ON_CHANGE,
@ -1525,7 +1525,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Room *****/
/* Start selector */
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActChgGrpRoo,Grp_GROUPS_SECTION_ID);
Frm_BeginFormAnchor (ActChgGrpRoo,Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"name=\"RooCod\" style=\"width:100px;\"");
@ -1565,7 +1565,7 @@ static void Grp_ListGroupsForEdition (const struct Roo_Rooms *Rooms)
/***** Maximum number of students of the group (row[3]) *****/
HTM_TD_Begin ("class=\"CM\"");
Frm_StartFormAnchor (ActChgMaxStdGrp,Grp_GROUPS_SECTION_ID);
Frm_BeginFormAnchor (ActChgMaxStdGrp,Grp_GROUPS_SECTION_ID);
Grp_PutParamGrpCod (&Grp->GrpCod);
Grp_WriteMaxStds (StrMaxStudents,Grp->MaxStudents);
HTM_INPUT_TEXT ("MaxStudents",Cns_MAX_DECIMAL_DIGITS_UINT,StrMaxStudents,
@ -2415,7 +2415,7 @@ static void Grp_PutFormToCreateGroupType (void)
HTM_SECTION_Begin (Grp_NEW_GROUP_TYPE_SECTION_ID);
/***** Begin form *****/
Frm_StartFormAnchor (ActNewGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
Frm_BeginFormAnchor (ActNewGrpTyp,Grp_GROUP_TYPES_SECTION_ID);
/***** Begin box *****/
Box_BoxTableBegin (NULL,Txt_New_type_of_group,
@ -2530,7 +2530,7 @@ static void Grp_PutFormToCreateGroup (const struct Roo_Rooms *Rooms)
HTM_SECTION_Begin (Grp_NEW_GROUP_SECTION_ID);
/***** Begin form *****/
Frm_StartFormAnchor (ActNewGrp,Grp_GROUPS_SECTION_ID);
Frm_BeginFormAnchor (ActNewGrp,Grp_GROUPS_SECTION_ID);
/***** Begin box and table *****/
Box_BoxTableBegin (NULL,Txt_New_group,

View File

@ -1453,7 +1453,7 @@ void Ind_ComputeAndStoreIndicatorsCrs (long CrsCod,int NumIndicatorsFromDB,
/***** Indicator #3: information about online tutoring *****/
IndicatorsCrs->NumThreads = For_DB_GetNumTotalThrsInForumsOfType (For_FORUM_COURSE_USRS,-1L,-1L,-1L,-1L,CrsCod);
IndicatorsCrs->NumPosts = For_GetNumTotalPstsInForumsOfType (For_FORUM_COURSE_USRS,-1L,-1L,-1L,-1L,CrsCod,&(IndicatorsCrs->NumUsrsToBeNotifiedByEMail));
IndicatorsCrs->NumMsgsSentByTchs = Msg_GetNumMsgsSentByTchsCrs (CrsCod);
IndicatorsCrs->NumMsgsSentByTchs = Msg_DB_GetNumMsgsSentByTchsCrs (CrsCod);
IndicatorsCrs->ThereIsOnlineTutoring = (IndicatorsCrs->NumThreads != 0) ||
(IndicatorsCrs->NumPosts != 0) ||
(IndicatorsCrs->NumMsgsSentByTchs != 0);

View File

@ -1233,7 +1233,7 @@ void Lay_PutContextualLinkOnlyIcon (Act_Action_t NextAction,const char *Anchor,
const char *Title)
{
/***** Begin form *****/
Frm_StartFormAnchor (NextAction,Anchor);
Frm_BeginFormAnchor (NextAction,Anchor);
if (FuncParams)
FuncParams (Args);
@ -1260,7 +1260,7 @@ void Lay_PutContextualLinkIconText (Act_Action_t NextAction,const char *Anchor,
// jumping to the next line on narrow screens
/***** Begin form *****/
Frm_StartFormAnchor (NextAction,Anchor);
Frm_BeginFormAnchor (NextAction,Anchor);
if (FuncParams)
FuncParams (Args);
@ -1294,7 +1294,7 @@ void Lay_PutContextualLinkIconTextOnSubmit (Act_Action_t NextAction,const char *
// jumping to the next line on narrow screens
/***** Begin form *****/
Frm_StartFormAnchor (NextAction,Anchor);
Frm_BeginFormAnchor (NextAction,Anchor);
if (FuncParams)
FuncParams (Args);

View File

@ -1323,7 +1323,7 @@ static void Mai_ShowFormChangeUsrEmail (bool ItsMe,
{
HTM_BR ();
if (ItsMe)
Frm_StartFormAnchor (ActChgMyMai,Mai_EMAIL_SECTION_ID);
Frm_BeginFormAnchor (ActChgMyMai,Mai_EMAIL_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
@ -1339,7 +1339,7 @@ static void Mai_ShowFormChangeUsrEmail (bool ItsMe,
NextAction = ActNewMaiOth;
break;
}
Frm_StartFormAnchor (NextAction,Mai_EMAIL_SECTION_ID);
Frm_BeginFormAnchor (NextAction,Mai_EMAIL_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
Par_PutHiddenParamString (NULL,"NewEmail",row[0]);
@ -1369,7 +1369,7 @@ static void Mai_ShowFormChangeUsrEmail (bool ItsMe,
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
if (ItsMe)
Frm_StartFormAnchor (ActChgMyMai,Mai_EMAIL_SECTION_ID);
Frm_BeginFormAnchor (ActChgMyMai,Mai_EMAIL_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
@ -1385,7 +1385,7 @@ static void Mai_ShowFormChangeUsrEmail (bool ItsMe,
NextAction = ActNewMaiOth;
break;
}
Frm_StartFormAnchor (NextAction,Mai_EMAIL_SECTION_ID);
Frm_BeginFormAnchor (NextAction,Mai_EMAIL_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
HTM_INPUT_EMAIL ("NewEmail",Cns_MAX_CHARS_EMAIL_ADDRESS,Gbl.Usrs.Me.UsrDat.Email,

View File

@ -1460,7 +1460,7 @@ static void Mch_PutFormExistingMatch (struct Gam_Games *Games,
extern const char *Txt_Save_changes;
/***** Begin form *****/
Frm_StartFormAnchor (ActChgMch,Anchor);
Frm_BeginFormAnchor (ActChgMch,Anchor);
Mch_PutParamsEdit (Games);
/***** Begin box and table *****/

View File

@ -594,7 +594,7 @@ static void MchRes_ListGamesToSelect (struct Gam_Games *Games)
/***** Begin form to update the results
depending on the games selected *****/
Frm_StartFormAnchor (Gbl.Action.Act,MchRes_RESULTS_TABLE_ID);
Frm_BeginFormAnchor (Gbl.Action.Act,MchRes_RESULTS_TABLE_ID);
Grp_PutParamsCodGrps ();
Usr_PutHiddenParSelectedUsrsCods (&Gbl.Usrs.Selected);

File diff suppressed because it is too large Load Diff

View File

@ -101,7 +101,7 @@ void Msg_ExpSntMsg (void);
void Msg_ExpRecMsg (void);
void Msg_ConSntMsg (void);
void Msg_ConRecMsg (void);
void Msg_SetReceivedMsgAsOpen (long MsgCod,long UsrCod);
void Msg_DB_SetReceivedMsgAsOpen (long MsgCod,long UsrCod);
void Msg_DelAllRecAndSntMsgsUsr (long UsrCod);
void Msg_MoveUnusedMsgsContentToDeleted (void);
@ -109,8 +109,8 @@ void Msg_MoveUnusedMsgsContentToDeleted (void);
void Msg_ShowSntMsgs (void);
void Msg_ShowRecMsgs (void);
unsigned Msg_GetNumMsgsSentByTchsCrs (long CrsCod);
unsigned Msg_GetNumMsgsSentByUsr (long UsrCod);
unsigned Msg_DB_GetNumMsgsSentByTchsCrs (long CrsCod);
unsigned Msg_DB_GetNumMsgsSentByUsr (long UsrCod);
unsigned Msg_GetNumMsgsSent (HieLvl_Level_t Scope,Msg_Status_t MsgStatus);
unsigned Msg_GetNumMsgsReceived (HieLvl_Level_t Scope,Msg_Status_t MsgStatus);
@ -128,7 +128,7 @@ void Msg_PutHiddenParamMsgCod (long MsgCod);
void Msg_BanSenderWhenShowingMsgs (void);
void Msg_UnbanSenderWhenShowingMsgs (void);
void Msg_UnbanSenderWhenListingUsrs (void);
bool Msg_CheckIfUsrIsBanned (long FromUsrCod,long ToUsrCod);
bool Msg_DB_CheckIfUsrIsBanned (long FromUsrCod,long ToUsrCod);
void Msg_DB_RemoveUsrFromBanned (long UsrCod);
void Msg_ListBannedUsrs (void);

View File

@ -214,30 +214,30 @@ void Net_ShowWebsAndSocialNets (const struct UsrData *UsrDat)
/***** Begin container *****/
HTM_DIV_Begin ("class=\"REC_WEBS\"");
/***** Show link to public profile *****/
Net_ShowAWebOrSocialNet (Prf_GetURLPublicProfile (URL,UsrDat->Nickname),
"swad64x64.png",Cfg_PLATFORM_SHORT_NAME);
/***** Show link to public profile *****/
Net_ShowAWebOrSocialNet (Prf_GetURLPublicProfile (URL,UsrDat->Nickname),
"swad64x64.png",Cfg_PLATFORM_SHORT_NAME);
/***** Show the rest of webs / social networks *****/
for (NumURL = (Net_WebsAndSocialNetworks_t) 0;
NumURL <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
NumURL++)
{
/***** Check if exists the web / social network for this user *****/
DB_QuerySELECTString (URL,sizeof (URL) - 1,
"can not get user's web / social network",
"SELECT URL" // row[0]
" FROM usr_webs"
" WHERE UsrCod=%ld"
" AND Web='%s'",
UsrDat->UsrCod,
Net_WebsAndSocialNetworksDB[NumURL]);
if (URL[0])
/* Show the web / social network */
Net_ShowAWebOrSocialNet (URL,
Net_WebsAndSocialNetworksIcons[NumURL],
Net_WebsAndSocialNetworksTitle[NumURL]);
}
/***** Show the rest of webs / social networks *****/
for (NumURL = (Net_WebsAndSocialNetworks_t) 0;
NumURL <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
NumURL++)
{
/***** Check if exists the web / social network for this user *****/
DB_QuerySELECTString (URL,sizeof (URL) - 1,
"can not get user's web / social network",
"SELECT URL" // row[0]
" FROM usr_webs"
" WHERE UsrCod=%ld"
" AND Web='%s'",
UsrDat->UsrCod,
Net_WebsAndSocialNetworksDB[NumURL]);
if (URL[0])
/* Show the web / social network */
Net_ShowAWebOrSocialNet (URL,
Net_WebsAndSocialNetworksIcons[NumURL],
Net_WebsAndSocialNetworksTitle[NumURL]);
}
/***** End container *****/
HTM_DIV_End ();
@ -252,9 +252,9 @@ static void Net_ShowAWebOrSocialNet (const char *URL,
{
/***** Write link and icon *****/
HTM_DIV_Begin ("class=\"ICO_HIGHLIGHT\" style=\"display:inline;\"");
HTM_A_Begin ("href=\"%s\" target=\"_blank\" title=\"%s\"",URL,Title);
Ico_PutIcon (Icon,Title,"ICO16x16");
HTM_A_End ();
HTM_A_Begin ("href=\"%s\" target=\"_blank\" title=\"%s\"",URL,Title);
Ico_PutIcon (Icon,Title,"ICO16x16");
HTM_A_End ();
HTM_DIV_End ();
}
@ -276,65 +276,65 @@ void Net_ShowFormMyWebsAndSocialNets (void)
/***** Begin section *****/
HTM_SECTION_Begin (Net_MY_WEBS_ID);
/***** Begin box *****/
snprintf (StrRecordWidth,sizeof (StrRecordWidth),"%upx",Rec_RECORD_WIDTH);
Box_BoxBegin (StrRecordWidth,Txt_Webs_social_networks,
Net_PutIconsWebsSocialNetworks,NULL,
Hlp_PROFILE_Webs,Box_NOT_CLOSABLE);
/***** Begin box *****/
snprintf (StrRecordWidth,sizeof (StrRecordWidth),"%upx",Rec_RECORD_WIDTH);
Box_BoxBegin (StrRecordWidth,Txt_Webs_social_networks,
Net_PutIconsWebsSocialNetworks,NULL,
Hlp_PROFILE_Webs,Box_NOT_CLOSABLE);
/***** Begin table *****/
HTM_TABLE_BeginPadding (2);
/***** Begin form *****/
Frm_BeginFormAnchor (ActChgMyNet,Net_MY_WEBS_ID);
/***** Begin form *****/
Frm_StartFormAnchor (ActChgMyNet,Net_MY_WEBS_ID);
/***** Begin table *****/
HTM_TABLE_BeginPadding (2);
/***** List webs and social networks *****/
for (NumURL = (Net_WebsAndSocialNetworks_t) 0;
NumURL <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
NumURL++)
{
/***** Get user's web / social network from database *****/
DB_QuerySELECTString (URL,sizeof (URL) - 1,
"can not get user's web / social network",
"SELECT URL" // row[0]
" FROM usr_webs"
" WHERE UsrCod=%ld"
" AND Web='%s'",
Gbl.Usrs.Me.UsrDat.UsrCod,
Net_WebsAndSocialNetworksDB[NumURL]);
/***** List webs and social networks *****/
for (NumURL = (Net_WebsAndSocialNetworks_t) 0;
NumURL <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
NumURL++)
{
/***** Get user's web / social network from database *****/
DB_QuerySELECTString (URL,sizeof (URL) - 1,
"can not get user's web / social network",
"SELECT URL" // row[0]
" FROM usr_webs"
" WHERE UsrCod=%ld"
" AND Web='%s'",
Gbl.Usrs.Me.UsrDat.UsrCod,
Net_WebsAndSocialNetworksDB[NumURL]);
/***** Row for this web / social network *****/
snprintf (StrName,sizeof (StrName),"URL%u",(unsigned) NumURL);
HTM_TR_Begin (NULL);
/***** Row for this web / social network *****/
snprintf (StrName,sizeof (StrName),"URL%u",(unsigned) NumURL);
HTM_TR_Begin (NULL);
HTM_TD_Begin ("class=\"REC_C1_BOT LM\"");
HTM_LABEL_Begin ("for=\"%s\" class=\"%s\"",
StrName,The_ClassFormInBox[Gbl.Prefs.Theme]);
HTM_IMG (Cfg_URL_ICON_PUBLIC,Net_WebsAndSocialNetworksIcons[NumURL],Net_WebsAndSocialNetworksTitle[NumURL],
"class=\"CONTEXT_ICO_16x16\" style=\"margin-right:6px;\"");
HTM_TxtColon (Net_WebsAndSocialNetworksTitle[NumURL]);
HTM_LABEL_End ();
HTM_TD_End ();
HTM_TD_Begin ("class=\"REC_C1_BOT LM\"");
HTM_LABEL_Begin ("for=\"%s\" class=\"%s\"",
StrName,The_ClassFormInBox[Gbl.Prefs.Theme]);
HTM_IMG (Cfg_URL_ICON_PUBLIC,Net_WebsAndSocialNetworksIcons[NumURL],Net_WebsAndSocialNetworksTitle[NumURL],
"class=\"CONTEXT_ICO_16x16\" style=\"margin-right:6px;\"");
HTM_TxtColon (Net_WebsAndSocialNetworksTitle[NumURL]);
HTM_LABEL_End ();
HTM_TD_End ();
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
HTM_INPUT_URL (StrName,URL,HTM_DONT_SUBMIT_ON_CHANGE,
"id=\"%s\" class=\"REC_C2_BOT_INPUT\"",StrName);
HTM_TD_End ();
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
HTM_INPUT_URL (StrName,URL,HTM_DONT_SUBMIT_ON_CHANGE,
"id=\"%s\" class=\"REC_C2_BOT_INPUT\"",StrName);
HTM_TD_End ();
HTM_TR_End ();
}
HTM_TR_End ();
}
/***** End table *****/
HTM_TABLE_End ();
/***** End table *****/
HTM_TABLE_End ();
/***** Confirm button *****/
Btn_PutConfirmButton (Txt_Save_changes);
/***** Confirm button *****/
Btn_PutConfirmButton (Txt_Save_changes);
/***** End form *****/
Frm_EndForm ();
/***** End form *****/
Frm_EndForm ();
/***** End box *****/
Box_BoxEnd ();
/***** End box *****/
Box_BoxEnd ();
/***** End section *****/
HTM_SECTION_End ();
@ -545,57 +545,55 @@ void Net_ShowWebAndSocialNetworksStats (void)
NULL,NULL,
Hlp_ANALYTICS_Figures_webs_social_networks,Box_NOT_CLOSABLE,2);
/***** Write heading *****/
HTM_TR_Begin (NULL);
/***** Write heading *****/
HTM_TR_Begin (NULL);
HTM_TH (1,1,"LM",Txt_Web_social_network);
HTM_TH (1,1,"RM",Txt_Number_of_users);
HTM_TH (1,1,"RM",Txt_PERCENT_of_users);
HTM_TR_End ();
HTM_TH (1,1,"LM",Txt_Web_social_network);
HTM_TH (1,1,"RM",Txt_Number_of_users);
HTM_TH (1,1,"RM",Txt_PERCENT_of_users);
HTM_TR_End ();
/***** For each web / social network... *****/
for (NumRow = 0;
NumRow < NumRows;
NumRow++)
{
/* Get row */
row = mysql_fetch_row (mysql_res);
/* Get web / social network (row[0]) */
Str_Copy (NetName,row[0],sizeof (NetName) - 1);
for (Web = (Net_WebsAndSocialNetworks_t) 0;
Web <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
Web++)
if (!strcmp (Net_WebsAndSocialNetworksDB[Web],NetName))
break;
if (Web < Net_NUM_WEBS_AND_SOCIAL_NETWORKS)
/***** For each web / social network... *****/
for (NumRow = 0;
NumRow < NumRows;
NumRow++)
{
/* Get number of users (row[1]) */
if (sscanf (row[1],"%u",&NumUsrs) != 1)
Err_ShowErrorAndExit ("Error when getting number of files.");
/* Get row */
row = mysql_fetch_row (mysql_res);
HTM_TR_Begin (NULL);
/* Get web / social network (row[0]) */
Str_Copy (NetName,row[0],sizeof (NetName) - 1);
for (Web = (Net_WebsAndSocialNetworks_t) 0;
Web <= (Net_WebsAndSocialNetworks_t) (Net_NUM_WEBS_AND_SOCIAL_NETWORKS - 1);
Web++)
if (!strcmp (Net_WebsAndSocialNetworksDB[Web],NetName))
break;
if (Web < Net_NUM_WEBS_AND_SOCIAL_NETWORKS)
{
/* Get number of users (row[1]) */
if (sscanf (row[1],"%u",&NumUsrs) != 1)
Err_ShowErrorAndExit ("Error when getting number of files.");
HTM_TD_Begin ("class=\"DAT LM\"");
HTM_IMG (Cfg_URL_ICON_PUBLIC,Net_WebsAndSocialNetworksIcons[Web],Net_WebsAndSocialNetworksTitle[Web],
"class=\"CONTEXT_ICO_16x16\" style=\"margin-right:6px;\"");
HTM_Txt (Net_WebsAndSocialNetworksTitle[Web]);
HTM_TD_End ();
HTM_TR_Begin (NULL);
HTM_TD_Begin ("class=\"DAT RM\"");
HTM_Unsigned (NumUsrs);
HTM_TD_End ();
HTM_TD_Begin ("class=\"DAT LM\"");
HTM_IMG (Cfg_URL_ICON_PUBLIC,Net_WebsAndSocialNetworksIcons[Web],Net_WebsAndSocialNetworksTitle[Web],
"class=\"CONTEXT_ICO_16x16\" style=\"margin-right:6px;\"");
HTM_Txt (Net_WebsAndSocialNetworksTitle[Web]);
HTM_TD_End ();
HTM_TD_Begin ("class=\"DAT RM\"");
HTM_Percentage (NumUsrsTotal ? 100.0 * (double) NumUsrs /
(double) NumUsrsTotal :
0.0);
HTM_TD_End ();
HTM_TD_Begin ("class=\"DAT RM\"");
HTM_Unsigned (NumUsrs);
HTM_TD_End ();
HTM_TR_End ();
HTM_TD_Begin ("class=\"DAT RM\"");
HTM_Percentage (NumUsrsTotal ? 100.0 * (double) NumUsrs /
(double) NumUsrsTotal :
0.0);
HTM_TD_End ();
HTM_TR_End ();
}
}
}
/***** End table and box *****/
Box_BoxTableEnd ();

View File

@ -66,7 +66,7 @@ static void Nck_ShowFormChangeUsrNickname (bool ItsMe,
static void Nck_PutParamsRemoveMyNick (void *Nick);
static void Nck_PutParamsRemoveOtherNick (void *Nick);
static void Nck_RemoveNicknameFromDB (long UsrCod,const char *Nickname);
static void Nck_DB_RemoveNickname (long UsrCod,const char *Nickname);
static void Nck_UpdateUsrNick (struct UsrData *UsrDat);
@ -112,8 +112,8 @@ bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr)
/************* Get nickname of a user from his/her user's code ***************/
/*****************************************************************************/
void Nck_GetNicknameFromUsrCod (long UsrCod,
char Nickname[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1])
void Nck_DB_GetNicknameFromUsrCod (long UsrCod,
char Nickname[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1])
{
/***** Get current (last updated) user's nickname from database *****/
DB_QuerySELECTString (Nickname,Nck_MAX_BYTES_NICK_WITHOUT_ARROBA,
@ -207,181 +207,181 @@ static void Nck_ShowFormChangeUsrNickname (bool ItsMe,
/***** Begin section *****/
HTM_SECTION_Begin (Nck_NICKNAME_SECTION_ID);
/***** Get my nicknames *****/
NumNicks = (unsigned)
DB_QuerySELECT (&mysql_res,"can not get nicknames of a user",
"SELECT Nickname" // row[0]
" FROM usr_nicknames"
" WHERE UsrCod=%ld"
" ORDER BY CreatTime DESC",
UsrDat->UsrCod);
/***** Get my nicknames *****/
NumNicks = (unsigned)
DB_QuerySELECT (&mysql_res,"can not get nicknames of a user",
"SELECT Nickname" // row[0]
" FROM usr_nicknames"
" WHERE UsrCod=%ld"
" ORDER BY CreatTime DESC",
UsrDat->UsrCod);
/***** Begin box *****/
snprintf (StrRecordWidth,sizeof (StrRecordWidth),"%upx",Rec_RECORD_WIDTH);
Box_BoxBegin (StrRecordWidth,Txt_Nickname,
Acc_PutLinkToRemoveMyAccount,NULL,
Hlp_PROFILE_Account,Box_NOT_CLOSABLE);
/***** Begin box *****/
snprintf (StrRecordWidth,sizeof (StrRecordWidth),"%upx",Rec_RECORD_WIDTH);
Box_BoxBegin (StrRecordWidth,Txt_Nickname,
Acc_PutLinkToRemoveMyAccount,NULL,
Hlp_PROFILE_Account,Box_NOT_CLOSABLE);
/***** Show possible alerts *****/
Ale_ShowAlerts (Nck_NICKNAME_SECTION_ID);
/***** Show possible alerts *****/
Ale_ShowAlerts (Nck_NICKNAME_SECTION_ID);
/***** Help message *****/
if (IMustFillNickname)
Ale_ShowAlert (Ale_WARNING,Txt_Before_going_to_any_other_option_you_must_fill_your_nickname);
/***** Help message *****/
if (IMustFillNickname)
Ale_ShowAlert (Ale_WARNING,Txt_Before_going_to_any_other_option_you_must_fill_your_nickname);
/***** Begin table *****/
HTM_TABLE_BeginWidePadding (2);
/***** Begin table *****/
HTM_TABLE_BeginWidePadding (2);
/***** List nicknames *****/
for (NumNick = 1;
NumNick <= NumNicks;
NumNick++)
{
/* Get nickname */
row = mysql_fetch_row (mysql_res);
if (NumNick == 1)
{
/* The first nickname is the current one */
HTM_TR_Begin (NULL);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT",NULL,Txt_Current_nickname);
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT USR_ID\"");
}
else // NumNick >= 2
{
if (NumNick == 2)
{
HTM_TR_Begin (NULL);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT",NULL,Txt_Other_nicknames);
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
}
/* Form to remove old nickname */
if (ItsMe)
Ico_PutContextualIconToRemove (ActRemMyNck,Nck_NICKNAME_SECTION_ID,
Nck_PutParamsRemoveMyNick,row[0]);
else
{
switch (UsrDat->Roles.InCurrentCrs)
/***** List nicknames *****/
for (NumNick = 1;
NumNick <= NumNicks;
NumNick++)
{
case Rol_STD:
NextAction = ActRemOldNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActRemOldNicTch;
break;
default: // Guest, user or admin
NextAction = ActRemOldNicOth;
break;
/* Get nickname */
row = mysql_fetch_row (mysql_res);
if (NumNick == 1)
{
/* The first nickname is the current one */
HTM_TR_Begin (NULL);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT",NULL,Txt_Current_nickname);
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT USR_ID\"");
}
else // NumNick >= 2
{
if (NumNick == 2)
{
HTM_TR_Begin (NULL);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT",NULL,Txt_Other_nicknames);
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
}
/* Form to remove old nickname */
if (ItsMe)
Ico_PutContextualIconToRemove (ActRemMyNck,Nck_NICKNAME_SECTION_ID,
Nck_PutParamsRemoveMyNick,row[0]);
else
{
switch (UsrDat->Roles.InCurrentCrs)
{
case Rol_STD:
NextAction = ActRemOldNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActRemOldNicTch;
break;
default: // Guest, user or admin
NextAction = ActRemOldNicOth;
break;
}
Ico_PutContextualIconToRemove (NextAction,Nck_NICKNAME_SECTION_ID,
Nck_PutParamsRemoveOtherNick,row[0]);
}
}
/* Nickname */
HTM_TxtF ("@%s",row[0]);
/* Link to QR code */
if (NumNick == 1 && UsrDat->Nickname[0])
QR_PutLinkToPrintQRCode (ActPrnUsrQR,
Usr_PutParamMyUsrCodEncrypted,Gbl.Usrs.Me.UsrDat.EnUsrCod);
/* Form to change the nickname */
if (NumNick > 1)
{
HTM_BR ();
if (ItsMe)
Frm_BeginFormAnchor (ActChgMyNck,Nck_NICKNAME_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
{
case Rol_STD:
NextAction = ActChgNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActChgNicTch;
break;
default: // Guest, user or admin
NextAction = ActChgNicOth;
break;
}
Frm_BeginFormAnchor (NextAction,Nck_NICKNAME_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
snprintf (NickWithArr,sizeof (NickWithArr),"@%s",row[0]);
Par_PutHiddenParamString (NULL,"NewNick",NickWithArr); // Nickname
Btn_PutConfirmButtonInline (Txt_Use_this_nickname);
Frm_EndForm ();
}
if (NumNick == 1 ||
NumNick == NumNicks)
{
HTM_TD_End ();
HTM_TR_End ();
}
else
HTM_BR ();
}
Ico_PutContextualIconToRemove (NextAction,Nck_NICKNAME_SECTION_ID,
Nck_PutParamsRemoveOtherNick,row[0]);
}
}
/* Nickname */
HTM_TxtF ("@%s",row[0]);
/***** Form to enter new nickname *****/
HTM_TR_Begin (NULL);
/* Link to QR code */
if (NumNick == 1 && UsrDat->Nickname[0])
QR_PutLinkToPrintQRCode (ActPrnUsrQR,
Usr_PutParamMyUsrCodEncrypted,Gbl.Usrs.Me.UsrDat.EnUsrCod);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT","NewNick",
NumNicks ? Txt_New_nickname : // A new nickname
Txt_Nickname); // The first nickname
/* Form to change the nickname */
if (NumNick > 1)
{
HTM_BR ();
if (ItsMe)
Frm_StartFormAnchor (ActChgMyNck,Nck_NICKNAME_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
{
case Rol_STD:
NextAction = ActChgNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActChgNicTch;
break;
default: // Guest, user or admin
NextAction = ActChgNicOth;
break;
}
Frm_StartFormAnchor (NextAction,Nck_NICKNAME_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
if (ItsMe)
Frm_BeginFormAnchor (ActChgMyNck,Nck_NICKNAME_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
{
case Rol_STD:
NextAction = ActChgNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActChgNicTch;
break;
default: // Guest, user or admin
NextAction = ActChgNicOth;
break;
}
Frm_BeginFormAnchor (NextAction,Nck_NICKNAME_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
snprintf (NickWithArr,sizeof (NickWithArr),"@%s",
Gbl.Usrs.Me.UsrDat.Nickname);
HTM_INPUT_TEXT ("NewNick",1 + Nck_MAX_CHARS_NICK_WITHOUT_ARROBA,
NickWithArr,HTM_DONT_SUBMIT_ON_CHANGE,
"id=\"NewNick\" size=\"18\"");
HTM_BR ();
Btn_PutCreateButtonInline (NumNicks ? Txt_Change_nickname : // I already have a nickname
Txt_Save_changes); // I have no nickname yet);
Frm_EndForm ();
HTM_TD_End ();
snprintf (NickWithArr,sizeof (NickWithArr),"@%s",row[0]);
Par_PutHiddenParamString (NULL,"NewNick",NickWithArr); // Nickname
Btn_PutConfirmButtonInline (Txt_Use_this_nickname);
Frm_EndForm ();
}
HTM_TR_End ();
if (NumNick == 1 ||
NumNick == NumNicks)
{
HTM_TD_End ();
HTM_TR_End ();
}
else
HTM_BR ();
}
/***** Form to enter new nickname *****/
HTM_TR_Begin (NULL);
/* Label */
Frm_LabelColumn ("REC_C1_BOT RT","NewNick",
NumNicks ? Txt_New_nickname : // A new nickname
Txt_Nickname); // The first nickname
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LT DAT\"");
if (ItsMe)
Frm_StartFormAnchor (ActChgMyNck,Nck_NICKNAME_SECTION_ID);
else
{
switch (UsrDat->Roles.InCurrentCrs)
{
case Rol_STD:
NextAction = ActChgNicStd;
break;
case Rol_NET:
case Rol_TCH:
NextAction = ActChgNicTch;
break;
default: // Guest, user or admin
NextAction = ActChgNicOth;
break;
}
Frm_StartFormAnchor (NextAction,Nck_NICKNAME_SECTION_ID);
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
}
snprintf (NickWithArr,sizeof (NickWithArr),"@%s",
Gbl.Usrs.Me.UsrDat.Nickname);
HTM_INPUT_TEXT ("NewNick",1 + Nck_MAX_CHARS_NICK_WITHOUT_ARROBA,
NickWithArr,HTM_DONT_SUBMIT_ON_CHANGE,
"id=\"NewNick\" size=\"18\"");
HTM_BR ();
Btn_PutCreateButtonInline (NumNicks ? Txt_Change_nickname : // I already have a nickname
Txt_Save_changes); // I have no nickname yet);
Frm_EndForm ();
HTM_TD_End ();
HTM_TR_End ();
/***** End table and box *****/
Box_BoxTableEnd ();
/***** End table and box *****/
Box_BoxTableEnd ();
/***** End section *****/
HTM_SECTION_End ();
@ -419,7 +419,7 @@ void Nck_RemoveMyNick (void)
if (strcasecmp (NickWithoutArr,Gbl.Usrs.Me.UsrDat.Nickname)) // Only if not my current nickname
{
/***** Remove one of my old nicknames *****/
Nck_RemoveNicknameFromDB (Gbl.Usrs.Me.UsrDat.UsrCod,NickWithoutArr);
Nck_DB_RemoveNickname (Gbl.Usrs.Me.UsrDat.UsrCod,NickWithoutArr);
/***** Show message *****/
Ale_CreateAlert (Ale_SUCCESS,Nck_NICKNAME_SECTION_ID,
@ -453,7 +453,7 @@ void Nck_RemoveOtherUsrNick (void)
Nck_MAX_BYTES_NICK_WITHOUT_ARROBA);
/***** Remove one of the old nicknames *****/
Nck_RemoveNicknameFromDB (Gbl.Usrs.Other.UsrDat.UsrCod,NickWithoutArr);
Nck_DB_RemoveNickname (Gbl.Usrs.Other.UsrDat.UsrCod,NickWithoutArr);
/***** Show message *****/
Ale_CreateAlert (Ale_SUCCESS,Nck_NICKNAME_SECTION_ID,
@ -474,7 +474,7 @@ void Nck_RemoveOtherUsrNick (void)
/********************** Remove a nickname from database **********************/
/*****************************************************************************/
static void Nck_RemoveNicknameFromDB (long UsrCod,const char *Nickname)
static void Nck_DB_RemoveNickname (long UsrCod,const char *Nickname)
{
/***** Remove a nickname *****/
DB_QueryREPLACE ("can not remove a nickname",
@ -587,7 +587,7 @@ static void Nck_UpdateUsrNick (struct UsrData *UsrDat)
{
// Now we know the new nickname is not already in database
// and is diffent to the current one
Nck_UpdateNickInDB (UsrDat->UsrCod,NewNickWithoutArr);
Nck_DB_UpdateNick (UsrDat->UsrCod,NewNickWithoutArr);
Str_Copy (UsrDat->Nickname,NewNickWithoutArr,sizeof (UsrDat->Nickname) - 1);
Ale_CreateAlert (Ale_SUCCESS,Nck_NICKNAME_SECTION_ID,
@ -607,7 +607,7 @@ static void Nck_UpdateUsrNick (struct UsrData *UsrDat)
/******************* Update user's nickname in database **********************/
/*****************************************************************************/
void Nck_UpdateNickInDB (long UsrCod,const char *NewNickname)
void Nck_DB_UpdateNick (long UsrCod,const char *NewNickname)
{
/***** Update user's nickname in database *****/
DB_QueryREPLACE ("can not update nickname",

View File

@ -48,8 +48,8 @@
bool Nck_CheckIfNickWithArrIsValid (const char *NickWithArr);
void Nck_GetNicknameFromUsrCod (long UsrCod,
char Nickname[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]);
void Nck_DB_GetNicknameFromUsrCod (long UsrCod,
char Nickname[Nck_MAX_BYTES_NICK_WITHOUT_ARROBA + 1]);
long Nck_GetUsrCodFromNickname (const char *Nickname);
void Nck_ShowFormChangeMyNickname (bool IMustFillNickname);
@ -62,6 +62,6 @@ void Nck_DB_RemoveUsrNicknames (long UsrCod);
void Nck_UpdateMyNick (void);
void Nck_UpdateOtherUsrNick (void);
void Nck_UpdateNickInDB (long UsrCod,const char *NewNickname);
void Nck_DB_UpdateNick (long UsrCod,const char *NewNickname);
#endif

View File

@ -86,8 +86,9 @@ static void Not_DrawANotice (Not_Listing_t TypeNoticesListing,
const char *Content,
long UsrCod,
Not_Status_t Status);
static long Not_InsertNoticeInDB (const char *Content);
static void Not_UpdateNumUsrsNotifiedByEMailAboutNotice (long NotCod,unsigned NumUsrsToBeNotifiedByEMail);
static long Not_DB_InsertNotice (const char *Content);
static void Not_DB_UpdateNumUsrsNotifiedByEMailAboutNotice (long NotCod,
unsigned NumUsrsToBeNotifiedByEMail);
static void Not_PutParams (void *NotCod);
static long Not_GetParamNotCod (void);
@ -109,18 +110,18 @@ void Not_ShowFormNotice (void)
/***** Begin form *****/
Frm_BeginForm (ActRcvNot);
/***** Begin box *****/
Box_BoxBegin (NULL,Txt_New_notice,
NULL,NULL,
Hlp_COMMUNICATION_Notices,Box_NOT_CLOSABLE);
/***** Begin box *****/
Box_BoxBegin (NULL,Txt_New_notice,
NULL,NULL,
Hlp_COMMUNICATION_Notices,Box_NOT_CLOSABLE);
/***** Message body *****/
HTM_TEXTAREA_Begin ("name=\"Content\" cols=\"30\" rows=\"10\""
" autofocus=\"autofocus\" required=\"required\"");
HTM_TEXTAREA_End ();
/***** Message body *****/
HTM_TEXTAREA_Begin ("name=\"Content\" cols=\"30\" rows=\"10\""
" autofocus=\"autofocus\" required=\"required\"");
HTM_TEXTAREA_End ();
/***** Send button and end box *****/
Box_BoxWithButtonEnd (Btn_CREATE_BUTTON,Txt_Create_notice);
/***** Send button and end box *****/
Box_BoxWithButtonEnd (Btn_CREATE_BUTTON,Txt_Create_notice);
/***** End form *****/
Frm_EndForm ();
@ -146,7 +147,7 @@ void Not_ReceiveNotice (void)
Str_TO_RIGOROUS_HTML,true);
/***** Create a new notice in database *****/
NotCod = Not_InsertNoticeInDB (Content);
NotCod = Not_DB_InsertNotice (Content);
/***** Update RSS of current course *****/
RSS_UpdateRSSFileForACrs (&Gbl.Hierarchy.Crs);
@ -156,7 +157,7 @@ void Not_ReceiveNotice (void)
/***** Notify by email about the new notice *****/
if ((NumUsrsToBeNotifiedByEMail = Ntf_StoreNotifyEventsToAllUsrs (Ntf_EVENT_NOTICE,NotCod)))
Not_UpdateNumUsrsNotifiedByEMailAboutNotice (NotCod,NumUsrsToBeNotifiedByEMail);
Not_DB_UpdateNumUsrsNotifiedByEMailAboutNotice (NotCod,NumUsrsToBeNotifiedByEMail);
/***** Create a new social note about the new notice *****/
Tml_Not_StoreAndPublishNote (TL_NOTE_NOTICE,NotCod);
@ -170,7 +171,7 @@ void Not_ReceiveNotice (void)
/*****************************************************************************/
// Return the code of the new inserted notice
static long Not_InsertNoticeInDB (const char *Content)
static long Not_DB_InsertNotice (const char *Content)
{
/***** Insert notice in the database *****/
return
@ -189,7 +190,8 @@ static long Not_InsertNoticeInDB (const char *Content)
/*********** Update number of users notified in table of notices *************/
/*****************************************************************************/
static void Not_UpdateNumUsrsNotifiedByEMailAboutNotice (long NotCod,unsigned NumUsrsToBeNotifiedByEMail)
static void Not_DB_UpdateNumUsrsNotifiedByEMailAboutNotice (long NotCod,
unsigned NumUsrsToBeNotifiedByEMail)
{
/***** Update number of users notified *****/
DB_QueryUPDATE ("can not update the number of notifications of a notice",
@ -359,7 +361,7 @@ void Not_RemoveNotice (void)
Gbl.Hierarchy.Crs.CrsCod);
/***** Mark possible notifications as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_NOTICE,NotCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_NOTICE,NotCod);
/***** Mark possible social note as unavailable *****/
Tml_DB_MarkNoteAsUnavailable (TL_NOTE_NOTICE,NotCod);
@ -570,7 +572,7 @@ static void Not_PutButtonToAddNewNotice (void)
extern const char *Txt_New_notice;
Frm_BeginForm (ActWriNot);
Btn_PutConfirmButton (Txt_New_notice);
Btn_PutConfirmButton (Txt_New_notice);
Frm_EndForm ();
}
@ -687,89 +689,89 @@ static void Not_DrawANotice (Not_Listing_t TypeNoticesListing,
HTM_DIV_Begin ("class=\"%s %s\"",
ContainerClass[Status],ContainerWidthClass[TypeNoticesListing]);
/***** Write the date in the top part of the yellow note *****/
/* Write symbol to indicate if notice is obsolete or active */
if (TypeNoticesListing == Not_LIST_FULL_NOTICES)
if (Not_CheckIfICanEditNotices ())
/***** Write the date in the top part of the yellow note *****/
/* Write symbol to indicate if notice is obsolete or active */
if (TypeNoticesListing == Not_LIST_FULL_NOTICES)
if (Not_CheckIfICanEditNotices ())
{
/***** Put form to remove announcement *****/
Ico_PutContextualIconToRemove (ActReqRemNot,NULL,
Not_PutParams,&NotCod);
/***** Put form to change the status of the notice *****/
switch (Status)
{
case Not_ACTIVE_NOTICE:
Ico_PutContextualIconToHide (ActHidNot,NULL,
Not_PutParams,&NotCod);
break;
case Not_OBSOLETE_NOTICE:
Ico_PutContextualIconToUnhide (ActRevNot,NULL,
Not_PutParams,&NotCod);
break;
}
Frm_EndForm ();
}
/* Write the date */
UniqueId++;
HTM_DIV_Begin ("class=\"%s\"",DateClass[Status]);
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
/* Form to view full notice */
Frm_BeginFormAnchor (ActSeeOneNot,Anchor);
Not_PutHiddenParamNotCod (NotCod);
HTM_BUTTON_SUBMIT_Begin (Txt_See_full_notice,"BT_LINK RT",NULL);
}
if (asprintf (&Id,"not_date_%u",UniqueId) < 0)
Err_NotEnoughMemoryExit ();
HTM_SPAN_Begin ("id=\"%s\"",Id);
HTM_SPAN_End ();
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
Dat_WriteLocalDateHMSFromUTC (Id,TimeUTC,
Gbl.Prefs.DateFormat,Dat_SEPARATOR_BREAK,
true,true,false,0x6);
free (Id);
HTM_DIV_End ();
/***** Write the content of the notice *****/
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
/***** Put form to remove announcement *****/
Ico_PutContextualIconToRemove (ActReqRemNot,NULL,
Not_PutParams,&NotCod);
HTM_DIV_Begin ("class=\"NOTICE_TEXT_BRIEF\"");
HTM_Txt (Content);
HTM_DIV_End ();
/***** Put form to change the status of the notice *****/
switch (Status)
{
case Not_ACTIVE_NOTICE:
Ico_PutContextualIconToHide (ActHidNot,NULL,
Not_PutParams,&NotCod);
break;
case Not_OBSOLETE_NOTICE:
Ico_PutContextualIconToUnhide (ActRevNot,NULL,
Not_PutParams,&NotCod);
break;
}
Frm_EndForm ();
}
/* Put form to view full notice */
HTM_DIV_Begin ("class=\"CM\"");
Lay_PutContextualLinkOnlyIcon (ActSeeOneNot,Anchor,
Not_PutParams,&NotCod,
"ellipsis-h.svg",
Txt_See_full_notice);
HTM_DIV_End ();
}
else
{
HTM_DIV_Begin ("class=\"%s\"",TextClass[Status]);
HTM_Txt (Content);
HTM_DIV_End ();
}
/* Write the date */
UniqueId++;
HTM_DIV_Begin ("class=\"%s\"",DateClass[Status]);
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
/* Form to view full notice */
Frm_StartFormAnchor (ActSeeOneNot,Anchor);
Not_PutHiddenParamNotCod (NotCod);
HTM_BUTTON_SUBMIT_Begin (Txt_See_full_notice,"BT_LINK RT",NULL);
}
if (asprintf (&Id,"not_date_%u",UniqueId) < 0)
Err_NotEnoughMemoryExit ();
HTM_SPAN_Begin ("id=\"%s\"",Id);
HTM_SPAN_End ();
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
Dat_WriteLocalDateHMSFromUTC (Id,TimeUTC,
Gbl.Prefs.DateFormat,Dat_SEPARATOR_BREAK,
true,true,false,0x6);
free (Id);
HTM_DIV_End ();
/***** Write the content of the notice *****/
if (TypeNoticesListing == Not_LIST_BRIEF_NOTICES)
{
HTM_DIV_Begin ("class=\"NOTICE_TEXT_BRIEF\"");
HTM_Txt (Content);
/***** Write the author *****/
HTM_DIV_Begin ("class=\"NOTICE_AUTHOR %s\"", // Limited width
AuthorClass[Status]);
Usr_UsrDataConstructor (&UsrDat);
UsrDat.UsrCod = UsrCod;
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat, // Get author's data from database
Usr_DONT_GET_PREFS,
Usr_DONT_GET_ROLE_IN_CURRENT_CRS))
Usr_WriteFirstNameBRSurnames (&UsrDat);
Usr_UsrDataDestructor (&UsrDat);
HTM_DIV_End ();
/* Put form to view full notice */
HTM_DIV_Begin ("class=\"CM\"");
Lay_PutContextualLinkOnlyIcon (ActSeeOneNot,Anchor,
Not_PutParams,&NotCod,
"ellipsis-h.svg",
Txt_See_full_notice);
HTM_DIV_End ();
}
else
{
HTM_DIV_Begin ("class=\"%s\"",TextClass[Status]);
HTM_Txt (Content);
HTM_DIV_End ();
}
/***** Write the author *****/
HTM_DIV_Begin ("class=\"NOTICE_AUTHOR %s\"", // Limited width
AuthorClass[Status]);
Usr_UsrDataConstructor (&UsrDat);
UsrDat.UsrCod = UsrCod;
if (Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat, // Get author's data from database
Usr_DONT_GET_PREFS,
Usr_DONT_GET_ROLE_IN_CURRENT_CRS))
Usr_WriteFirstNameBRSurnames (&UsrDat);
Usr_UsrDataDestructor (&UsrDat);
HTM_DIV_End ();
/***** End yellow note *****/
HTM_DIV_End ();

View File

@ -280,7 +280,7 @@ static bool Ntf_StartFormGoToAction (Ntf_NotifyEvent_t NotifyEvent,
const struct For_Forums *Forums);
static void Ntf_PutHiddenParamNotifyEvent (Ntf_NotifyEvent_t NotifyEvent);
static void Ntf_UpdateMyLastAccessToNotifications (void);
static void Ntf_DB_UpdateMyLastAccessToNotifications (void);
static void Ntf_SendPendingNotifByEMailToOneUsr (struct UsrData *ToUsrDat,unsigned *NumNotif,unsigned *NumMails);
static void Ntf_GetNumNotifSent (long DegCod,long CrsCod,
Ntf_NotifyEvent_t NotifyEvent,
@ -388,237 +388,237 @@ void Ntf_ShowMyNotifications (void)
Ntf_PutIconsNotif,NULL,
Hlp_START_Notifications,Box_NOT_CLOSABLE);
/***** List my notifications *****/
if (NumNotifications) // Notifications found
{
/***** Initialize structure with user's data *****/
Usr_UsrDataConstructor (&UsrDat);
/***** Begin table *****/
HTM_TABLE_BeginWideMarginPadding (2);
HTM_TR_Begin (NULL);
HTM_TH (1,2,"LM",Txt_Event);
HTM_TH (1,1,"LM",Txt_MSG_From);
HTM_TH (1,1,"LM",Txt_Location);
HTM_TH (1,1,"CM",Txt_Date);
HTM_TH (1,1,"LM",Txt_Email);
HTM_TR_End ();
/***** List notifications one by one *****/
for (NumNotif = 0;
NumNotif < NumNotifications;
NumNotif++)
/***** List my notifications *****/
if (NumNotifications) // Notifications found
{
/***** Get next notification *****/
row = mysql_fetch_row (mysql_res);
/***** Initialize structure with user's data *****/
Usr_UsrDataConstructor (&UsrDat);
/* Get event type (row[0]) */
NotifyEvent = Ntf_GetNotifyEventFromStr (row[0]);
/***** Begin table *****/
HTM_TABLE_BeginWideMarginPadding (2);
/* Get (from) user code (row[1]) */
UsrDat.UsrCod = Str_ConvertStrCodToLongCod (row[1]);
Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat, // Get user's data from database
Usr_DONT_GET_PREFS,
Usr_DONT_GET_ROLE_IN_CURRENT_CRS);
/***** Heading *****/
HTM_TR_Begin (NULL);
HTM_TH (1,2,"LM",Txt_Event);
HTM_TH (1,1,"LM",Txt_MSG_From);
HTM_TH (1,1,"LM",Txt_Location);
HTM_TH (1,1,"CM",Txt_Date);
HTM_TH (1,1,"LM",Txt_Email);
HTM_TR_End ();
/* Get institution code (row[2]) */
Hie.Ins.InsCod = Str_ConvertStrCodToLongCod (row[2]);
Ins_GetDataOfInstitutionByCod (&Hie.Ins);
/***** List notifications one by one *****/
for (NumNotif = 0;
NumNotif < NumNotifications;
NumNotif++)
{
/***** Get next notification *****/
row = mysql_fetch_row (mysql_res);
/* Get center code (row[3]) */
Hie.Ctr.CtrCod = Str_ConvertStrCodToLongCod (row[3]);
Ctr_GetDataOfCenterByCod (&Hie.Ctr);
/* Get event type (row[0]) */
NotifyEvent = Ntf_GetNotifyEventFromStr (row[0]);
/* Get degree code (row[4]) */
Hie.Deg.DegCod = Str_ConvertStrCodToLongCod (row[4]);
Deg_GetDataOfDegreeByCod (&Hie.Deg);
/* Get (from) user code (row[1]) */
UsrDat.UsrCod = Str_ConvertStrCodToLongCod (row[1]);
Usr_ChkUsrCodAndGetAllUsrDataFromUsrCod (&UsrDat, // Get user's data from database
Usr_DONT_GET_PREFS,
Usr_DONT_GET_ROLE_IN_CURRENT_CRS);
/* Get course code (row[5]) */
Hie.Crs.CrsCod = Str_ConvertStrCodToLongCod (row[5]);
Crs_GetDataOfCourseByCod (&Hie.Crs);
/* Get institution code (row[2]) */
Hie.Ins.InsCod = Str_ConvertStrCodToLongCod (row[2]);
Ins_GetDataOfInstitutionByCod (&Hie.Ins);
/* Get message/post/... code (row[6]) */
Cod = Str_ConvertStrCodToLongCod (row[6]);
/* Get center code (row[3]) */
Hie.Ctr.CtrCod = Str_ConvertStrCodToLongCod (row[3]);
Ctr_GetDataOfCenterByCod (&Hie.Ctr);
/* Get forum type of the post */
if (NotifyEvent == Ntf_EVENT_FORUM_POST_COURSE ||
NotifyEvent == Ntf_EVENT_FORUM_REPLY)
{
For_ResetForums (&Forums);
For_GetForumTypeAndLocationOfAPost (Cod,&Forums.Forum);
For_SetForumName (&Forums.Forum,
ForumName,Gbl.Prefs.Language,false); // Set forum name in recipient's language
}
/* Get degree code (row[4]) */
Hie.Deg.DegCod = Str_ConvertStrCodToLongCod (row[4]);
Deg_GetDataOfDegreeByCod (&Hie.Deg);
/* Get time of the event (row[7]) */
DateTimeUTC = Dat_GetUNIXTimeFromStr (row[7]);
/* Get course code (row[5]) */
Hie.Crs.CrsCod = Str_ConvertStrCodToLongCod (row[5]);
Crs_GetDataOfCourseByCod (&Hie.Crs);
/* Get status (row[8]) */
if (sscanf (row[8],"%u",&Status) != 1)
Err_WrongStatusExit ();
StatusTxt = Ntf_GetStatusTxtFromStatusBits (Status);
/* Get message/post/... code (row[6]) */
Cod = Str_ConvertStrCodToLongCod (row[6]);
if (Status & Ntf_STATUS_BIT_REMOVED) // The source of the notification was removed
{
ClassBackground = "MSG_TIT_BG_REM";
ClassText = "MSG_TIT_REM";
ClassLink = "BT_LINK MSG_TIT_REM";
ClassAuthorBg = "MSG_AUT_BG_REM";
PutLink = false;
}
else if (Status & Ntf_STATUS_BIT_READ) // I have already seen the source of the notification
{
ClassBackground = "MSG_TIT_BG";
ClassText = "MSG_TIT";
ClassLink = "BT_LINK LT MSG_TIT";
ClassAuthorBg = "MSG_AUT_BG";
PutLink = true;
}
else // I have not seen the source of the notification
{
ClassBackground = "MSG_TIT_BG_NEW";
ClassText = "MSG_TIT_NEW";
ClassLink = "BT_LINK LT MSG_TIT_NEW";
ClassAuthorBg = "MSG_AUT_BG_NEW";
PutLink = true;
}
/* Get forum type of the post */
if (NotifyEvent == Ntf_EVENT_FORUM_POST_COURSE ||
NotifyEvent == Ntf_EVENT_FORUM_REPLY)
{
For_ResetForums (&Forums);
For_GetForumTypeAndLocationOfAPost (Cod,&Forums.Forum);
For_SetForumName (&Forums.Forum,
ForumName,Gbl.Prefs.Language,false); // Set forum name in recipient's language
}
/***** Write row for this notification *****/
/* Write event icon */
HTM_TR_Begin (NULL);
/* Get time of the event (row[7]) */
DateTimeUTC = Dat_GetUNIXTimeFromStr (row[7]);
HTM_TD_Begin ("class=\"%s LT\" style=\"width:25px;\"",ClassBackground);
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
/* Get status (row[8]) */
if (sscanf (row[8],"%u",&Status) != 1)
Err_WrongStatusExit ();
StatusTxt = Ntf_GetStatusTxtFromStatusBits (Status);
if (PutLink)
{
Ico_PutIconLink (Ntf_Icons[NotifyEvent],
Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
Frm_EndForm ();
}
else
Ico_PutIconOff (Ntf_Icons[NotifyEvent],
Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_TD_End ();
if (Status & Ntf_STATUS_BIT_REMOVED) // The source of the notification was removed
{
ClassBackground = "MSG_TIT_BG_REM";
ClassText = "MSG_TIT_REM";
ClassLink = "BT_LINK MSG_TIT_REM";
ClassAuthorBg = "MSG_AUT_BG_REM";
PutLink = false;
}
else if (Status & Ntf_STATUS_BIT_READ) // I have already seen the source of the notification
{
ClassBackground = "MSG_TIT_BG";
ClassText = "MSG_TIT";
ClassLink = "BT_LINK LT MSG_TIT";
ClassAuthorBg = "MSG_AUT_BG";
PutLink = true;
}
else // I have not seen the source of the notification
{
ClassBackground = "MSG_TIT_BG_NEW";
ClassText = "MSG_TIT_NEW";
ClassLink = "BT_LINK LT MSG_TIT_NEW";
ClassAuthorBg = "MSG_AUT_BG_NEW";
PutLink = true;
}
/* Write event type */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
if (PutLink)
{
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
HTM_Txt (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
{
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
HTM_Txt (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_SPAN_End ();
}
HTM_TD_End ();
/***** Write row for this notification *****/
/* Write event icon */
HTM_TR_Begin (NULL);
/* Write user (from) */
HTM_TD_Begin ("class=\"%s LT\"",ClassAuthorBg);
Msg_WriteMsgAuthor (&UsrDat,true,NULL);
HTM_TD_End ();
HTM_TD_Begin ("class=\"%s LT\" style=\"width:25px;\"",ClassBackground);
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
/* Write location */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
if (NotifyEvent == Ntf_EVENT_FORUM_POST_COURSE ||
NotifyEvent == Ntf_EVENT_FORUM_REPLY)
{
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
if (PutLink)
{
Ico_PutIconLink (Ntf_Icons[NotifyEvent],
Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
Frm_EndForm ();
}
else
Ico_PutIconOff (Ntf_Icons[NotifyEvent],
Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_TD_End ();
if (PutLink)
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
else
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
HTM_TxtF ("%s:&nbsp;%s",Txt_Forum,ForumName);
if (PutLink)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
HTM_SPAN_End ();
}
else
{
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
/* Write event type */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
if (PutLink)
{
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
HTM_Txt (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
{
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
HTM_Txt (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent]);
HTM_SPAN_End ();
}
HTM_TD_End ();
if (PutLink)
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
else
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
/* Write user (from) */
HTM_TD_Begin ("class=\"%s LT\"",ClassAuthorBg);
Msg_WriteMsgAuthor (&UsrDat,true,NULL);
HTM_TD_End ();
if (Hie.Crs.CrsCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Course,Hie.Crs.ShrtName);
else if (Hie.Deg.DegCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Degree,Hie.Deg.ShrtName);
else if (Hie.Ctr.CtrCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Center,Hie.Ctr.ShrtName);
else if (Hie.Ins.InsCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Institution,Hie.Ins.ShrtName);
else
HTM_Hyphen ();
/* Write location */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
if (NotifyEvent == Ntf_EVENT_FORUM_POST_COURSE ||
NotifyEvent == Ntf_EVENT_FORUM_REPLY)
{
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
if (PutLink)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
HTM_SPAN_End ();
}
HTM_TD_End ();
if (PutLink)
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
else
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
HTM_TxtF ("%s:&nbsp;%s",Txt_Forum,ForumName);
if (PutLink)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
HTM_SPAN_End ();
}
else
{
if (PutLink)
PutLink = Ntf_StartFormGoToAction (NotifyEvent,Hie.Crs.CrsCod,&UsrDat,Cod,&Forums);
/* Write date and time */
Msg_WriteMsgDate (DateTimeUTC,ClassBackground);
if (PutLink)
HTM_BUTTON_SUBMIT_Begin (Txt_NOTIFY_EVENTS_SINGULAR[NotifyEvent],ClassLink,NULL);
else
HTM_SPAN_Begin ("class=\"%s\"",ClassText);
/* Write status (sent by email / pending to be sent by email) */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
HTM_Txt (Txt_NOTIFICATION_STATUS[StatusTxt]);
HTM_TD_End ();
if (Hie.Crs.CrsCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Course,Hie.Crs.ShrtName);
else if (Hie.Deg.DegCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Degree,Hie.Deg.ShrtName);
else if (Hie.Ctr.CtrCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Center,Hie.Ctr.ShrtName);
else if (Hie.Ins.InsCod > 0)
HTM_TxtF ("%s:&nbsp;%s",Txt_Institution,Hie.Ins.ShrtName);
else
HTM_Hyphen ();
HTM_TR_End ();
if (PutLink)
{
HTM_BUTTON_End ();
Frm_EndForm ();
}
else
HTM_SPAN_End ();
}
HTM_TD_End ();
/***** Write content of the event *****/
if (PutLink)
{
ContentStr = NULL;
/* Write date and time */
Msg_WriteMsgDate (DateTimeUTC,ClassBackground);
Ntf_GetNotifSummaryAndContent (SummaryStr,&ContentStr,NotifyEvent,
Cod,Hie.Crs.CrsCod,Gbl.Usrs.Me.UsrDat.UsrCod,
false);
HTM_TR_Begin (NULL);
/* Write status (sent by email / pending to be sent by email) */
HTM_TD_Begin ("class=\"%s LT\"",ClassBackground);
HTM_Txt (Txt_NOTIFICATION_STATUS[StatusTxt]);
HTM_TD_End ();
HTM_TD_Begin ("colspan=\"2\"");
HTM_TD_End ();
HTM_TR_End ();
HTM_TD_Begin ("colspan=\"4\" class=\"DAT LT\" style=\"padding-bottom:12px;\"");
HTM_Txt (SummaryStr);
HTM_TD_End ();
/***** Write content of the event *****/
if (PutLink)
{
ContentStr = NULL;
HTM_TR_End ();
}
}
Ntf_GetNotifSummaryAndContent (SummaryStr,&ContentStr,NotifyEvent,
Cod,Hie.Crs.CrsCod,Gbl.Usrs.Me.UsrDat.UsrCod,
false);
HTM_TR_Begin (NULL);
/***** End table *****/
HTM_TABLE_End ();
HTM_TD_Begin ("colspan=\"2\"");
HTM_TD_End ();
/***** Free memory used for user's data *****/
Usr_UsrDataDestructor (&UsrDat);
}
else
Ale_ShowAlert (Ale_INFO,AllNotifications ? Txt_You_have_no_notifications :
Txt_You_have_no_unread_notifications);
HTM_TD_Begin ("colspan=\"4\" class=\"DAT LT\" style=\"padding-bottom:12px;\"");
HTM_Txt (SummaryStr);
HTM_TD_End ();
HTM_TR_End ();
}
}
/***** End table *****/
HTM_TABLE_End ();
/***** Free memory used for user's data *****/
Usr_UsrDataDestructor (&UsrDat);
}
else
Ale_ShowAlert (Ale_INFO,AllNotifications ? Txt_You_have_no_notifications :
Txt_You_have_no_unread_notifications);
/***** End box *****/
Box_BoxEnd ();
@ -627,7 +627,7 @@ void Ntf_ShowMyNotifications (void)
DB_FreeMySQLResult (&mysql_res);
/***** Reset to 0 the number of new notifications *****/
Ntf_UpdateMyLastAccessToNotifications ();
Ntf_DB_UpdateMyLastAccessToNotifications ();
}
/*****************************************************************************/
@ -905,7 +905,7 @@ void Ntf_GetNotifSummaryAndContent (char SummaryStr[Ntf_MAX_BYTES_SUMMARY + 1],
Msg_GetNotifMessage (SummaryStr,ContentStr,Cod,GetContent);
if (Gbl.WebService.IsWebService)
/* Set the message as open by me, because I can read it in an extern application */
Msg_SetReceivedMsgAsOpen (Cod,UsrCod);
Msg_DB_SetReceivedMsgAsOpen (Cod,UsrCod);
break;
case Ntf_EVENT_SURVEY:
Svy_GetNotifSurvey (SummaryStr,ContentStr,Cod,GetContent);
@ -963,7 +963,7 @@ void Ntf_MarkNotifAsSeen (Ntf_NotifyEvent_t NotifyEvent,long Cod,long CrsCod,lon
/******************* Set possible notifications as removed *******************/
/*****************************************************************************/
void Ntf_MarkNotifAsRemoved (Ntf_NotifyEvent_t NotifyEvent,long Cod)
void Ntf_DB_MarkNotifAsRemoved (Ntf_NotifyEvent_t NotifyEvent,long Cod)
{
/***** Set notification as removed *****/
DB_QueryUPDATE ("can not set notification(s) as removed",
@ -1089,7 +1089,7 @@ void Ntf_MarkNotifOneFileAsRemoved (const char *Path)
default:
return;
}
Ntf_MarkNotifAsRemoved (NotifyEvent,FilCod);
Ntf_DB_MarkNotifAsRemoved (NotifyEvent,FilCod);
}
break;
default:
@ -1164,7 +1164,7 @@ void Ntf_MarkNotifChildrenOfFolderAsRemoved (const char *Path)
/******* Set all possible notifications of files in a group as removed *******/
/*****************************************************************************/
void Ntf_MarkNotifFilesInGroupAsRemoved (long GrpCod)
void Ntf_DB_MarkNotifFilesInGroupAsRemoved (long GrpCod)
{
/***** Set notifications as removed *****/
DB_QueryUPDATE ("can not set notification(s) as removed",
@ -1513,14 +1513,14 @@ unsigned Ntf_StoreNotifyEventsToAllUsrs (Ntf_NotifyEvent_t NotifyEvent,long Cod)
{
if ((UsrDat.NtfEvents.SendEmail & NotifyEventMask)) // Send notification by email
{
Ntf_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,Cod,
Ntf_DB_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,Cod,
(Ntf_Status_t) Ntf_STATUS_BIT_EMAIL,
InsCod,CtrCod,DegCod,CrsCod);
NumUsrsToBeNotifiedByEMail++;
}
else // Don't send notification by email
Ntf_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,Cod,(Ntf_Status_t) 0,
InsCod,CtrCod,DegCod,CrsCod);
Ntf_DB_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,Cod,(Ntf_Status_t) 0,
InsCod,CtrCod,DegCod,CrsCod);
}
}
@ -1538,10 +1538,10 @@ unsigned Ntf_StoreNotifyEventsToAllUsrs (Ntf_NotifyEvent_t NotifyEvent,long Cod)
/************** Store a notify event to one user into database ***************/
/*****************************************************************************/
void Ntf_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
struct UsrData *UsrDat,
long Cod,Ntf_Status_t Status,
long InsCod,long CtrCod,long DegCod,long CrsCod)
void Ntf_DB_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
struct UsrData *UsrDat,
long Cod,Ntf_Status_t Status,
long InsCod,long CtrCod,long DegCod,long CrsCod)
{
/***** Store notify event *****/
DB_QueryINSERT ("can not create new notification event",
@ -1566,7 +1566,7 @@ void Ntf_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
/*************** Reset my number of new notifications to 0 *******************/
/*****************************************************************************/
static void Ntf_UpdateMyLastAccessToNotifications (void)
static void Ntf_DB_UpdateMyLastAccessToNotifications (void)
{
/***** Reset to 0 my number of new notifications *****/
DB_QueryUPDATE ("can not update last access to notifications",
@ -2004,70 +2004,68 @@ void Ntf_PutFormChangeNotifSentByEMail (void)
/***** Begin section with settings on privacy *****/
HTM_SECTION_Begin (Ntf_NOTIFICATIONS_ID);
/***** Begin box *****/
Box_BoxBegin (NULL,Txt_Notifications,
Ntf_PutIconsNotif,NULL,
Hlp_PROFILE_Settings_notifications,Box_NOT_CLOSABLE);
/***** Begin box *****/
Box_BoxBegin (NULL,Txt_Notifications,
Ntf_PutIconsNotif,NULL,
Hlp_PROFILE_Settings_notifications,Box_NOT_CLOSABLE);
/***** Begin form *****/
Frm_BeginForm (ActChgNtfPrf);
/***** Begin form *****/
Frm_BeginForm (ActChgNtfPrf);
/***** Warning if I can not receive email notifications *****/
if (!Mai_CheckIfUsrCanReceiveEmailNotif (&Gbl.Usrs.Me.UsrDat))
Mai_WriteWarningEmailNotifications ();
/***** Warning if I can not receive email notifications *****/
if (!Mai_CheckIfUsrCanReceiveEmailNotif (&Gbl.Usrs.Me.UsrDat))
Mai_WriteWarningEmailNotifications ();
/***** List of notifications *****/
HTM_TABLE_BeginCenterPadding (2);
HTM_TR_Begin (NULL);
/***** List of notifications *****/
HTM_TABLE_BeginCenterPadding (2);
HTM_TH_Empty (1);
HTM_TR_Begin (NULL);
HTM_TH_Empty (1);
HTM_TH (1,1,"CM",Txt_Create_BR_notification);
HTM_TH (1,1,"CM",Txt_Notify_me_BR_by_email);
HTM_TR_End ();
HTM_TH (1,1,"CM",Txt_Create_BR_notification);
HTM_TH (1,1,"CM",Txt_Notify_me_BR_by_email);
/***** Checkbox to activate internal notifications and email notifications
about events *****/
for (NotifyEvent = (Ntf_NotifyEvent_t) 1;
NotifyEvent <= (Ntf_NotifyEvent_t) (Ntf_NUM_NOTIFY_EVENTS - 1);
NotifyEvent++) // O is reserved for Ntf_EVENT_UNKNOWN
{
HTM_TR_Begin (NULL);
HTM_TR_End ();
HTM_TD_Begin ("class=\"%s RM\"",The_ClassFormInBox[Gbl.Prefs.Theme]);
HTM_TxtColon (Txt_NOTIFY_EVENTS_PLURAL[NotifyEvent]);
HTM_TD_End ();
/***** Checkbox to activate internal notifications and email notifications
about events *****/
for (NotifyEvent = (Ntf_NotifyEvent_t) 1;
NotifyEvent <= (Ntf_NotifyEvent_t) (Ntf_NUM_NOTIFY_EVENTS - 1);
NotifyEvent++) // O is reserved for Ntf_EVENT_UNKNOWN
{
HTM_TR_Begin (NULL);
HTM_TD_Begin ("class=\"CM\"");
HTM_INPUT_CHECKBOX (Ntf_ParamNotifMeAboutNotifyEvents[NotifyEvent],HTM_DONT_SUBMIT_ON_CHANGE,
"value=\"Y\"%s",
(Gbl.Usrs.Me.UsrDat.NtfEvents.CreateNotif &
(1 << NotifyEvent)) ? " checked=\"checked\"" :
"");
HTM_TD_End ();
HTM_TD_Begin ("class=\"%s RM\"",The_ClassFormInBox[Gbl.Prefs.Theme]);
HTM_TxtColon (Txt_NOTIFY_EVENTS_PLURAL[NotifyEvent]);
HTM_TD_End ();
HTM_TD_Begin ("class=\"CM\"");
HTM_INPUT_CHECKBOX (Ntf_ParamEmailMeAboutNotifyEvents[NotifyEvent],HTM_DONT_SUBMIT_ON_CHANGE,
"value=\"Y\"%s",
(Gbl.Usrs.Me.UsrDat.NtfEvents.SendEmail &
(1 << NotifyEvent)) ? " checked=\"checked\"" :
"");
HTM_TD_End ();
HTM_TD_Begin ("class=\"CM\"");
HTM_INPUT_CHECKBOX (Ntf_ParamNotifMeAboutNotifyEvents[NotifyEvent],HTM_DONT_SUBMIT_ON_CHANGE,
"value=\"Y\"%s",
(Gbl.Usrs.Me.UsrDat.NtfEvents.CreateNotif &
(1 << NotifyEvent)) ? " checked=\"checked\"" :
"");
HTM_TD_End ();
HTM_TR_End ();
}
HTM_TD_Begin ("class=\"CM\"");
HTM_INPUT_CHECKBOX (Ntf_ParamEmailMeAboutNotifyEvents[NotifyEvent],HTM_DONT_SUBMIT_ON_CHANGE,
"value=\"Y\"%s",
(Gbl.Usrs.Me.UsrDat.NtfEvents.SendEmail &
(1 << NotifyEvent)) ? " checked=\"checked\"" :
"");
HTM_TD_End ();
HTM_TABLE_End ();
HTM_TR_End ();
}
/***** Button to save changes *****/
Btn_PutConfirmButton (Txt_Save_changes);
HTM_TABLE_End ();
/***** End form *****/
Frm_EndForm ();
/***** Button to save changes *****/
Btn_PutConfirmButton (Txt_Save_changes);
/***** End form *****/
Frm_EndForm ();
/***** End box *****/
Box_BoxEnd ();
/***** End box *****/
Box_BoxEnd ();
/***** End section with settings about notifications *****/
HTM_SECTION_End ();
@ -2147,30 +2145,34 @@ void Ntf_WriteNumberOfNewNtfs (void)
/***** Begin form *****/
Frm_BeginFormId (ActSeeNewNtf,"form_ntf");
HTM_BUTTON_SUBMIT_Begin (Txt_See_notifications,The_ClassNotif[Gbl.Prefs.Theme],NULL);
/***** Number of unseen notifications *****/
HTM_SPAN_Begin ("id=\"notif_all\"");
HTM_TxtF ("%u&nbsp;%s",NumUnseenNtfs,
NumUnseenNtfs == 1 ? Txt_notification :
Txt_notifications);
HTM_SPAN_End ();
/***** Begin link *****/
HTM_BUTTON_SUBMIT_Begin (Txt_See_notifications,The_ClassNotif[Gbl.Prefs.Theme],NULL);
/***** Icon and number of new notifications *****/
if (NumNewNtfs)
{
HTM_BR ();
HTM_IMG (Gbl.Prefs.URLTheme,"bell.svg",Txt_Notifications,
"class=\"ICO16x16\"");
HTM_TxtF ("&nbsp;%u",NumNewNtfs);
HTM_SPAN_Begin ("id=\"notif_new\"");
HTM_TxtF ("&nbsp;%s",NumNewNtfs == 1 ? Txt_NOTIF_new_SINGULAR :
Txt_NOTIF_new_PLURAL);
HTM_SPAN_End ();
}
/***** Number of unseen notifications *****/
HTM_SPAN_Begin ("id=\"notif_all\"");
HTM_TxtF ("%u&nbsp;%s",NumUnseenNtfs,
NumUnseenNtfs == 1 ? Txt_notification :
Txt_notifications);
HTM_SPAN_End ();
/***** Icon and number of new notifications *****/
if (NumNewNtfs)
{
HTM_BR ();
HTM_IMG (Gbl.Prefs.URLTheme,"bell.svg",Txt_Notifications,
"class=\"ICO16x16\"");
HTM_TxtF ("&nbsp;%u",NumNewNtfs);
HTM_SPAN_Begin ("id=\"notif_new\"");
HTM_TxtF ("&nbsp;%s",NumNewNtfs == 1 ? Txt_NOTIF_new_SINGULAR :
Txt_NOTIF_new_PLURAL);
HTM_SPAN_End ();
}
/***** End link *****/
HTM_BUTTON_End ();
/***** End form *****/
HTM_BUTTON_End ();
Frm_EndForm ();
}

View File

@ -122,17 +122,17 @@ void Ntf_GetNotifSummaryAndContent (char SummaryStr[Ntf_MAX_BYTES_SUMMARY + 1],
long Cod,long CrsCod,long UsrCod,
bool GetContent);
void Ntf_MarkNotifAsSeen (Ntf_NotifyEvent_t NotifyEvent,long Cod,long CrsCod,long ToUsrCod);
void Ntf_MarkNotifAsRemoved (Ntf_NotifyEvent_t NotifyEvent,long Cod);
void Ntf_DB_MarkNotifAsRemoved (Ntf_NotifyEvent_t NotifyEvent,long Cod);
void Ntf_MarkNotifToOneUsrAsRemoved (Ntf_NotifyEvent_t NotifyEvent,long Cod,long ToUsrCod);
void Ntf_MarkNotifInCrsAsRemoved (long ToUsrCod,long CrsCod);
void Ntf_MarkNotifOneFileAsRemoved (const char *Path);
void Ntf_MarkNotifChildrenOfFolderAsRemoved (const char *Path);
void Ntf_MarkNotifFilesInGroupAsRemoved (long GrpCod);
void Ntf_DB_MarkNotifFilesInGroupAsRemoved (long GrpCod);
unsigned Ntf_StoreNotifyEventsToAllUsrs (Ntf_NotifyEvent_t NotifyEvent,long Cod);
void Ntf_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
struct UsrData *UsrDat,
long Cod,Ntf_Status_t Status,
long InsCod,long CtrCod,long DegCod,long CrsCod);
void Ntf_DB_StoreNotifyEventToOneUser (Ntf_NotifyEvent_t NotifyEvent,
struct UsrData *UsrDat,
long Cod,Ntf_Status_t Status,
long InsCod,long CtrCod,long DegCod,long CrsCod);
void Ntf_SendPendingNotifByEMailToAllUsrs (void);
Ntf_NotifyEvent_t Ntf_GetNotifyEventFromStr (const char *Str);
void Ntf_MarkAllNotifAsSeen (void);

View File

@ -178,49 +178,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
1,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (1, // Page of threads = first
1, // Page of posts = first
@ -231,7 +231,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
1, // Page of posts = first
@ -242,17 +242,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -261,7 +261,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
@ -305,49 +305,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
1,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (1, // Page of threads = first
1, // Page of posts = first
@ -358,7 +358,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
1, // Page of posts = first
@ -369,17 +369,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -388,7 +388,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,1);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
@ -418,49 +418,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
Pagination->LeftPage,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (Pagination->LeftPage, // Page of threads = left
1, // Page of posts = first
@ -471,7 +471,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
Pagination->LeftPage, // Page of posts = left
@ -482,17 +482,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -501,7 +501,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->LeftPage);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
@ -543,49 +543,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
NumPage,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (NumPage, // Page of threads = number of page
1, // Page of posts = first
@ -596,7 +596,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
NumPage, // Page of posts = number of page
@ -607,17 +607,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -626,7 +626,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,NumPage);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
@ -655,49 +655,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
Pagination->RightPage,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (Pagination->RightPage, // Page of threads = right
1, // Page of posts = first
@ -708,7 +708,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
Pagination->RightPage, // Page of posts = right
@ -719,17 +719,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -738,7 +738,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->RightPage);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
@ -768,49 +768,49 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
switch (WhatPaginate)
{
case Pag_ASSIGNMENTS:
Frm_StartFormAnchor (ActSeeAsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Dat_PutHiddenParamOrder (((struct Asg_Assignments *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_PROJECTS:
Frm_StartFormAnchor (ActSeePrj,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeePrj,Pagination->Anchor);
Prj_PutParams (&((struct Prj_Projects *) Context)->Filter,
((struct Prj_Projects *) Context)->SelectedOrder,
Pagination->NumPags,
Cod);
break;
case Pag_EXAMS:
Frm_StartFormAnchor (ActSeeAllExa,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllExa,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Dat_PutHiddenParamOrder (((struct Exa_Exams *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_GAMES:
Frm_StartFormAnchor (ActSeeAllGam,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllGam,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Dat_PutHiddenParamOrder (((struct Gam_Games *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_SURVEYS:
Frm_StartFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAllSvy,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Dat_PutHiddenParamOrder (((struct Svy_Surveys *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_ATT_EVENTS:
Frm_StartFormAnchor (ActSeeAtt,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeAtt,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Dat_PutHiddenParamOrder (((struct Att_Events *) Context)->SelectedOrder);
WhichGroups = Grp_GetParamWhichGroups ();
Grp_PutParamWhichGroups (&WhichGroups);
break;
case Pag_THREADS_FORUM:
Frm_StartFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeeFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (Pagination->NumPags, // Page of threads = last
1, // Page of posts = first
@ -821,7 +821,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_POSTS_FORUM:
Frm_StartFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Frm_BeginFormAnchor (For_ActionsSeePstFor[((struct For_Forums *) Context)->Forum.Type],
Pagination->Anchor);
For_PutAllHiddenParamsForum (((struct For_Forums *) Context)->CurrentPageThrs, // Page of threads = current
Pagination->NumPags, // Page of posts = last
@ -832,17 +832,17 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
-1L);
break;
case Pag_MESSAGES_RECEIVED:
Frm_StartFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeRcvMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MESSAGES_SENT:
Frm_StartFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeSntMsg,Pagination->Anchor);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Msg_PutHiddenParamsMsgsFilters ((struct Msg_Messages *) Context);
break;
case Pag_MY_AGENDA:
Frm_StartFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeMyAgd,Pagination->Anchor);
Agd_PutParamsMyAgenda (((struct Agd_Agenda *) Context)->Past__FutureEvents,
((struct Agd_Agenda *) Context)->PrivatPublicEvents,
((struct Agd_Agenda *) Context)->HiddenVisiblEvents,
@ -851,7 +851,7 @@ void Pag_WriteLinksToPages (Pag_WhatPaginate_t WhatPaginate,
Cod);
break;
case Pag_ANOTHER_AGENDA:
Frm_StartFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Frm_BeginFormAnchor (ActSeeUsrAgd,Pagination->Anchor);
Agd_PutHiddenParamEventsOrder (((struct Agd_Agenda *) Context)->SelectedOrder);
Pag_PutHiddenParamPagNum (WhatPaginate,Pagination->NumPags);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);

View File

@ -669,7 +669,7 @@ void Pwd_ShowFormChgMyPwd (void)
HTM_SECTION_Begin (Pwd_PASSWORD_SECTION_ID);
/***** Begin form *****/
Frm_StartFormAnchor (ActChgMyPwd,Pwd_PASSWORD_SECTION_ID);
Frm_BeginFormAnchor (ActChgMyPwd,Pwd_PASSWORD_SECTION_ID);
/***** Begin box *****/
snprintf (StrRecordWidth,sizeof (StrRecordWidth),"%upx",Rec_RECORD_WIDTH);
@ -833,7 +833,7 @@ void Pwd_ShowFormChgOtherUsrPwd (void)
NextAction = ActChgPwdOth;
break;
}
Frm_StartFormAnchor (NextAction,Pwd_PASSWORD_SECTION_ID);
Frm_BeginFormAnchor (NextAction,Pwd_PASSWORD_SECTION_ID);
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
/* New password */

View File

@ -166,7 +166,7 @@ static void Pri_PutFormVisibility (const char *TxtLabel,
/***** Form with list of options *****/
HTM_TD_Begin ("class=\"LT\"");
if (Action != ActUnk)
Frm_StartFormAnchor (Action,Pri_PRIVACY_ID);
Frm_BeginFormAnchor (Action,Pri_PRIVACY_ID);
HTM_UL_Begin ("class=\"PRI_LIST LIST_LEFT\"");
for (Visibility = Pri_VISIBILITY_USER;
Visibility <= Pri_VISIBILITY_WORLD;

View File

@ -1235,7 +1235,7 @@ static void Prf_GetNumMessagesSentAndStoreAsUsrFigure (long UsrCod)
Prf_ResetUsrFigures (&UsrFigures);
/***** Get number of messages sent from database *****/
UsrFigures.NumMsgSnt = (int) Msg_GetNumMsgsSentByUsr (UsrCod);
UsrFigures.NumMsgSnt = (int) Msg_DB_GetNumMsgsSentByUsr (UsrCod);
/***** Update number of messages sent in user's figures *****/
if (Prf_CheckIfUsrFiguresExists (UsrCod))

View File

@ -399,7 +399,7 @@ static void Prg_PutButtonToCreateNewItem (void)
extern const char *Txt_New_item;
long ItmCod = -1L;
Frm_StartFormAnchor (ActFrmNewPrgItm,"item_form");
Frm_BeginFormAnchor (ActFrmNewPrgItm,"item_form");
Prg_PutParams (&ItmCod);
Btn_PutConfirmButton (Txt_New_item);
Frm_EndForm ();
@ -1828,7 +1828,7 @@ static void Prg_ShowFormToCreateItem (long ParentItmCod)
Ale_ShowAlerts (NULL);
/***** Begin form *****/
Frm_StartFormAnchor (ActNewPrgItm,"prg_highlighted");
Frm_BeginFormAnchor (ActNewPrgItm,"prg_highlighted");
Prg_PutParamItmCod (ParentItem.Hierarchy.ItmCod);
/***** Begin box and table *****/
@ -1872,7 +1872,7 @@ static void Prg_ShowFormToChangeItem (long ItmCod)
Ale_ShowAlerts (NULL);
/***** Begin form *****/
Frm_StartFormAnchor (ActChgPrgItm,"prg_highlighted");
Frm_BeginFormAnchor (ActChgPrgItm,"prg_highlighted");
Prg_PutParamItmCod (Item.Hierarchy.ItmCod);
/***** Begin box and table *****/

View File

@ -1721,7 +1721,7 @@ static void Rec_ShowCrsRecord (Rec_CourseRecordViewType_t TypeOfView,
TypeOfView == Rec_CRS_LIST_SEVERAL_RECORDS)
{
ICanEdit = true;
Frm_StartFormAnchor (ActRcvRecOthUsr,Anchor);
Frm_BeginFormAnchor (ActRcvRecOthUsr,Anchor);
Par_PutHiddenParamLong (NULL,"OriginalActCod",
Act_GetActCod (ActSeeRecSevStd)); // Original action, used to know where we came from
Usr_PutParamUsrCodEncrypted (UsrDat->EnUsrCod);
@ -2620,7 +2620,7 @@ static void Rec_PutIconsCommands (__attribute__((unused)) void *Args)
Rec_PutParamUsrCodEncrypted,NULL);
/***** Button to send a message *****/
RecipientHasBannedMe = Msg_CheckIfUsrIsBanned (Gbl.Usrs.Me.UsrDat.UsrCod, // From:
RecipientHasBannedMe = Msg_DB_CheckIfUsrIsBanned (Gbl.Usrs.Me.UsrDat.UsrCod, // From:
Gbl.Record.UsrDat->UsrCod); // To:
if (!RecipientHasBannedMe)
Lay_PutContextualLinkOnlyIcon (ActReqMsgUsr,NULL,
@ -3896,7 +3896,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
/* Begin form to select the country of my institution */
Frm_StartFormAnchor (ActChgCtyMyIns,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgCtyMyIns,Rec_MY_INS_CTR_DPT_ID);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"id=\"InsCtyCod\" name=\"OthCtyCod\""
" class=\"REC_C2_BOT_INPUT\"");
@ -3933,7 +3933,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
Ins_GetBasicListOfInstitutions (Gbl.Usrs.Me.UsrDat.InsCtyCod);
/* Begin form to select institution */
Frm_StartFormAnchor (ActChgMyIns,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgMyIns,Rec_MY_INS_CTR_DPT_ID);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"id=\"OthInsCod\" name=\"OthInsCod\""
" class=\"REC_C2_BOT_INPUT\"");
@ -3974,7 +3974,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
Ctr_GetBasicListOfCenters (Gbl.Usrs.Me.UsrDat.InsCod);
/* Begin form to select center */
Frm_StartFormAnchor (ActChgMyCtr,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgMyCtr,Rec_MY_INS_CTR_DPT_ID);
HTM_SELECT_Begin (HTM_SUBMIT_ON_CHANGE,
"id=\"OthCtrCod\" name=\"OthCtrCod\""
" class=\"REC_C2_BOT_INPUT\"");
@ -4006,7 +4006,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
Frm_StartFormAnchor (ActChgMyDpt,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgMyDpt,Rec_MY_INS_CTR_DPT_ID);
Dpt_WriteSelectorDepartment (Gbl.Usrs.Me.UsrDat.InsCod, // Departments in my institution
Gbl.Usrs.Me.UsrDat.Tch.DptCod, // Selected department
"REC_C2_BOT_INPUT", // Selector class
@ -4026,7 +4026,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
Frm_StartFormAnchor (ActChgMyOff,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgMyOff,Rec_MY_INS_CTR_DPT_ID);
HTM_INPUT_TEXT ("Office",Usr_MAX_CHARS_ADDRESS,Gbl.Usrs.Me.UsrDat.Tch.Office,
HTM_SUBMIT_ON_CHANGE,
"id=\"Office\" class=\"REC_C2_BOT_INPUT\"");
@ -4043,7 +4043,7 @@ static void Rec_ShowFormMyInsCtrDpt (bool IAmATeacher)
/* Data */
HTM_TD_Begin ("class=\"REC_C2_BOT LM\"");
Frm_StartFormAnchor (ActChgMyOffPho,Rec_MY_INS_CTR_DPT_ID);
Frm_BeginFormAnchor (ActChgMyOffPho,Rec_MY_INS_CTR_DPT_ID);
HTM_INPUT_TEL ("OfficePhone",Gbl.Usrs.Me.UsrDat.Tch.OfficePhone,
HTM_SUBMIT_ON_CHANGE,
"id=\"OfficePhone\" class=\"REC_C2_BOT_INPUT\"");

View File

@ -814,7 +814,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Building */
HTM_TD_Begin ("class=\"CT\"");
Frm_StartFormAnchor (ActChgRooBld,Anchor);
Frm_BeginFormAnchor (ActChgRooBld,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
Roo_PutSelectorBuilding (Room->BldCod,Buildings,
HTM_SUBMIT_ON_CHANGE);
@ -823,7 +823,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Floor */
HTM_TD_Begin ("class=\"LT\"");
Frm_StartFormAnchor (ActChgRooFlo,Anchor);
Frm_BeginFormAnchor (ActChgRooFlo,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
HTM_INPUT_LONG ("Floor",(long) INT_MIN,(long) INT_MAX,(long) Room->Floor,
HTM_SUBMIT_ON_CHANGE,false,
@ -833,7 +833,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Room type */
HTM_TD_Begin ("class=\"CT\"");
Frm_StartFormAnchor (ActChgRooTyp,Anchor);
Frm_BeginFormAnchor (ActChgRooTyp,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
Roo_PutSelectorType (Room->Type,
HTM_SUBMIT_ON_CHANGE);
@ -842,7 +842,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Room short name */
HTM_TD_Begin ("class=\"LT\"");
Frm_StartFormAnchor (ActRenRooSho,Anchor);
Frm_BeginFormAnchor (ActRenRooSho,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
HTM_INPUT_TEXT ("ShortName",Roo_MAX_CHARS_SHRT_NAME,Room->ShrtName,
HTM_SUBMIT_ON_CHANGE,
@ -852,7 +852,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Room full name */
HTM_TD_Begin ("class=\"LT\"");
Frm_StartFormAnchor (ActRenRooFul,Anchor);
Frm_BeginFormAnchor (ActRenRooFul,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
HTM_INPUT_TEXT ("FullName",Roo_MAX_CHARS_FULL_NAME,Room->FullName,
HTM_SUBMIT_ON_CHANGE,
@ -862,7 +862,7 @@ static void Roo_ListRoomsForEdition (const struct Bld_Buildings *Buildings,
/* Seating capacity */
HTM_TD_Begin ("class=\"LT\"");
Frm_StartFormAnchor (ActChgRooMaxUsr,Anchor);
Frm_BeginFormAnchor (ActChgRooMaxUsr,Anchor);
Roo_PutParamRooCod (&Room->RooCod);
Roo_WriteCapacity (StrCapacity,Room->Capacity);
HTM_INPUT_TEXT ("Capacity",Cns_MAX_DECIMAL_DIGITS_UINT,StrCapacity,

View File

@ -309,7 +309,7 @@ static void Sta_PutFormCrsHits (struct Sta_Stats *Stats)
Enr_CheckStdsAndPutButtonToRegisterStdsInCurrentCrs ();
/***** Begin form *****/
Frm_StartFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Frm_BeginFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Grp_PutParamsCodGrps ();
Par_PutHiddenParamLong (NULL,"FirstRow",0);
@ -499,7 +499,7 @@ static void Sta_PutFormGblHits (struct Sta_Stats *Stats)
Mnu_ContextMenuEnd ();
/***** Begin form *****/
Frm_StartFormAnchor (ActSeeAccGbl,Sta_STAT_RESULTS_SECTION_ID);
Frm_BeginFormAnchor (ActSeeAccGbl,Sta_STAT_RESULTS_SECTION_ID);
/***** Begin box and table *****/
Box_BoxTableBegin (NULL,Txt_Statistics_of_all_visits,
@ -1628,7 +1628,7 @@ static void Sta_ShowDetailedAccessesList (const struct Sta_Stats *Stats,
/* Put link to jump to previous page (older clicks) */
if (FirstRow > 1)
{
Frm_StartFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Frm_BeginFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Dat_WriteParamsIniEndDates ();
Par_PutHiddenParamUnsigned (NULL,"GroupedBy",(unsigned) Sta_CLICKS_CRS_DETAILED_LIST);
Par_PutHiddenParamUnsigned (NULL,"StatAct" ,(unsigned) Stats->NumAction);
@ -1666,7 +1666,7 @@ static void Sta_ShowDetailedAccessesList (const struct Sta_Stats *Stats,
/* Put link to jump to next page (more recent clicks) */
if (LastRow < NumHits)
{
Frm_StartFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Frm_BeginFormAnchor (ActSeeAccCrs,Sta_STAT_RESULTS_SECTION_ID);
Dat_WriteParamsIniEndDates ();
Par_PutHiddenParamUnsigned (NULL,"GroupedBy",(unsigned) Sta_CLICKS_CRS_DETAILED_LIST);
Par_PutHiddenParamUnsigned (NULL,"StatAct" ,(unsigned) Stats->NumAction);
@ -2092,7 +2092,7 @@ static void Sta_ShowDistrAccessesPerDayAndHour (const struct Sta_Stats *Stats,
HTM_TD_Begin ("colspan=\"26\" class=\"CM\"");
Frm_StartFormAnchor (Gbl.Action.Act,Sta_STAT_RESULTS_SECTION_ID);
Frm_BeginFormAnchor (Gbl.Action.Act,Sta_STAT_RESULTS_SECTION_ID);
Dat_WriteParamsIniEndDates ();
Par_PutHiddenParamUnsigned (NULL,"GroupedBy",(unsigned) Stats->ClicksGroupedBy);
Par_PutHiddenParamUnsigned (NULL,"CountType",(unsigned) Stats->CountType);

View File

@ -756,7 +756,7 @@ void Str_AnalyzeTxtAndStoreNotifyEventToMentionedUsrs (long PubCod,const char *T
if (CreateNotif)
{
NotifyByEmail = (UsrDat.NtfEvents.SendEmail & (1 << Ntf_EVENT_TL_MENTION));
Ntf_StoreNotifyEventToOneUser (Ntf_EVENT_TL_MENTION,&UsrDat,PubCod,
Ntf_DB_StoreNotifyEventToOneUser (Ntf_EVENT_TL_MENTION,&UsrDat,PubCod,
(Ntf_Status_t) (NotifyByEmail ? Ntf_STATUS_BIT_EMAIL :
0),
Gbl.Hierarchy.Ins.InsCod,

View File

@ -1653,7 +1653,7 @@ void Svy_RemoveSurvey (void)
Svy.SvyCod);
/***** Mark possible notifications as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_SURVEY,Svy.SvyCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_SURVEY,Svy.SvyCod);
/***** Write message to show the change made *****/
Ale_ShowAlert (Ale_SUCCESS,Txt_Survey_X_removed,

View File

@ -1007,9 +1007,9 @@ void Tml_Com_RemoveCommMediaAndDBEntries (long PubCod)
Med_RemoveMedia (Tml_DB_GetMedCodFromComm (PubCod));
/***** Mark possible notifications on this comment as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_COMMENT,PubCod);
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV ,PubCod);
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_MENTION,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_COMMENT,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV ,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_MENTION,PubCod);
/***** Remove favs for this comment *****/
Tml_DB_RemoveCommFavs (PubCod);

View File

@ -194,7 +194,7 @@ static void Tml_Fav_UnfNote (struct Tml_Not_Note *Not)
/***** Mark possible notifications on this note as removed *****/
OriginalPubCod = Tml_DB_GetPubCodOfOriginalNote (Not->NotCod);
if (OriginalPubCod > 0)
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV,OriginalPubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV,OriginalPubCod);
}
/*****************************************************************************/
@ -345,7 +345,7 @@ static void Tml_Fav_UnfComm (struct Tml_Com_Comment *Com)
Com->PubCod,Com->UsrCod);
/***** Mark possible notifications on this comment as removed *****/
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV,Com->PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV,Com->PubCod);
/***** Free image *****/
Med_MediaDestructor (&Com->Content.Media);

View File

@ -188,7 +188,7 @@ void Tml_Frm_BeginForm (const struct Tml_Timeline *Timeline,
if (Gbl.Usrs.Other.UsrDat.UsrCod > 0)
{
/***** Begin form in user timeline *****/
Frm_StartFormAnchor (Tml_Frm_ActionUsr[Action],"timeline");
Frm_BeginFormAnchor (Tml_Frm_ActionUsr[Action],"timeline");
Usr_PutParamOtherUsrCodEncrypted (Gbl.Usrs.Other.UsrDat.EnUsrCod);
}
else

View File

@ -1287,9 +1287,9 @@ static void Tml_Not_RemoveNoteMediaAndDBEntries (struct Tml_Not_Note *Not)
PubCod = Tml_DB_GetPubCodOfOriginalNote (Not->NotCod);
if (PubCod > 0)
{
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV ,PubCod);
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_SHARE ,PubCod);
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_MENTION,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_FAV ,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_SHARE ,PubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_MENTION,PubCod);
}
/***** Remove favs for this note *****/

View File

@ -86,7 +86,7 @@ void Tml_Ntf_CreateNotifToAuthor (long AuthorCod,long PubCod,
If this author wants to receive notifications by email,
activate the sending of a notification *****/
if (CreateNotif)
Ntf_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,PubCod,
Ntf_DB_StoreNotifyEventToOneUser (NotifyEvent,&UsrDat,PubCod,
(Ntf_Status_t) (NotifyByEmail ? Ntf_STATUS_BIT_EMAIL :
0),
Gbl.Hierarchy.Ins.InsCod,

View File

@ -192,5 +192,5 @@ static void Tml_Sha_UnsNote (struct Tml_Not_Note *Not)
/***** Mark possible notifications on this note as removed *****/
OriginalPubCod = Tml_DB_GetPubCodOfOriginalNote (Not->NotCod);
if (OriginalPubCod > 0)
Ntf_MarkNotifAsRemoved (Ntf_EVENT_TL_SHARE,OriginalPubCod);
Ntf_DB_MarkNotifAsRemoved (Ntf_EVENT_TL_SHARE,OriginalPubCod);
}

View File

@ -731,7 +731,7 @@ void Usr_GetUsrDataFromUsrCod (struct UsrData *UsrDat,
DB_FreeMySQLResult (&mysql_res);
/***** Get nickname and email *****/
Nck_GetNicknameFromUsrCod (UsrDat->UsrCod,UsrDat->Nickname);
Nck_DB_GetNicknameFromUsrCod (UsrDat->UsrCod,UsrDat->Nickname);
Mai_GetEmailFromUsrCod (UsrDat);
}
@ -6388,7 +6388,7 @@ void Usr_ShowFormsToSelectUsrListType (void (*FuncParams) (void *Args),void *Arg
Usr_LIST_AS_CLASS_PHOTO);
/* Number of columns in the class photo */
Frm_StartFormAnchor (Gbl.Action.Act, // Repeat current action
Frm_BeginFormAnchor (Gbl.Action.Act, // Repeat current action
Usr_USER_LIST_SECTION_ID);
Grp_PutParamsCodGrps ();
Usr_PutParamUsrListType (Usr_LIST_AS_CLASS_PHOTO);
@ -6407,7 +6407,7 @@ void Usr_ShowFormsToSelectUsrListType (void (*FuncParams) (void *Args),void *Arg
Usr_LIST_AS_LISTING);
/* See the photos in list? */
Frm_StartFormAnchor (Gbl.Action.Act, // Repeat current action
Frm_BeginFormAnchor (Gbl.Action.Act, // Repeat current action
Usr_USER_LIST_SECTION_ID);
Grp_PutParamsCodGrps ();
Usr_PutParamUsrListType (Usr_LIST_AS_LISTING);
@ -6432,7 +6432,7 @@ static void Usr_FormToSelectUsrListType (void (*FuncParams) (void *Args),void *A
extern const char *Txt_USR_LIST_TYPES[Usr_NUM_USR_LIST_TYPES];
/***** Begin form *****/
Frm_StartFormAnchor (Gbl.Action.Act, // Repeat current action
Frm_BeginFormAnchor (Gbl.Action.Act, // Repeat current action
Usr_USER_LIST_SECTION_ID);
Grp_PutParamsCodGrps ();
Usr_PutParamUsrListType (ListType);