From a711b1ba0a91301f01f50ba8135136e94f582393 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antonio=20Ca=C3=B1as=20Vargas?= Date: Thu, 25 Dec 2014 12:54:21 +0100 Subject: [PATCH] Version 14.40.9 --- swad_changelog.h | 3 +- swad_search.c | 2 +- swad_statistic.c | 680 +++++++++++++++++++++++++++++++++++------------ 3 files changed, 509 insertions(+), 176 deletions(-) diff --git a/swad_changelog.h b/swad_changelog.h index 6c7e71490..bdc952019 100644 --- a/swad_changelog.h +++ b/swad_changelog.h @@ -35,11 +35,12 @@ /****************************** Public constants *****************************/ /*****************************************************************************/ -#define Log_PLATFORM_VERSION "SWAD 14.40.8 (2014/12/24)" +#define Log_PLATFORM_VERSION "SWAD 14.40.9 (2014/12/25)" // 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 | tail -1 /* + Version 14.40.9 :Dic 25, 2014 Changes in HTML and CSS to validate HTML5 in W3C validator. (172986 lines) Version 14.40.8 :Dic 24, 2014 Changes in HTML and CSS to validate HTML5 in W3C validator. (172653 lines) Version 14.40.7 :Dic 23, 2014 Changes in HTML and CSS to validate HTML5 in W3C validator. (172552 lines) Version 14.40.6 :Dic 23, 2014 Changes in HTML and CSS to validate HTML5 in W3C validator. (172400 lines) diff --git a/swad_search.c b/swad_search.c index c912be761..026da97cf 100644 --- a/swad_search.c +++ b/swad_search.c @@ -234,7 +234,7 @@ static void Sch_PutFormToSearchWithWhatToSearchAndScope (Act_Action_t Action,Sco Act_FormStart (Action); Lay_StartRoundFrameTable10 (NULL,2,Txt_Search); fprintf (Gbl.F.Out,"" - ""); + ""); /***** Scope (whole platform, current centre, current degree or current course) *****/ fprintf (Gbl.F.Out,"
%s: ", diff --git a/swad_statistic.c b/swad_statistic.c index 47770e2e2..0f651c067 100644 --- a/swad_statistic.c +++ b/swad_statistic.c @@ -396,7 +396,7 @@ void Sta_AskSeeCrsAccesses (void) fprintf (Gbl.F.Out,"
" "" "" - "" - "" - "" + "" - "" - "" + "" - "" - "" + "" - "" - "" + "" - "" "", @@ -614,8 +629,11 @@ static void Sta_WriteSelectorCountType (void) /**** Count type *****/ fprintf (Gbl.F.Out,"" - "" - "" + "" - "" - "" + "" - "" + "
"); + ""); Lay_StartRoundFrameTable10 (NULL,0,NULL); /* Put list of users to select some users */ @@ -419,8 +419,12 @@ void Sta_AskSeeCrsAccesses (void) /***** Type of statistic *****/ fprintf (Gbl.F.Out,"
%s:", + "" + "%s:" + "", The_ClassFormul[Gbl.Prefs.Theme],Txt_distributed_by); if ((Gbl.Stat.ClicksStatType < Sta_ACC_CRS_PER_USR || Gbl.Stat.ClicksStatType > Sta_ACC_CRS_PER_ACTION) && @@ -442,7 +446,8 @@ void Sta_AskSeeCrsAccesses (void) /* Listing of clicks to this course */ fprintf (Gbl.F.Out,"
" + "" "" - "%s:" + "" + "%s:" + "" "
%s:", + "" + "%s:" + "", The_ClassFormul[Gbl.Prefs.Theme],Txt_Scope); Gbl.Scope.Allowed = 1 << Sco_SCOPE_PLATFORM | 1 << Sco_SCOPE_COUNTRY | @@ -558,8 +569,12 @@ void Sta_AskSeeGblAccesses (void) /***** Type of statistic *****/ fprintf (Gbl.F.Out,"
%s:", + "" + "%s:" + "", The_ClassFormul[Gbl.Prefs.Theme],Txt_distributed_by); if (Gbl.Stat.ClicksStatType < Sta_ACC_GBL_PER_DAYS || Gbl.Stat.ClicksStatType > Sta_ACC_GBL_PER_COURSE) @@ -594,7 +609,7 @@ static void Sta_PutSeeAccessesButton (void) extern const char *Txt_Show_visits; fprintf (Gbl.F.Out,"
" + "" "" "
%s:" + "" + "%s:" + "" "
%s:" + "" + "%s:" + "" "
" + "" "" ""); @@ -1456,7 +1477,7 @@ static void Sta_ShowDetailedAccessesList (unsigned long NumRows,MYSQL_RES *mysql Par_PutHiddenParamLong ("RowsPage",Gbl.Stat.RowsPerPage); Usr_PutHiddenParUsrCodAll (ActSeeAccCrs,Gbl.Usrs.Select.All); } - fprintf (Gbl.F.Out,"", + "" + "", Txt_Clicks, FirstRow,LastRow,Txt_of_PART_OF_A_TOTAL,NumRows, Txt_page,NumPagesBefore+1,Txt_of_PART_OF_A_TOTAL,NumPagsTotal); @@ -1489,7 +1512,7 @@ static void Sta_ShowDetailedAccessesList (unsigned long NumRows,MYSQL_RES *mysql Par_PutHiddenParamUnsigned ("RowsPage",(unsigned) Gbl.Stat.RowsPerPage); Usr_PutHiddenParUsrCodAll (ActSeeAccCrs,Gbl.Usrs.Select.All); } - fprintf (Gbl.F.Out,"" - "", + "", Gbl.ColorRows[Gbl.RowEvenOdd],NumRow); /* Write the user's ID if user is a student */ - fprintf (Gbl.F.Out,""); /* Write the first name and the surnames */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd],UsrDat.FullName); /* Write the user's role */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd], RoleFromLog < Rol_NUM_ROLES ? Txt_ROLES_SINGULAR_Abc[RoleFromLog][UsrDat.Sex] : "?"); /* Write the date (in row[3] is the date in YYYYMMDDHHMMSS format) */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd], Act_GetActionTextFromDB (ActCod,ActTxt)); else - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); /* Write the comments of the access */ - fprintf (Gbl.F.Out,"" @@ -1646,12 +1687,30 @@ static void Sta_ShowNumAccessesPerUsr (unsigned long NumRows,MYSQL_RES *mysql_re /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "" - "" - "" - "" - "" - "" + "" + "" + "" + "" + "" + "" "", Txt_No_INDEX, Txt_Photo, @@ -1673,11 +1732,15 @@ static void Sta_ShowNumAccessesPerUsr (unsigned long NumRows,MYSQL_RES *mysql_re /* Write the number of row */ fprintf (Gbl.F.Out,"" - "", + "", Gbl.ColorRows[Gbl.RowEvenOdd],NumRow); /* Show the photo */ - fprintf (Gbl.F.Out,""); /* Write the user's ID if user is a student in current course */ - fprintf (Gbl.F.Out,""); /* Write the name and the surnames */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd],UsrDat.FullName); /* Write user's role */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd], Txt_ROLES_SINGULAR_Abc[UsrDat.RoleInCurrentCrsDB][UsrDat.Sex]); @@ -1713,7 +1783,8 @@ static void Sta_ShowNumAccessesPerUsr (unsigned long NumRows,MYSQL_RES *mysql_re } else BarWidth = 0; - fprintf (Gbl.F.Out,"" - "" - "" - "" + "" + "" + "" "", Txt_Date, Txt_Day, @@ -1800,13 +1880,19 @@ static void Sta_ShowNumAccessesPerDays (unsigned long NumRows,MYSQL_RES *mysql_r /* Write the date */ fprintf (Gbl.F.Out,"" - "", + "", NumDayWeek == 6 ? "LOG_R" : "LOG", Date.Day,Date.Month,Date.Year % 100); /* Write the day of the week */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NumDayWeek == 6 ? "LOG_R" : "LOG", Txt_DAYS_SMALL[NumDayWeek]); @@ -1834,13 +1920,19 @@ static void Sta_ShowNumAccessesPerDays (unsigned long NumRows,MYSQL_RES *mysql_r /* Write the date */ fprintf (Gbl.F.Out,"" - "", + "", NumDayWeek == 6 ? "LOG_R" : "LOG", Date.Day,Date.Month,Date.Year % 100); /* Write the day of the week */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NumDayWeek == 6 ? "LOG_R" : "LOG", Txt_DAYS_SMALL[NumDayWeek]); @@ -1885,7 +1977,8 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES /***** Put a selector for the type of color *****/ fprintf (Gbl.F.Out,"" - "" - "" - "" - "" + "" + "" + "" "", Txt_Date, Txt_Day, GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH,Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); fprintf (Gbl.F.Out,"" - "" @@ -1960,7 +2063,10 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES for (Hour = 0; Hour < 24; Hour++) - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", GRAPH_DISTRIBUTION_PER_HOUR_HOUR_WIDTH,Hour); fprintf (Gbl.F.Out,""); @@ -2005,13 +2111,19 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES /* Write the date */ fprintf (Gbl.F.Out,"" - "", + "", NumDayWeek == 6 ? "LOG_R" : "LOG", Date.Day,Date.Month,Date.Year % 100); /* Write the day of the week */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NumDayWeek == 6 ? "LOG_R" : "LOG", Txt_DAYS_SMALL[NumDayWeek]); @@ -2051,13 +2163,19 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES /* Write the date */ fprintf (Gbl.F.Out,"" - "", + "", NumDayWeek == 6 ? "LOG_R" : "LOG", Date.Day,Date.Month,Date.Year % 100); /* Write the day of the week */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NumDayWeek == 6 ? "LOG_R" : "LOG", Txt_DAYS_SMALL[NumDayWeek]); @@ -2085,13 +2203,19 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES /* Write the date */ fprintf (Gbl.F.Out,"" - "", + "", NumDayWeek == 6 ? "LOG_R" : "LOG", Date.Day,Date.Month,Date.Year % 100); /* Write the day of the week */ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NumDayWeek == 6 ? "LOG_R" : "LOG", Txt_DAYS_SMALL[NumDayWeek]); @@ -2137,19 +2261,27 @@ static void Sta_DrawBarColors (Sta_ColorType_t ColorType,float MaxPagesGenerated /***** Write numbers from 0 to MaxPagesGenerated *****/ fprintf (Gbl.F.Out,"
"); + fprintf (Gbl.F.Out,""); if (FirstRow > 1) { sprintf (Gbl.Title,Txt_Show_previous_X_clicks, @@ -1470,9 +1491,11 @@ static void Sta_ShowDetailedAccessesList (unsigned long NumRows,MYSQL_RES *mysql fprintf (Gbl.F.Out,""); /* Write number of current page */ - fprintf (Gbl.F.Out,"" + fprintf (Gbl.F.Out,"" + "" "%s %lu-%lu %s %lu (%s %ld %s %lu)" - ""); + fprintf (Gbl.F.Out,""); if (LastRow < NumRows) { sprintf (Gbl.Title,Txt_Show_next_X_clicks, @@ -1546,27 +1569,38 @@ static void Sta_ShowDetailedAccessesList (unsigned long NumRows,MYSQL_RES *mysql /* Write the number of row */ fprintf (Gbl.F.Out,"
%ld " + "%ld " + "", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); ID_WriteUsrIDs (&UsrDat,(RoleFromLog == Rol_ROLE_STUDENT)); fprintf (Gbl.F.Out," %s " + "%s " + "%s " + "%s " + "", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); Dat_WriteDate (row[3]); fprintf (Gbl.F.Out," "); @@ -1578,14 +1612,21 @@ static void Sta_ShowDetailedAccessesList (unsigned long NumRows,MYSQL_RES *mysql if (sscanf (row[4],"%ld",&ActCod) != 1) Lay_ShowErrorAndExit ("Wrong action code."); if (ActCod >= 0) - fprintf (Gbl.F.Out,"%s " + "%s " + "" + "? " + "", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); Sta_WriteLogComments (LogCod); fprintf (Gbl.F.Out,"
%s%s%s%s%s%s" + "%s" + "" + "%s" + "" + "%s" + "" + "%s" + "" + "%s" + "" + "%s" + "
%ld " + "%ld " + "", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); ShowPhoto = Pho_ShowUsrPhotoIsAllowed (&UsrDat,PhotoURL); Pho_ShowUsrPhoto (&UsrDat, @@ -1687,17 +1750,24 @@ static void Sta_ShowNumAccessesPerUsr (unsigned long NumRows,MYSQL_RES *mysql_re fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); ID_WriteUsrIDs (&UsrDat,(UsrDat.RoleInCurrentCrsDB == Rol_ROLE_STUDENT)); fprintf (Gbl.F.Out," %s " + "%s " + "%s " + "%s " + "", + fprintf (Gbl.F.Out,"", Gbl.ColorRows[Gbl.RowEvenOdd]); if (BarWidth) fprintf (Gbl.F.Out,"\"\" ", @@ -1751,9 +1822,18 @@ static void Sta_ShowNumAccessesPerDays (unsigned long NumRows,MYSQL_RES *mysql_r /***** Write heading *****/ fprintf (Gbl.F.Out,"
%s %s %s" + "%s " + "" + "%s " + "" + "%s" + "
%02u/%02u/%02u " + "%02u/%02u/%02u " + "%s " + "%s " + "
%02u/%02u/%02u " + "%02u/%02u/%02u " + "%s " + "%s " + "
", + "", The_ClassFormul[Gbl.Prefs.Theme]); Act_FormStart (Gbl.CurrentAct); @@ -1943,15 +2036,25 @@ static void Sta_ShowDistrAccessesPerDaysAndHour (unsigned long NumRows,MYSQL_RES /***** Write heading *****/ fprintf (Gbl.F.Out,"
%s %s %s" + "%s " + "" + "%s " + "" + "%s" + "
", + "", GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH); Sta_DrawBarColors (SelectedColorType,MaxPagesGenerated); fprintf (Gbl.F.Out,"%02uh" + "%02uh" + "
%02u/%02u/%02u " + "%02u/%02u/%02u " + "%s " + "%s " + "
%02u/%02u/%02u " + "%02u/%02u/%02u " + "%s " + "%s " + "
%02u/%02u/%02u " + "%02u/%02u/%02u " + "%s " + "%s " + "
" "" - "", - (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2,(GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2); + "", + (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2, + (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2); for (Interval = 1; Interval <= 4; Interval++) { - fprintf (Gbl.F.Out,""); } - fprintf (Gbl.F.Out,"" "" @@ -2161,10 +2293,14 @@ static void Sta_DrawBarColors (Sta_ColorType_t ColorType,float MaxPagesGenerated NumColor++) { Sta_SetColor (ColorType,(float) NumColor,(float) GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH,&R,&G,&B); - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", R,G,B,Gbl.Prefs.IconsURL); } - fprintf (Gbl.F.Out,"
0" + "0" + "", - GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5,GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5); + fprintf (Gbl.F.Out,"", + GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5, + GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5); Sta_WriteFloatNum ((float) Interval * MaxPagesGenerated / 5.0); fprintf (Gbl.F.Out,"", - (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2,(GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2); + fprintf (Gbl.F.Out,"", + (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2, + (GRAPH_DISTRIBUTION_PER_HOUR_TOTAL_WIDTH/5)/2); Sta_WriteFloatNum (MaxPagesGenerated); fprintf (Gbl.F.Out,"
\"\"" + "\"\"" + "
"); + fprintf (Gbl.F.Out,"
"); } /*****************************************************************************/ @@ -2180,11 +2316,12 @@ static void Sta_DrawAccessesPerHourForADay (Sta_ColorType_t ColorType,float NumP Hour++) { Sta_SetColor (ColorType,NumPagesGenerated[Hour],MaxPagesGenerated,&R,&G,&B); - fprintf (Gbl.F.Out,"" - ""); + fprintf (Gbl.F.Out,"\" style=\"width:%upx; text-align:left;" + " background-color:#%02X%02X%02X;\">" + "", + GRAPH_DISTRIBUTION_PER_HOUR_HOUR_WIDTH,R,G,B); } } @@ -2283,8 +2420,14 @@ static void Sta_ShowNumAccessesPerWeeks (unsigned long NumRows,MYSQL_RES *mysql_ /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Week, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2326,7 +2469,10 @@ static void Sta_ShowNumAccessesPerWeeks (unsigned long NumRows,MYSQL_RES *mysql_ { /* Write week */ fprintf (Gbl.F.Out,"" - "%02u/%02u ", + "" + "%02u/%02u " + "", Date.Week,Date.Year % 100); /* Draw bar proportional to number of pages generated */ @@ -2350,7 +2496,10 @@ static void Sta_ShowNumAccessesPerWeeks (unsigned long NumRows,MYSQL_RES *mysql_ { /* Write week */ fprintf (Gbl.F.Out,"" - "%02u/%02u ", + "" + "%02u/%02u " + "", Date.Week,Date.Year % 100); /* Draw bar proportional to number of pages generated */ @@ -2380,8 +2529,14 @@ static void Sta_ShowNumAccessesPerMonths (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Month, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2423,7 +2578,10 @@ static void Sta_ShowNumAccessesPerMonths (unsigned long NumRows,MYSQL_RES *mysql { /* Write the month */ fprintf (Gbl.F.Out,"" - "%02u/%02u ", + "" + "%02u/%02u " + "", Date.Month,Date.Year % 100); /* Draw bar proportional to number of pages generated */ @@ -2446,7 +2604,10 @@ static void Sta_ShowNumAccessesPerMonths (unsigned long NumRows,MYSQL_RES *mysql { /* Write the month */ fprintf (Gbl.F.Out,"" - "%02u/%02u ", + "" + "%02u/%02u " + "", Date.Month,Date.Year % 100); /* Draw bar proportional to number of pages generated */ @@ -2532,7 +2693,8 @@ static void Sta_WriteAccessHour (unsigned Hour,float NumPagesGenerated,float Max { unsigned AltoBarra; - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", ColumnWidth); /* Draw bar with a height porportional to the number of clicks */ @@ -2636,21 +2798,24 @@ static void Sta_ShowAverageAccessesPerMinute (unsigned long NumRows,MYSQL_RES *m /***** X axis *****/ /* First division (left) */ fprintf (Gbl.F.Out,"" - "" - "\"\"" + "" + "\"\""" "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL,WIDTH_SEMIDIVISION_GRAPHIC); /* All the intermediate divisions */ for (i = 0; i < NUM_DIVISIONS_X*2; i++) - fprintf (Gbl.F.Out,"" - "\"\"" + fprintf (Gbl.F.Out,"" + "\"\""" "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL,WIDTH_SEMIDIVISION_GRAPHIC); /* Last division (right) */ - fprintf (Gbl.F.Out,"" - "\"\"" + fprintf (Gbl.F.Out,"" + "\"\""" "" "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL,WIDTH_SEMIDIVISION_GRAPHIC); @@ -2676,7 +2841,8 @@ static void Sta_WriteLabelsXAxisAccMin (float IncX,const char *Format) i <= NUM_DIVISIONS_X; i++, NumX += IncX) { - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", WIDTH_DIVISION_GRAPHIC); fprintf (Gbl.F.Out,Format,NumX); fprintf (Gbl.F.Out,""); @@ -2698,18 +2864,39 @@ static void Sta_WriteAccessMinute (unsigned Minute,float NumPagesGenerated,float fprintf (Gbl.F.Out,""); /***** Labels of the Y axis, and Y axis *****/ - if (!Minute) // If minute 0 - fprintf (Gbl.F.Out,"00h", + if (!Minute) + // If minute 0 + fprintf (Gbl.F.Out,"" + "00h" + "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL); - else if (Minute == (NUM_MINUTES_PER_DAY - 30)) // If 23:30 - fprintf (Gbl.F.Out,"24h", + else if (Minute == (NUM_MINUTES_PER_DAY - 30)) + // If 23:30 + fprintf (Gbl.F.Out,"" + "24h" + "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL); - else if (!(Minute % 30) && (Minute % 60)) // If minute is multiple of 30 but not of 60 (i.e.: 30, 90, 150...) - fprintf (Gbl.F.Out,"%02uh", + else if (!(Minute % 30) && (Minute % 60)) + // If minute is multiple of 30 but not of 60 (i.e.: 30, 90, 150...) + fprintf (Gbl.F.Out,"" + "%02uh" + "", WIDTH_SEMIDIVISION_GRAPHIC,Gbl.Prefs.IconsURL,(Minute + 30) / 60); /***** Start of cell for the graphic *****/ - fprintf (Gbl.F.Out,"", + fprintf (Gbl.F.Out,"", NUM_DIVISIONS_X*2,WIDTH_GRAPHIC,Gbl.Prefs.IconsURL, (Minute % 60) == 0 ? 'v' : 'h'); @@ -2717,7 +2904,9 @@ static void Sta_WriteAccessMinute (unsigned Minute,float NumPagesGenerated,float /***** Draw bar with anchura proporcional al number of clicks *****/ if (NumPagesGenerated != 0.0) if ((BarWidth = (unsigned) (((NumPagesGenerated * (float) WIDTH_GRAPHIC / MaxX)) + 0.5)) != 0) - fprintf (Gbl.F.Out,"\"\"", + fprintf (Gbl.F.Out,"\"\""", Gbl.Prefs.IconsURL, (Minute % 60) == 0 ? 'g' : 'b', @@ -2746,8 +2935,14 @@ static void Sta_ShowNumAccessesPerAction (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Action, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2779,11 +2974,17 @@ static void Sta_ShowNumAccessesPerAction (unsigned long NumRows,MYSQL_RES *mysql Lay_ShowErrorAndExit ("Wrong action code."); if (ActCod >= 0) fprintf (Gbl.F.Out,"" - "%s ", + "" + "%s " + "", Act_GetActionTextFromDB (ActCod,ActTxt)); else fprintf (Gbl.F.Out,"" - "? "); + "" + "? " + ""); /* Draw bar proportional to number of pages generated */ NumPagesGenerated = Str_GetFloatNumFromStr (row[1]); @@ -2808,8 +3009,14 @@ static void Sta_ShowNumAccessesPerPlugin (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Plugin, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2840,7 +3047,8 @@ static void Sta_ShowNumAccessesPerPlugin (unsigned long NumRows,MYSQL_RES *mysql if (sscanf (row[0],"%ld",&Plg.PlgCod) != 1) Lay_ShowErrorAndExit ("Wrong plugin code."); fprintf (Gbl.F.Out,"" - ""); + ""); if (Plg_GetDataOfPluginByCod (&Plg)) fprintf (Gbl.F.Out,"%s",Plg.Name); else @@ -2870,8 +3078,14 @@ static void Sta_ShowNumAccessesPerWSFunction (unsigned long NumRows,MYSQL_RES *m /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Function, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2902,7 +3116,10 @@ static void Sta_ShowNumAccessesPerWSFunction (unsigned long NumRows,MYSQL_RES *m if (sscanf (row[0],"%ld",&FunCod) != 1) Lay_ShowErrorAndExit ("Wrong function code."); fprintf (Gbl.F.Out,"" - "%s ", + "" + "%s " + "", Svc_GetFunctionNameFromFunCod (FunCod)); /* Draw bar proportional to number of pages generated */ @@ -2928,8 +3145,14 @@ static void Sta_ShowNumAccessesPerBanner (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s " - "%s" + "" + "%s " + "" + "" + "%s" + "" "", Txt_Banner, Txt_STAT_TYPE_COUNT_CAPS[Gbl.Stat.CountType]); @@ -2961,10 +3184,12 @@ static void Sta_ShowNumAccessesPerBanner (unsigned long NumRows,MYSQL_RES *mysql Lay_ShowErrorAndExit ("Wrong banner code."); Ban_GetDataOfBannerByCod (&Ban); fprintf (Gbl.F.Out,"" - "" + "" "" "\"%s\""" + " style=\"width:60px; height:20px;" + " margin:0 8px 4px 0;\" />" "", Ban.WWW, Ban.FullName, @@ -2996,9 +3221,18 @@ static void Sta_ShowNumAccessesPerDegree (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s" - "%s" - "%s" + "" + "%s" + "" + "" + "%s" + "" + "" + "%s" + "" "", Txt_No_INDEX, Txt_Degree, @@ -3033,10 +3267,12 @@ static void Sta_ShowNumAccessesPerDegree (unsigned long NumRows,MYSQL_RES *mysql /* Write ranking of this degree */ fprintf (Gbl.F.Out,"" - ""); + ""); if (DegCod >= 0) fprintf (Gbl.F.Out,"%lu",++Ranking); - fprintf (Gbl.F.Out," "); + fprintf (Gbl.F.Out," " + ""); /* Write degree */ Sta_WriteDegree (DegCod); @@ -3071,11 +3307,26 @@ static void Sta_ShowNumAccessesPerCourse (unsigned long NumRows,MYSQL_RES *mysql /***** Write heading *****/ fprintf (Gbl.F.Out,"" - "%s" - "%s" - "%s" - "%s" - "%s" + "" + "%s" + "" + "" + "%s" + "" + "" + "%s" + "" + "" + "%s" + "" + "" + "%s" + "" "", Txt_No_INDEX, Txt_Degree, @@ -3115,7 +3366,8 @@ static void Sta_ShowNumAccessesPerCourse (unsigned long NumRows,MYSQL_RES *mysql /* Write ranking of this course */ fprintf (Gbl.F.Out,"" - ""); + ""); if (CrsOK) fprintf (Gbl.F.Out,"%lu",++Ranking); fprintf (Gbl.F.Out," "); @@ -3124,12 +3376,16 @@ static void Sta_ShowNumAccessesPerCourse (unsigned long NumRows,MYSQL_RES *mysql Sta_WriteDegree (Crs.DegCod); /* Write degree year */ - fprintf (Gbl.F.Out,"%s ", + fprintf (Gbl.F.Out,"" + "%s " + "", CrsOK ? Txt_YEAR_OF_DEGREE[Crs.Year] : "-"); /* Write course, including link */ - fprintf (Gbl.F.Out,""); + fprintf (Gbl.F.Out,""); if (CrsOK) { Act_FormGoToStart (ActSeeCrsInf); @@ -3152,7 +3408,7 @@ static void Sta_ShowNumAccessesPerCourse (unsigned long NumRows,MYSQL_RES *mysql } /*****************************************************************************/ -/*********************** Write titulation with an icon ***********************/ +/************************* Write degree with an icon *************************/ /*****************************************************************************/ static void Sta_WriteDegree (long DegCod) @@ -3160,8 +3416,10 @@ static void Sta_WriteDegree (long DegCod) extern const char *Txt_Clicks_without_degree_selected; struct Degree Deg; - fprintf (Gbl.F.Out,"= 0) + fprintf (Gbl.F.Out," 0) { Deg.DegCod = DegCod; Deg_GetDataOfDegreeByCod (&Deg); @@ -3187,7 +3445,8 @@ static void Sta_DrawBarNumClicks (char Color,float NumPagesGenerated,float MaxPa { unsigned BarWidth; - fprintf (Gbl.F.Out,""); + fprintf (Gbl.F.Out,""); if (NumPagesGenerated != 0.0) { /* Draw bar with a with proportional to the number of clicks */ @@ -3321,8 +3580,9 @@ void Sta_ReqUseOfPlatform (void) /***** Type of statistic *****/ Lay_StartRoundFrameTable10 (NULL,0,NULL); fprintf (Gbl.F.Out,"" - "" - "
    ", + "" + "
      ", The_ClassFormul[Gbl.Prefs.Theme]); for (UseStatType = (Sta_UseStatType_t) 0; UseStatType < Sta_NUM_TYPES_USE_STATS; @@ -3561,14 +3821,30 @@ static void Sta_GetAndShowNumCtysInSWAD (void) /***** Write number of countries *****/ fprintf (Gbl.F.Out,"" - "%s:" - "%u" - "%u" - "%u" - "%u" - "%u" - "%u" - "%u" + "" + "%s:" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" "", Txt_Countries, NumCtysTotal, @@ -3654,14 +3930,28 @@ static void Sta_GetAndShowNumInssInSWAD (void) /***** Write number of institutions *****/ fprintf (Gbl.F.Out,"" - "%s:" - "%u" - "" - "%u" - "%u" - "%u" - "%u" - "%u" + "" + "%s:" + "" + "" + "%u" + "" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" "", Txt_Institutions, NumInssTotal, @@ -3740,14 +4030,26 @@ static void Sta_GetAndShowNumCtrsInSWAD (void) /***** Write number of centres *****/ fprintf (Gbl.F.Out,"" - "%s:" - "%u" - "" - "" - "%u" - "%u" - "%u" - "%u" + "" + "%s:" + "" + "" + "%u" + "" + "" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" "", Txt_Centres, NumCtrsTotal, @@ -3819,14 +4121,24 @@ static void Sta_GetAndShowNumDegsInSWAD (void) /***** Write number of degrees *****/ fprintf (Gbl.F.Out,"" - "%s:" - "%u" - "" - "" - "" - "%u" - "%u" - "%u" + "" + "%s:" + "" + "" + "%u" + "" + "" + "" + "" + "" + "%u" + "" + "" + "%u" + "" + "" + "%u" + "" "", Txt_Degrees, NumDegsTotal, @@ -3891,14 +4203,22 @@ static void Sta_GetAndShowNumCrssInSWAD (void) /***** Write number of degrees *****/ fprintf (Gbl.F.Out,"" - "%s:" - "%u" - "" - "" - "" - "" - "%u" - "%u" + "" + "%s:" + "" + "" + "%u" + "" + "" + "" + "" + "" + "" + "%u" + "" + "" + "%u" + "" "", Txt_Courses, NumCrssTotal, @@ -4168,12 +4488,24 @@ static void Sta_WriteRowStatsExpTrees (Brw_FileBrowser_t FileZone,const char *Na 0.0); } fprintf (Gbl.F.Out,"" - "%s" - "%s" - "%s" - "%u" - "%lu" - "%lu" + "" + "%s" + "" + "" + "%s" + "" + "" + "%s" + "" + "" + "%u" + "" + "" + "%lu" + "" + "" + "%lu" + "" "", ClassData,StyleTableCell,NameOfFileZones, ClassData,StyleTableCell,StrNumCrss,