mirror of
https://github.com/acanas/swad-core.git
synced 2024-06-03 07:15:26 +02:00
Version 15.224.3
This commit is contained in:
parent
90c4217ba9
commit
d3c0891ade
|
@ -545,7 +545,8 @@ a:hover /* Default ==> underlined */
|
||||||
.TAB_ON_YELLOW {background-color:rgba(255, 242, 189, 0.99);}
|
.TAB_ON_YELLOW {background-color:rgba(255, 242, 189, 0.99);}
|
||||||
|
|
||||||
.TAB_OFF_WHITE {background-color:#D4D4D4;}
|
.TAB_OFF_WHITE {background-color:#D4D4D4;}
|
||||||
.TAB_OFF_GREY {background-color:#D4D4D4;}
|
/*.TAB_OFF_GREY {background-color:#D4D4D4;}*/
|
||||||
|
.TAB_OFF_GREY {background-color:#AEA79F;}
|
||||||
.TAB_OFF_BLUE {background-color:#CAE1E8;}
|
.TAB_OFF_BLUE {background-color:#CAE1E8;}
|
||||||
.TAB_OFF_YELLOW {background-color:#FADE94;}
|
.TAB_OFF_YELLOW {background-color:#FADE94;}
|
||||||
|
|
||||||
|
|
|
@ -129,13 +129,14 @@
|
||||||
/****************************** Public constants *****************************/
|
/****************************** Public constants *****************************/
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
#define Log_PLATFORM_VERSION "SWAD 15.224.2 (2016-06-12)"
|
#define Log_PLATFORM_VERSION "SWAD 15.224.3 (2016-06-13)"
|
||||||
#define CSS_FILE "swad15.218.css"
|
#define CSS_FILE "swad15.218.css"
|
||||||
#define JS_FILE "swad15.216.js"
|
#define JS_FILE "swad15.216.js"
|
||||||
|
|
||||||
// Number of lines (includes comments but not blank lines) has been got with the following command:
|
// Number of lines (includes comments but not blank lines) has been got with the following command:
|
||||||
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
|
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
|
||||||
/*
|
/*
|
||||||
|
Version 15.224.3: Jun 13, 2016 Fix bug while finding cell content in file of marks. (202267 lines)
|
||||||
Version 15.224.2: Jun 12, 2016 Info about number of files is moved to bottom of file browsers. (202266 lines)
|
Version 15.224.2: Jun 12, 2016 Info about number of files is moved to bottom of file browsers. (202266 lines)
|
||||||
Version 15.224.1: Jun 12, 2016 Change in layout of file browsers. (202266 lines)
|
Version 15.224.1: Jun 12, 2016 Change in layout of file browsers. (202266 lines)
|
||||||
Version 15.224: Jun 12, 2016 Now a user can unfollow users followed by him/her whose profile is not visible.
|
Version 15.224: Jun 12, 2016 Now a user can unfollow users followed by him/her whose profile is not visible.
|
||||||
|
|
|
@ -487,6 +487,7 @@ static bool Mrk_GetUsrMarks (FILE *FileUsrMarks,struct UsrData *UsrDat,
|
||||||
// Users' IDs are always stored internally in capitals and without leading zeros
|
// Users' IDs are always stored internally in capitals and without leading zeros
|
||||||
Str_RemoveLeadingZeros (UsrIDFromTable);
|
Str_RemoveLeadingZeros (UsrIDFromTable);
|
||||||
Str_ConvertToUpperText (UsrIDFromTable);
|
Str_ConvertToUpperText (UsrIDFromTable);
|
||||||
|
|
||||||
if (ID_CheckIfUsrIDIsValid (UsrIDFromTable))
|
if (ID_CheckIfUsrIDIsValid (UsrIDFromTable))
|
||||||
// A valid user's ID is found in the first column of table, and stored in UsrIDFromTable.
|
// A valid user's ID is found in the first column of table, and stored in UsrIDFromTable.
|
||||||
// Compare UsrIDFromTable with all the confirmed user's IDs in list
|
// Compare UsrIDFromTable with all the confirmed user's IDs in list
|
||||||
|
|
137
swad_string.c
137
swad_string.c
|
@ -1949,6 +1949,8 @@ char *Str_GetCellFromHTMLTableSkipComments (FILE *FileSrc,char *Str,int MaxLengt
|
||||||
long PosTD;
|
long PosTD;
|
||||||
int i = 0;
|
int i = 0;
|
||||||
int Ch;
|
int Ch;
|
||||||
|
bool EndCellFound = false;
|
||||||
|
bool DirectiveFound;
|
||||||
bool SpaceFound;
|
bool SpaceFound;
|
||||||
char StrAux[1+1]; // To find next "/td>" or "nbsp;"
|
char StrAux[1+1]; // To find next "/td>" or "nbsp;"
|
||||||
|
|
||||||
|
@ -1973,87 +1975,86 @@ char *Str_GetCellFromHTMLTableSkipComments (FILE *FileSrc,char *Str,int MaxLengt
|
||||||
|
|
||||||
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
||||||
|
|
||||||
for (;;)
|
for (EndCellFound = false;
|
||||||
|
!EndCellFound;
|
||||||
|
)
|
||||||
{
|
{
|
||||||
if ((Ch = Str_ReadCharAndSkipComments (FileSrc,Str_SKIP_HTML_COMMENTS)) == EOF) // Set pointer to '<' if not comment, or to first character after comment if comment
|
if ((Ch = Str_ReadCharAndSkipComments (FileSrc,Str_SKIP_HTML_COMMENTS)) == EOF) // Set pointer to '<' if not comment, or to first character after comment if comment
|
||||||
break;
|
break;
|
||||||
|
|
||||||
/***** Skip directives except </td> *****/
|
/***** Skip directives except </td> *****/
|
||||||
if (Ch == (int) '<') // Start of directive, not a comment
|
DirectiveFound = (Ch == (int) '<');
|
||||||
|
|
||||||
|
if (DirectiveFound) // Start of directive, not a comment
|
||||||
{
|
{
|
||||||
/* Check if it's </td> */
|
/* Check if it's </td> */
|
||||||
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"/"))
|
if (!strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"/")) // It's </
|
||||||
{ // It's not </
|
if (!strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"t")) // It's </t
|
||||||
Str_FindStrInFileBack (FileSrc,"<",Str_NO_SKIP_HTML_COMMENTS); // Skip directive backward
|
if (!strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"d")) // It's </td
|
||||||
|
if (!strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),">")) // It's </td>
|
||||||
|
EndCellFound = true; // </td> found
|
||||||
|
|
||||||
|
if (!EndCellFound)
|
||||||
|
{
|
||||||
|
/* Skip directive */
|
||||||
|
Str_FindStrInFileBack (FileSrc,"<",Str_NO_SKIP_HTML_COMMENTS);
|
||||||
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
||||||
continue;
|
|
||||||
}
|
}
|
||||||
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"t"))
|
|
||||||
{ // It's not </t
|
|
||||||
Str_FindStrInFileBack (FileSrc,"<",Str_NO_SKIP_HTML_COMMENTS); // Skip directive backward
|
|
||||||
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"d"))
|
|
||||||
{ // It's not </td
|
|
||||||
Str_FindStrInFileBack (FileSrc,"<",Str_NO_SKIP_HTML_COMMENTS); // Skip directive backward
|
|
||||||
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),">"))
|
|
||||||
{ // It's not </td>
|
|
||||||
Str_FindStrInFileBack (FileSrc,"<",Str_NO_SKIP_HTML_COMMENTS); // Skip directive backward
|
|
||||||
Str_FindStrInFile (FileSrc,">",Str_NO_SKIP_HTML_COMMENTS);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
break; // If it's </td>
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SpaceFound = false;
|
if (!EndCellFound)
|
||||||
|
|
||||||
/***** Skip *****/
|
|
||||||
if (Ch == (int) '&')
|
|
||||||
{
|
{
|
||||||
/* Ver if no it's */
|
if (DirectiveFound)
|
||||||
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"n"))
|
Ch = (int) ' '; // Replace directive for ' ' (separator)
|
||||||
{ // It's not &n
|
else
|
||||||
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
{
|
||||||
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
/***** Check for space or *****/
|
||||||
}
|
SpaceFound = false;
|
||||||
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"b"))
|
|
||||||
{ // It's not &nb
|
if (Ch == (int) '&')
|
||||||
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
{
|
||||||
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
/* Check for (case insensitive) */
|
||||||
}
|
if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"n"))
|
||||||
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"s"))
|
{ // It's not &n
|
||||||
{ // It's not &nbs
|
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
||||||
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
||||||
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
}
|
||||||
}
|
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"b"))
|
||||||
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"p"))
|
{ // It's not &nb
|
||||||
{ // It's not  
|
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
||||||
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
||||||
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
}
|
||||||
}
|
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"s"))
|
||||||
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),";"))
|
{ // It's not &nbs
|
||||||
{ // It's not
|
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
||||||
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
||||||
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
}
|
||||||
}
|
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),"p"))
|
||||||
else // It's
|
{ // It's not  
|
||||||
SpaceFound = true;
|
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
||||||
|
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
||||||
|
}
|
||||||
|
else if (strcasecmp (Str_GetNextStrFromFileConvertingToLower (FileSrc,StrAux,1),";"))
|
||||||
|
{ // It's not
|
||||||
|
Str_FindStrInFileBack (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Back until &
|
||||||
|
Str_FindStrInFile (FileSrc,"&",Str_NO_SKIP_HTML_COMMENTS); // Skip &
|
||||||
|
}
|
||||||
|
else // It's
|
||||||
|
SpaceFound = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/***** Skip spaces *****/
|
||||||
|
if (isspace (Ch) ||
|
||||||
|
Ch == 0xA0) // Unicode translation for
|
||||||
|
SpaceFound = true;
|
||||||
|
|
||||||
|
if (SpaceFound)
|
||||||
|
Ch = (int) ' '; // Replace any kind of space for ' ' (separator)
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i < MaxLength)
|
||||||
|
Str[i++] = (char) Ch;
|
||||||
}
|
}
|
||||||
|
|
||||||
/***** Skip spaces *****/
|
|
||||||
if (isspace (Ch) ||
|
|
||||||
Ch == 0xA0) // Unicode translation for
|
|
||||||
SpaceFound = true;
|
|
||||||
|
|
||||||
if (SpaceFound)
|
|
||||||
Ch = (int) ' ';
|
|
||||||
|
|
||||||
if (i < MaxLength)
|
|
||||||
Str[i++] = (char) Ch;
|
|
||||||
}
|
}
|
||||||
Str[i] = '\0';
|
Str[i] = '\0';
|
||||||
return Str;
|
return Str;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user