/statrix/includes/constants.phpb accessLevelmonthsstatrix_whois_errnostatrix_whois_errstrstatrixActionsweekdayswpdbstatrixActions;;arrayKzstatrix_whois_errstr;;_ q weekdays;;arrayPstatrix_whois_errno;;Z * accessLevel;;>months;;arrayU j STATRIX_DIR 'statrix' string Statrix directory namemSTATRIX_MAIN_FILE 'statrix.php' string Statrix main file nameSTATRIX_DEFAULT_ACCESS_LEVEL8JoQ  int Statrix default access levelH STATRIX_TABLE$wpdb->prefix . 'statrix' string Statrix table namevSTATRIX_DEFAULT_ACTION 'overview'GfN Istring the key of the Statrix default action in the Statrix actions array$statrixActionsESTATRIX_WHOIS_TIMEOUT15 int whois timeout in secondsv v y v statrixE-sense Copyright (c) 2008, E-sense^/statrix/includes/hits.phploadHits"This function loads the Hits mode.string Statrix action STATRIX_DIRSTATRIX_MAIN_FILE$statrixActionsgetBlogDomain() printPages()a(*G3#statrix_action<<<#voidloadHits_GET_POSTaditionalCriteriabrowser emptyReferer hitsCountiplimitoffsetorderospagerefererresultsrowrss selected10 selected20 selected50sortstatrix_action<<<#statrixActionsusername visitorsPagewpdb selected20;;loadHits'?'aditionalCriteria;;loadHits"selected50;;loadHits'yresults;;loadHits%IBlimit;;loadHitsBJorder;;loadHitss@tA statrix_action;;loadHits*selected10;;loadHits'page;;loadHitsB9sort;;loadHits c>d?e??f?lg?h?i?j@k@:n@fhitsCount;;loadHits%: Peter - externalize the sorting algorithm, it is the same in hits.php, and it should be implemented only once, and used in both locations.TASKTODO=>=`] y   399tvt EKK'--GIG-33HJH *,*020  &&&&&&''''''( ( ( (0(6(6(H(J(H(m(s(s((().)4)4)F)H)F)I)O)O)g)i)g)}))))))))*'*)*'*`*f*f*x*z*x*{***********++++X+Z+X+++,,,,, , ,$,&,$,:,@,@,V,X,V,,,,,,--!-!-3-5-3-6-<-<-T-V-T-j-p-p------....}................./6/</</z/|/z////////////00000 00k0q0q0001111/111/1218181P1R1P1f1l1l1111112222I2O2O2a2c2a2d2j2j2222222222333A3C3A3333333333333444444e4k4k4444444444555555157575M5O5M5555556D6J6J6\6^6\6_6e6e6}66}6666666667;7=7;7t7z7z7777777777777778&8,8,8j8l8j8888888889999$9*9*9@9B9@999999: :::":$:":%:+:+:C:E:C:Y:_:_:u:w:u:::;;;;l;r;r;;;;;;;;;;;;;;;< <&<&Copyright (c) 2008, E-sense^! /statrix/resources/index.php/statrix/libs/index.php/statrix/includes/index.php/statrix/includes/options.php loadOptions%This function loads the Options mode.string Statrix action$statrixActionsagstatrix_actionvoid loadOptions_POSTresultsrowstatrix_actionstatrixActionswpdbstatrix_action;;loadOptionsresults;;loadOptionsc: check the options belowTASKTODOVrV+Y[Yioo Y _ _    3 9 9 s u s |     y      U [ [    - 3 3 n p n w } }   }/55SUSntt.44PRP_eehkh statrixE-sense Copyright (c) 2008, E-sense^[/statrix/includes/overview.php loadOverview&This function loads the Overview mode. STATRIX_DIRSTATRIX_MAIN_FILE STATRIX_TABLESTATRIX_DEFAULT_ACTION$statrixActionsgetDataFields()getTimeFields()getBlogDomain()a_a j%void loadOverviewiresultsrowstatrixActionswpdbresults;;loadOverview&i;;loadOverviewp bhh  #))dfdx~~5;;prpPVVxzxlrr   !  statrixE-sense Copyright (c) 2008, E-sense^'/statrix/includes/resourceFunctions.phpgetOs"This function returns the OS name.string user agentstring OS name STATRIX_DIRa agent string getBrowser'This function returns the browser name.string user agentstring browser name STATRIX_DIR5agent5stringgetSearchEngine-This function returns the search engine name.string user referrerstring search engine name STATRIX_DIR implementation KreferrerKstring getQueryPairs curl cunknowngetSearchTerms.This function returns the search engine terms.s string user referrernull implementation ( * ^ 3ureferrer B B Bunull getSpider&This function returns the spider name.string user agentstring spider name STATRIX_DIR `  * agent string getRssType(This function returns the rss feed type.string user request URIstring rss feed type STATRIX_DIRgetBlogDomain() ,   uri string getQueryPairshost parsed_urlquerytaburl c getRssTypeuri  getSpideragent idlinelinesnamespider getBrowseragent5browseridlinelinesnamegetSearchEngine agentiidkeylinelinesnamenomereferrerK searchEnginetaburl variablesgetSearchTermsreferrer B B BugetOsagent idlinelinesnameoshost;;getQueryPairsf (lines;;getSearchEnginearrayOlines;;getBrowserarray7agent;;getBrowsermixed6tab;;getQueryPairsmixede referrer;;getSearchTerms *tab;;getSearchEnginearrayY B agent;;getOsmixed!parsed_url;;getQueryPairsmixedd agent;;getSpider mixed query;;getQueryPairsh ^url;;getQueryPairs uri;;getRssType agent;;getSearchEnginemixedNvariables;;getSearchEngine-Vlines;;getSpiderarray 3i;;getSearchEngineintW referrer;;getSearchEngine lines;;getOsarray"(implementationTASK@todoxxIimplementationTASK@todo  $ s statrixE-sense Copyright (c) 2008, E-sense^!/statrix/includes/searchTerms.php%loadSearchTerms*This function loads the Search Terms mode.string Statrix action$statrixActionsa1statrix_actionvoidloadSearchTermsstatrix_actionstatrixActionsstatrix_action;;loadSearchTerms252 statrixE-sense Copyright (c) 2008, E-sense^S/statrix/includes/spiders.php loadSpiders%This function loads the Spiders mode.string Statrix action$statrixActions printPages()a statrix_action void loadSpiders_GET_POSTlimitoffsetorderpageresultsrow selected10 selected20 selected50sort spidersCountstatrix_action statrixActionswpdb statrix_action;;loadSpiderspage;;loadSpidersselected20;;loadSpiders?A"selected50;;loadSpiders@order;;loadSpidersxspidersCount;;loadSpiders3"limit;;loadSpidersresults;;loadSpiders25selected10;;loadSpiders>tsort;;loadSpiders|},~S}2`b`$$JMJcii{}{         Y _ _       ( * ( > D D Z \ Z         F L L    +11GIGTZZmompvv gig  X^^##6869??WYWmss/1/ioo%%z|z399OQO.44GIGJPPhjh~>@>%++ statrixE-sense Copyright (c) 2008, E-sense^!/statrix/resources/statrix.js.phpa printHitsLineLThis function prints the hits for time period, specified (or not) by filter. STATRIX_TABLE $weekdays drawChart()! 2void printPagesBar+This function prints the top fifteen pages. STATRIX_TABLEgetBlogDomain() drawChart() !!%!voidprintBrowsersPie,This function prints the browsers pie chart. STATRIX_TABLE drawChart()% %n%p&%yvoid printOsPie&This function prints the os pie chart. STATRIX_TABLE drawChart()&']'_('h void drawChartThis functions draws a chart.string HTML element ID"string chart type (bar, line, pie)array chart's datasetsarray chart's labels(){)}/v)#element)))#type)))#datasets)))#arraylabels)))#arrayunknown_GETstatrix_action drawChart datasetdatasets)))#datsetselement)))#ikeylabellabels)))#numtype)))#valueprintBrowsersPiedatasetslabelsresultsrowwpdb printOsPiedatasetslabelsresultsrowwpdb printHitsLine_GETcriteriadatasetsdateFromdateTo difference innerGroupBy innerLimit innerOrderByinnerSelectItemslabelsorderByresultsrowsql timePeriod timestampFrom timestampTotmpweekdayswpdb printPagesBardatasetsilabelsresultsrowwpdb criteria;;printHitsLinearrayrlabels;;printPagesBararray$HinnerGroupBy;;printHitsLine~wHmelement;;drawChart)}datasets;;printBrowsersPiearray&AtimePeriod;;printHitsLinewSz#|datasets;;drawChartarray)}dateTo;;printHitsLinestringBstringI stringP !stringW =string] stringa stringnMsql;;printHitsLine tmp;;printHitsLinestringistringltimestampFrom;;printHitsLine int?2intE <intH intL ZintO intS uintV Z intb6stringji;;printPagesBar$WinnerSelectItems;;printHitsLinearrayxllabels;;printBrowsersPiearray&Uresults;;printPagesBar!=labels;;drawChartarray)}datasets;;printOsPiearray(labels;;printHitsLinearrayhstatrix_action;;datasets;;printPagesBararray$4 i;;drawChart6,kD-dateFrom;;printHitsLinestringAstringG stringN stringU string\ string` Astringm8results;;printHitsLine2timestampTo;;printHitsLineint@tintF dintM intT int[ intc^stringktype;;drawChart)}innerOrderBy;;printHitsLinelorderBy;;printHitsLine%labels;;printOsPiearray(%results;;printOsPie'results;;printBrowsersPie%datasets;;printHitsLinearrayTinnerLimit;;printHitsLine../../../../wp-config.php[g!../../../../wp-includes/wp-db.php../includes/constants.phpSyntax Error: expecting: '::'ERROR,,,9Syntax Error: unexpected '$key'ERROR,,,9 Syntax ErrorERROR,,,9 Syntax ErrorERROR,,,9 Syntax ErrorERROR,,,9 Syntax ErrorERROR,,,9/x/{/x statrixE-sense Copyright (c) 2008, E-senseX/statrix/statrix.php prepareTool?This function prepares the Statrix environment for proper work.0(Necessary because the $wpdb->get_var() method.)STATRIX_DEFAULT_ACCESS_LEVEL STATRIX_TABLE $accessLevelZFvoid addToolMenu:This function builds the Statrix plugin menu and submenus.STATRIX_MAIN_FILE$statrixActions $accessLevel\voidloadToolUThis function loads the specific tool, depending on the statrix_action GET parameter.STATRIX_DEFAULT_ACTION$statrixActionsgetStatrixAction()fhqvoid addJavaScript3This functon adds javascript files in admin header. STATRIX_DIRSTATRIX_DEFAULT_ACTIONgetStatrixAction()xzvoid collectDataIThis function collects the visitor's data and inserts it in the database.  STATRIX_TABLEgetRequestUri()isUserExcluded()isIpExcluded()getOs() getBrowser() getRssType() getSpider()getSearchEngine()getSearchTerms()<>"Gvoid getRequestUri(This function returns the requested URI.string user requested URI $decide if this function is necessary"#6#8%K#AstringisUserExcludedBThis function checks if the user is excluded from data collecting.string username>bool returns true if the user is excluded from data collecting implementation%M&&&g&# username&2&2&2 bool isIpExcludedHThis function checks if the IP address is excluded from data collecting.string user IP address;bool return true if the IP is excluded from data collecting implementation&i'>'@''Iip'V'V'VboolgetStatrixAction)This function returns the statrix action.string Statrix actionSTATRIX_DEAULT_ACTION$statrixActions'(()1(!!string getBlogDomainCThis function returns the blog domain from the Settings panel data.string blog domain)3))*^)3string printPages(This function prints the paging elements!int count of the items for paging!int limit of the items for pagingstring Statrix action1array additional arguments for building the links STATRIX_DIRSTATRIX_MAIN_FILE*`+y+{2?+C itemsCount+++C itemsLimit+++C statrixAction+++CadditionalArgs+++CarrayarrayvoidprintDateFields(This function prints date select fields.string HTML day element IDstring HTML month element IDstring HTML year element IDstring built date select fields STATRIX_TABLE$months2A3;3=8V3F{ dayFieldName3V3V3V{monthFieldName3d3e3e{ yearFieldName3u3v3v{ isDisabled333{falsestringprintTimeFields(This function prints time select fields.string HTML hour element IDstring HTML minutes element IDstring built time select fields8X99 <9 hourField9"9"9" minutesField9-9.9. isDisabled9<9=9=falsestring statrixWhoisRThis function gets the whois information about the specified domain or IP address.string IP addressstring whois responseSTATRIX_WHOIS_TIMEOUT$statrix_whois_errno$statrix_whois_errstr<<=>= query===string getBlogDomaindomain statrixWhoisfquery===responseserverstatrix_whois_errnostatrix_whois_errstr getRequestUri_SERVER requestUri isIpExcludedip'V'V'VgetStatrixAction_GET actionData actionNamestatrixActions addJavaScript_GETkeyvalue addToolMenu accessLevel actionData actionNamestatrixActionsprintDateFields  dateFields dayFieldName3V3V3V{i isDisabled333{keymonthFieldName3d3e3e{monthsresultsrowvaluewpdb yearFieldName3u3v3v{printTimeFields hourField9"9"9"i isDisabled9<9=9= minutesField9-9.9. timeFields printPages_GETadditionalArgs+++C itemsCount+++C itemsLimit+++Ckeypages statrixAction+++Cvalue prepareTool accessLevelpagesql wp_db_versionwpdbisUserExcludedusername&2&2&2  collectData _SERVERagentipreferrer requestUriresultssqluserdatawpdbloadTool actionData actionNamestatrixActionspages;;printPagesfloatD+statrixAction;;printPages+{sql;;prepareToolnrequestUri;;collectDatastringminutesField;;printTimeFields9 hourField;;printTimeFields9 sql;;collectData itemsCount;;printPages+{domain;;getBlogDomainmixed5)itemsLimit;;printPages+{isDisabled;;printTimeFields9 isDisabled;;printDateFields3=i;;printDateFields4requestUri;;getRequestUri#bdayFieldName;;printDateFields3=monthFieldName;;printDateFields3=results;;printDateFields7;accessLevel;;prepareToolLN Ipage;;prepareToolqsyearFieldName;;printDateFields3=additionalArgs;;printPagesarray+{query;;statrixWhois=response;;statrixWhoisstring>pserver;;statrixWhois=bip;;collectDataf;;statrixWhoisresource=i;;printTimeFields:;mresults;;collectData"ip;;isIpExcluded'@username;;isUserExcluded&includes/constants.php9_E#includes/resourceFunctions.phpam$includes/overview.php%includes/hits.php&includes/searchTerms.php'includes/spiders.php)(includes/options.php+O7)includes/whois.phpQs]*g: Peter - Use the correct wordpress mechanism for handling actions, instead of the loadTool() function.TASKTODO;;$decide if this function is necessaryTASK@todo# #2# implementationTASK@todo&&&: implementationTASKTODO&B&U&B implementationTASK@todo''':'': implementationTASKTODO'`'s'`G: implementation for the other four RIRs (AfriNIC, APNIC, ARIN, LACNIC)TASKTODO=v==v>>> statrixE-sense Copyright (c) 2008, E-sense+/statrix/includes/whois.php; loadWhois&This function loads the Visitors mode.string Statrix action$statrixActionsstatrixWhois()a statrix_action void loadWhois_GETquerystatrix_action statrixActionsstatrix_action;;loadWhois}}!!.0.SYY statrixE-sense Copyright (c) 2008, E-sense^m