Version Description
- Support from Database
- Added Setting Page
- Addes decimals number
- Addes Online user check time
- Addes Database check time
- Added User Online
- Added Today Visit
- Added Yesterday Visit
- Added Week Visit
- Added Month Visit
- Added Years Visit
- Added Search Engine reffered
- Added Average Posts
- Added Average Comments
- Added Average Users
- Added Google Pagerank
- Added Alexa Pagerank
- Added wordpress shortcode
Download this release
Release Info
Developer | mostafa.s1990 |
Plugin | WP Statistics |
Version | 2.0 |
Comparing to | |
See all releases |
Code changes from version 1.0 to 2.0
- actions.php +13 -0
- images/icon.png +0 -0
- images/icon_big.png +0 -0
- images/loading.gif +0 -0
- include/alexa_pagerank.php +33 -0
- include/google_pagerank.php +97 -0
- langs/wp_statistics-fa_IR.mo +0 -0
- langs/wp_statistics-fa_IR.po +548 -0
- readme.txt +157 -56
- report_problem.php +21 -0
- screenshot-1.png +0 -0
- screenshot-2.png +0 -0
- wp-statistics-fa_IR.mo +0 -0
- wp-statistics-fa_IR.po +0 -62
- wp-statistics-totalvisit-live.php +7 -0
- wp-statistics-useronline-live.php +7 -0
- wp-statistics.mo +0 -0
- wp-statistics.php +767 -79
- wp-statistics.po +0 -62
- wp-statistics.txt +0 -1
actions.php
ADDED
@@ -0,0 +1,13 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
require('../../../wp-blog-header.php');
|
3 |
+
$increase_value = $_REQUEST['increase_value'];
|
4 |
+
$reduction_value = $_REQUEST['reduction_value'];
|
5 |
+
|
6 |
+
if($increase_value) {
|
7 |
+
echo __('Sorry! this feature is for Premium version', 'wp_statistics');
|
8 |
+
} else if($reduction_value) {
|
9 |
+
echo __('Sorry! this feature is for Premium version', 'wp_statistics');
|
10 |
+
} else {
|
11 |
+
_e('Please Enter value!', 'wp_statistics');
|
12 |
+
}
|
13 |
+
?>
|
images/icon.png
ADDED
Binary file
|
images/icon_big.png
ADDED
Binary file
|
images/loading.gif
ADDED
Binary file
|
include/alexa_pagerank.php
ADDED
@@ -0,0 +1,33 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/* Alexa Pagerank checker function
|
3 |
+
/* Source: http://abcoder.com/php/get-google-page-rank-and-alexa-rank-of-a-domain-using-php/
|
4 |
+
*/
|
5 |
+
function wp_statistics_alexaRank(){
|
6 |
+
$get_pagerank_alexa_url = get_option('pagerank_alexa_url');
|
7 |
+
if(!$get_pagerank_alexa_url) {
|
8 |
+
$domain = get_bloginfo('url');
|
9 |
+
} else {
|
10 |
+
$domain = get_option('pagerank_alexa_url');
|
11 |
+
}
|
12 |
+
|
13 |
+
$remote_url = 'http://data.alexa.com/data?cli=10&dat=snbamz&url='.trim($domain);
|
14 |
+
$search_for = '<POPULARITY URL';
|
15 |
+
if ($handle = @fopen($remote_url, "r")) {
|
16 |
+
while (!feof($handle)) {
|
17 |
+
$part .= fread($handle, 100);
|
18 |
+
$pos = strpos($part, $search_for);
|
19 |
+
if ($pos === false)
|
20 |
+
continue;
|
21 |
+
else
|
22 |
+
break;
|
23 |
+
}
|
24 |
+
$part .= fread($handle, 100);
|
25 |
+
fclose($handle);
|
26 |
+
}
|
27 |
+
$str = explode($search_for, $part);
|
28 |
+
$str = array_shift(explode('"/>', $str[1]));
|
29 |
+
$str = explode('TEXT="', $str);
|
30 |
+
|
31 |
+
return $str[1];
|
32 |
+
}
|
33 |
+
?>
|
include/google_pagerank.php
ADDED
@@ -0,0 +1,97 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/* Google Pagerank checker function
|
3 |
+
/* Source: http://abcoder.com/php/get-google-page-rank-and-alexa-rank-of-a-domain-using-php/
|
4 |
+
*/
|
5 |
+
function wp_statistics_google_page_rank() {
|
6 |
+
$get_pagerank_google_url = get_option('pagerank_google_url');
|
7 |
+
if(!$get_pagerank_google_url) {
|
8 |
+
$url = get_bloginfo('url');
|
9 |
+
} else {
|
10 |
+
$url = get_option('pagerank_google_url');
|
11 |
+
}
|
12 |
+
|
13 |
+
if (strlen(trim($url))>0) {
|
14 |
+
$_url = eregi("http://",$url)? $url:"http://".$url;
|
15 |
+
$pagerank = trim(wp_statistics_GooglePageRank($_url));
|
16 |
+
if (empty($pagerank)) $pagerank = 0;
|
17 |
+
return (int)($pagerank);
|
18 |
+
}
|
19 |
+
return 0;
|
20 |
+
}
|
21 |
+
|
22 |
+
function wp_statistics_GooglePageRank($url) {
|
23 |
+
$fp = fsockopen("toolbarqueries.google.com", 80, $errno, $errstr, 30);
|
24 |
+
if (!$fp) {
|
25 |
+
echo "$errstr ($errno)<br />\n";
|
26 |
+
} else {
|
27 |
+
$out = "GET /search?client=navclient-auto&ch=".wp_statistics_CheckHash(wp_statistics_HashURL($url))."&features=Rank&q=info:".$url."&num=100&filter=0 HTTP/1.1\r\n";
|
28 |
+
$out .= "Host: toolbarqueries.google.com\r\n";
|
29 |
+
$out .= "User-Agent: Mozilla/4.0 (compatible; GoogleToolbar 2.0.114-big; Windows XP 5.1)\r\n";
|
30 |
+
$out .= "Connection: Close\r\n\r\n";
|
31 |
+
fwrite($fp, $out);
|
32 |
+
|
33 |
+
while (!feof($fp)) {
|
34 |
+
$data = fgets($fp, 128);
|
35 |
+
$pos = strpos($data, "Rank_");
|
36 |
+
if($pos === false){} else{
|
37 |
+
$pagerank = substr($data, $pos + 9);
|
38 |
+
}
|
39 |
+
}
|
40 |
+
fclose($fp);
|
41 |
+
return $pagerank;
|
42 |
+
}
|
43 |
+
}
|
44 |
+
|
45 |
+
function wp_statistics_StrToNum($Str, $Check, $Magic) {
|
46 |
+
$Int32Unit = 4294967296; // 2^32
|
47 |
+
$length = strlen($Str);
|
48 |
+
for ($i = 0; $i < $length; $i++) {
|
49 |
+
$Check *= $Magic;
|
50 |
+
if ($Check >= $Int32Unit) {
|
51 |
+
$Check = ($Check - $Int32Unit * (int) ($Check / $Int32Unit));
|
52 |
+
$Check = ($Check < -2147483648)? ($Check + $Int32Unit) : $Check;
|
53 |
+
}
|
54 |
+
$Check += ord($Str{$i});
|
55 |
+
}
|
56 |
+
return $Check;
|
57 |
+
}
|
58 |
+
|
59 |
+
function wp_statistics_HashURL($String) {
|
60 |
+
$Check1 = wp_statistics_StrToNum($String, 0x1505, 0x21);
|
61 |
+
$Check2 = wp_statistics_StrToNum($String, 0, 0x1003F);
|
62 |
+
$Check1 >>= 2;
|
63 |
+
$Check1 = (($Check1 >> 4) & 0x3FFFFC0 ) | ($Check1 & 0x3F);
|
64 |
+
$Check1 = (($Check1 >> 4) & 0x3FFC00 ) | ($Check1 & 0x3FF);
|
65 |
+
$Check1 = (($Check1 >> 4) & 0x3C000 ) | ($Check1 & 0x3FFF);
|
66 |
+
$T1 = (((($Check1 & 0x3C0) << 4) | ($Check1 & 0x3C)) << 2 ) | ($Check2 & 0xF0F );
|
67 |
+
$T2 = (((($Check1 & 0xFFFFC000) << 4) | ($Check1 & 0x3C00)) << 0xA) | ($Check2 & 0xF0F0000 );
|
68 |
+
return ($T1 | $T2);
|
69 |
+
}
|
70 |
+
|
71 |
+
function wp_statistics_CheckHash($Hashnum) {
|
72 |
+
$CheckByte = 0;
|
73 |
+
$Flag = 0;
|
74 |
+
$HashStr = sprintf('%u', $Hashnum) ;
|
75 |
+
$length = strlen($HashStr);
|
76 |
+
for ($i = $length - 1; $i >= 0; $i --) {
|
77 |
+
$Re = $HashStr{$i};
|
78 |
+
if (1 === ($Flag % 2)) {
|
79 |
+
$Re += $Re;
|
80 |
+
$Re = (int)($Re / 10) + ($Re % 10);
|
81 |
+
}
|
82 |
+
$CheckByte += $Re;
|
83 |
+
$Flag ++;
|
84 |
+
}
|
85 |
+
$CheckByte %= 10;
|
86 |
+
if (0!== $CheckByte) {
|
87 |
+
$CheckByte = 10 - $CheckByte;
|
88 |
+
if (1 === ($Flag % 2) ) {
|
89 |
+
if (1 === ($CheckByte % 2)) {
|
90 |
+
$CheckByte += 9;
|
91 |
+
}
|
92 |
+
$CheckByte >>= 1;
|
93 |
+
}
|
94 |
+
}
|
95 |
+
return '7'.$CheckByte.$HashStr;
|
96 |
+
}
|
97 |
+
?>
|
langs/wp_statistics-fa_IR.mo
ADDED
Binary file
|
langs/wp_statistics-fa_IR.po
ADDED
@@ -0,0 +1,548 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
msgid ""
|
2 |
+
msgstr ""
|
3 |
+
"Project-Id-Version: wp-statistics\n"
|
4 |
+
"Report-Msgid-Bugs-To: \n"
|
5 |
+
"POT-Creation-Date: 2011-09-19 13:03+0330\n"
|
6 |
+
"PO-Revision-Date: \n"
|
7 |
+
"Last-Translator: Mostafa Soufi <mst404@gmail.com>\n"
|
8 |
+
"Language-Team: <mat404@gmail.com>\n"
|
9 |
+
"MIME-Version: 1.0\n"
|
10 |
+
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
+
"Content-Transfer-Encoding: 8bit\n"
|
12 |
+
"X-Poedit-KeywordsList: __;_e\n"
|
13 |
+
"X-Poedit-Basepath: F:\\Program Files\\Apserv\\AppServ\\www\\wordpress\\wp-content\\plugins\\wp-statistics\n"
|
14 |
+
"X-Poedit-Language: Persian\n"
|
15 |
+
"X-Poedit-Country: IRAN, ISLAMIC REPUBLIC OF\n"
|
16 |
+
"X-Poedit-SearchPath-0: F:\\Program Files\\Apserv\\AppServ\\www\\wordpress\\wp-content\\plugins\\wp-statistics\n"
|
17 |
+
|
18 |
+
#: F:\Program
|
19 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/actions.php:7
|
20 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/actions.php:9
|
21 |
+
msgid "Sorry! this feature is for Premium version"
|
22 |
+
msgstr "متاسفم! این امکان برای نسخهی ویژه است."
|
23 |
+
|
24 |
+
#: F:\Program
|
25 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/actions.php:11
|
26 |
+
msgid "Please Enter value!"
|
27 |
+
msgstr "لطفا مقداری را وارد کنید!"
|
28 |
+
|
29 |
+
#: F:\Program
|
30 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/report_problem.php:17
|
31 |
+
msgid "Thanks for your report!"
|
32 |
+
msgstr "با تشکر از گزارش شما!"
|
33 |
+
|
34 |
+
#: F:\Program
|
35 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/report_problem.php:19
|
36 |
+
msgid "Error! Please Enter all field"
|
37 |
+
msgstr "خطا! لطفا همه فیلدها را پرکنید"
|
38 |
+
|
39 |
+
#: F:\Program
|
40 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:194
|
41 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:209
|
42 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:224
|
43 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:239
|
44 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:254
|
45 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:269
|
46 |
+
msgid "(Disable)"
|
47 |
+
msgstr "(غیرفعال)"
|
48 |
+
|
49 |
+
#: F:\Program
|
50 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:376
|
51 |
+
msgid "Statistics"
|
52 |
+
msgstr "آماره"
|
53 |
+
|
54 |
+
#: F:\Program
|
55 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:377
|
56 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:637
|
57 |
+
msgid "Stats weblog"
|
58 |
+
msgstr "آمار سایت"
|
59 |
+
|
60 |
+
#: F:\Program
|
61 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:378
|
62 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:585
|
63 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:673
|
64 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:709
|
65 |
+
msgid "User Online"
|
66 |
+
msgstr "کاربران حاضر"
|
67 |
+
|
68 |
+
#: F:\Program
|
69 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:384
|
70 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:635
|
71 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:671
|
72 |
+
msgid "You do not have sufficient permissions to access this page."
|
73 |
+
msgstr "شما مجوز کافی برای مشاهدهی این قسمت را ندارید."
|
74 |
+
|
75 |
+
#: F:\Program
|
76 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:453
|
77 |
+
msgid "Configuration"
|
78 |
+
msgstr "پیکربندی"
|
79 |
+
|
80 |
+
#: F:\Program
|
81 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:458
|
82 |
+
msgid "Enable Statistics"
|
83 |
+
msgstr "آمارگیر فعال شود"
|
84 |
+
|
85 |
+
#: F:\Program
|
86 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:462
|
87 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:480
|
88 |
+
msgid "Yes"
|
89 |
+
msgstr "بله"
|
90 |
+
|
91 |
+
#: F:\Program
|
92 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:466
|
93 |
+
msgid "Statistics are disabled."
|
94 |
+
msgstr "آمارگیر فعال است."
|
95 |
+
|
96 |
+
#: F:\Program
|
97 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:468
|
98 |
+
msgid "Statistics are disabled!"
|
99 |
+
msgstr "آمارگیر غیرفعال است!"
|
100 |
+
|
101 |
+
#: F:\Program
|
102 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:473
|
103 |
+
msgid "General configuration"
|
104 |
+
msgstr "پیکربندی عمومی"
|
105 |
+
|
106 |
+
#: F:\Program
|
107 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:476
|
108 |
+
msgid "Show decimals number"
|
109 |
+
msgstr "نمایش اعداد بهصورت اعشاری"
|
110 |
+
|
111 |
+
#: F:\Program
|
112 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:482
|
113 |
+
msgid "Show number stats with decimal. For examle: 3,500"
|
114 |
+
msgstr "نمایش اعداد آمارگیر بهصورت اعشاری. برای مثال: 3،500"
|
115 |
+
|
116 |
+
#: F:\Program
|
117 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:486
|
118 |
+
msgid "Online user check time"
|
119 |
+
msgstr "زمان بررسی کاربران آنلاین"
|
120 |
+
|
121 |
+
#: F:\Program
|
122 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:488
|
123 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:529
|
124 |
+
msgid "Each"
|
125 |
+
msgstr "هر"
|
126 |
+
|
127 |
+
#: F:\Program
|
128 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:490
|
129 |
+
msgid "Compute min"
|
130 |
+
msgstr "دقیقه محاسبه کن"
|
131 |
+
|
132 |
+
#: F:\Program
|
133 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:492
|
134 |
+
msgid "Time for the check accurate online user in the site. Default: 5 Minutes"
|
135 |
+
msgstr "زمان برای بررسی دقیق کاربران حاضر در سایت. پیشفرض 5 دقیقه است"
|
136 |
+
|
137 |
+
#: F:\Program
|
138 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:496
|
139 |
+
msgid "Increase value of the total hits"
|
140 |
+
msgstr "افزایش مقدار به بازدیدهای کل"
|
141 |
+
|
142 |
+
#: F:\Program
|
143 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:499
|
144 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:509
|
145 |
+
msgid "Done"
|
146 |
+
msgstr "انجام"
|
147 |
+
|
148 |
+
#: F:\Program
|
149 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:502
|
150 |
+
msgid "Your total visit sum with this value"
|
151 |
+
msgstr "کل بازدیدها با این مقدار جمع میشود"
|
152 |
+
|
153 |
+
#: F:\Program
|
154 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:506
|
155 |
+
msgid "Reduction value of the total hits"
|
156 |
+
msgstr "کاهش مقدار از بازدیدهای کل"
|
157 |
+
|
158 |
+
#: F:\Program
|
159 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:512
|
160 |
+
msgid "Your total visit minus with this value"
|
161 |
+
msgstr "کل بازدیدها از این مقدار کم میشود"
|
162 |
+
|
163 |
+
#: F:\Program
|
164 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:516
|
165 |
+
msgid "Number item for show Statistics"
|
166 |
+
msgstr "تعداد آیتم برای نمایش آمار"
|
167 |
+
|
168 |
+
#: F:\Program
|
169 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:519
|
170 |
+
msgid "Default 5"
|
171 |
+
msgstr "پیشفرض 5 است"
|
172 |
+
|
173 |
+
#: F:\Program
|
174 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:521
|
175 |
+
msgid "Number for submit item in Database and show that"
|
176 |
+
msgstr "تعداد برای ثبت آیتمهای آمار در پایگاهداده و نمایش آن"
|
177 |
+
|
178 |
+
#: F:\Program
|
179 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:524
|
180 |
+
msgid "Live Statistics configuration"
|
181 |
+
msgstr "پیکربندی بازدید لحظهای"
|
182 |
+
|
183 |
+
#: F:\Program
|
184 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:527
|
185 |
+
msgid "Database check time"
|
186 |
+
msgstr "زمان بررسی پایگاهداده"
|
187 |
+
|
188 |
+
#: F:\Program
|
189 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:531
|
190 |
+
msgid "Minute updates"
|
191 |
+
msgstr "دقیقه بهروز کن"
|
192 |
+
|
193 |
+
#: F:\Program
|
194 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:534
|
195 |
+
msgid "Recommended"
|
196 |
+
msgstr "پیشنهاد میشود"
|
197 |
+
|
198 |
+
#: F:\Program
|
199 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:535
|
200 |
+
msgid "Due to pressure on the server, Be set up on time. Default 1 min."
|
201 |
+
msgstr "بهدلیل فشار برروی سرور، پیشنهاد میشود برروی زمان بالا تعیین شود. پیشفرض 1 دقیقه است."
|
202 |
+
|
203 |
+
#: F:\Program
|
204 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:539
|
205 |
+
msgid "Pagerank configuration"
|
206 |
+
msgstr "تنظیمات رتبهبندی"
|
207 |
+
|
208 |
+
#: F:\Program
|
209 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:542
|
210 |
+
msgid "Your url for Google pagerank check"
|
211 |
+
msgstr "آدرس شما برای بررسی رتبهبندی گوگل"
|
212 |
+
|
213 |
+
#: F:\Program
|
214 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:547
|
215 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:557
|
216 |
+
msgid "If this input is empty, The website url uses"
|
217 |
+
msgstr "اگراین قسمت خالی باشد، از آدرس اصلی سایت استفاده میکند"
|
218 |
+
|
219 |
+
#: F:\Program
|
220 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:552
|
221 |
+
msgid "Your url for Alexa pagerank check"
|
222 |
+
msgstr "آدرس شما برای بررسی رتبهبندی الکسا"
|
223 |
+
|
224 |
+
#: F:\Program
|
225 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:563
|
226 |
+
msgid "About plugin"
|
227 |
+
msgstr "دربارهی افزونه"
|
228 |
+
|
229 |
+
#: F:\Program
|
230 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:564
|
231 |
+
msgid "Plugin Version"
|
232 |
+
msgstr "نسخه افزونه"
|
233 |
+
|
234 |
+
#: F:\Program
|
235 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:564
|
236 |
+
msgid "Free!"
|
237 |
+
msgstr "رایگان!"
|
238 |
+
|
239 |
+
#: F:\Program
|
240 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:565
|
241 |
+
msgid "Get Premium version"
|
242 |
+
msgstr "دریافت نسخهی ویژه"
|
243 |
+
|
244 |
+
#: F:\Program
|
245 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:570
|
246 |
+
msgid "This plugin created by"
|
247 |
+
msgstr "این افزونه توسط"
|
248 |
+
|
249 |
+
#: F:\Program
|
250 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:570
|
251 |
+
msgid "from"
|
252 |
+
msgstr "از گروه"
|
253 |
+
|
254 |
+
#: F:\Program
|
255 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:570
|
256 |
+
msgid "and"
|
257 |
+
msgstr "و"
|
258 |
+
|
259 |
+
#: F:\Program
|
260 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:570
|
261 |
+
msgid "group"
|
262 |
+
msgstr "ساخته شدهاست"
|
263 |
+
|
264 |
+
#: F:\Program
|
265 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:571
|
266 |
+
msgid "for translate language files. please send files for"
|
267 |
+
msgstr "لطفا فایلهای ترجمه را به ایمیل روبرو ارسال کنید"
|
268 |
+
|
269 |
+
#: F:\Program
|
270 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:573
|
271 |
+
msgid "Show Functions"
|
272 |
+
msgstr "نمایش تابعها"
|
273 |
+
|
274 |
+
#: F:\Program
|
275 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:574
|
276 |
+
msgid "Report Problem"
|
277 |
+
msgstr "گزارش مشکل"
|
278 |
+
|
279 |
+
#: F:\Program
|
280 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:586
|
281 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:714
|
282 |
+
msgid "Today Visit"
|
283 |
+
msgstr "بازدید امروز"
|
284 |
+
|
285 |
+
#: F:\Program
|
286 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:587
|
287 |
+
msgid "Yesterday visit"
|
288 |
+
msgstr "بازدید دیروز"
|
289 |
+
|
290 |
+
#: F:\Program
|
291 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:588
|
292 |
+
msgid "Week Visit"
|
293 |
+
msgstr "بازدید هفته"
|
294 |
+
|
295 |
+
#: F:\Program
|
296 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:589
|
297 |
+
msgid "Month Visit"
|
298 |
+
msgstr "بازدید ماه"
|
299 |
+
|
300 |
+
#: F:\Program
|
301 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:590
|
302 |
+
msgid "Years Visit"
|
303 |
+
msgstr "بازدید سال"
|
304 |
+
|
305 |
+
#: F:\Program
|
306 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:591
|
307 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:724
|
308 |
+
msgid "Total Visit"
|
309 |
+
msgstr "کل بازدیدها"
|
310 |
+
|
311 |
+
#: F:\Program
|
312 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:592
|
313 |
+
msgid "Search Engine reffered"
|
314 |
+
msgstr "ورودی موتورهای جستجوگر"
|
315 |
+
|
316 |
+
#: F:\Program
|
317 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:593
|
318 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:729
|
319 |
+
msgid "Total Posts"
|
320 |
+
msgstr "کل نوشتهها"
|
321 |
+
|
322 |
+
#: F:\Program
|
323 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:594
|
324 |
+
msgid "Total Pages"
|
325 |
+
msgstr "کل برگهها"
|
326 |
+
|
327 |
+
#: F:\Program
|
328 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:595
|
329 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:734
|
330 |
+
msgid "Total Comments"
|
331 |
+
msgstr "کل دیدگاهها"
|
332 |
+
|
333 |
+
#: F:\Program
|
334 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:596
|
335 |
+
msgid "Total Spams"
|
336 |
+
msgstr "کل جفنگها"
|
337 |
+
|
338 |
+
#: F:\Program
|
339 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:597
|
340 |
+
msgid "Total Users"
|
341 |
+
msgstr "کل کاربرها"
|
342 |
+
|
343 |
+
#: F:\Program
|
344 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:598
|
345 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:739
|
346 |
+
msgid "Last Post Date"
|
347 |
+
msgstr "تاریخ بهروزشدن سایت"
|
348 |
+
|
349 |
+
#: F:\Program
|
350 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:599
|
351 |
+
msgid "Average Posts"
|
352 |
+
msgstr "میانگین نوشتهها"
|
353 |
+
|
354 |
+
#: F:\Program
|
355 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:600
|
356 |
+
msgid "Average Comments"
|
357 |
+
msgstr "میانگین دیدگاهها"
|
358 |
+
|
359 |
+
#: F:\Program
|
360 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:601
|
361 |
+
msgid "Average Users"
|
362 |
+
msgstr "میانگین کاربرها"
|
363 |
+
|
364 |
+
#: F:\Program
|
365 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:602
|
366 |
+
msgid "Total Feedburner Subscribe"
|
367 |
+
msgstr "تعداد مشترکهای فیدبرنر"
|
368 |
+
|
369 |
+
#: F:\Program
|
370 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:603
|
371 |
+
msgid "Google Pagerank"
|
372 |
+
msgstr "رتبه گوگل"
|
373 |
+
|
374 |
+
#: F:\Program
|
375 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:604
|
376 |
+
msgid "Alexa Pagerank"
|
377 |
+
msgstr "رتبه الکسا"
|
378 |
+
|
379 |
+
#: F:\Program
|
380 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:605
|
381 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:615
|
382 |
+
msgid "Hide"
|
383 |
+
msgstr "مخفی"
|
384 |
+
|
385 |
+
#: F:\Program
|
386 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:609
|
387 |
+
msgid "Your Name"
|
388 |
+
msgstr "نام شما"
|
389 |
+
|
390 |
+
#: F:\Program
|
391 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:611
|
392 |
+
msgid "Description Problem"
|
393 |
+
msgstr "توضیحات مشکل"
|
394 |
+
|
395 |
+
#: F:\Program
|
396 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:614
|
397 |
+
msgid "Send Problem"
|
398 |
+
msgstr "ارسال گزارش"
|
399 |
+
|
400 |
+
#: F:\Program
|
401 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:624
|
402 |
+
msgid "Update"
|
403 |
+
msgstr "بهروز رسانی"
|
404 |
+
|
405 |
+
#: F:\Program
|
406 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:648
|
407 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:684
|
408 |
+
msgid "No"
|
409 |
+
msgstr "شماره"
|
410 |
+
|
411 |
+
#: F:\Program
|
412 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:649
|
413 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:685
|
414 |
+
msgid "IP"
|
415 |
+
msgstr "آیپی"
|
416 |
+
|
417 |
+
#: F:\Program
|
418 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:650
|
419 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:686
|
420 |
+
msgid "Time"
|
421 |
+
msgstr "زمان"
|
422 |
+
|
423 |
+
#: F:\Program
|
424 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:651
|
425 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:687
|
426 |
+
msgid "Referred"
|
427 |
+
msgstr "هدایت شده"
|
428 |
+
|
429 |
+
#: F:\Program
|
430 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:652
|
431 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:688
|
432 |
+
msgid "Agent"
|
433 |
+
msgstr "مشخصات مرورگر"
|
434 |
+
|
435 |
+
#: F:\Program
|
436 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:719
|
437 |
+
msgid "Yesterday Visit"
|
438 |
+
msgstr "بازدید دیروز"
|
439 |
+
|
440 |
+
#: F:\Program
|
441 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:759
|
442 |
+
msgid "Name"
|
443 |
+
msgstr "نام"
|
444 |
+
|
445 |
+
#: F:\Program
|
446 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:764
|
447 |
+
msgid "Type date for last update"
|
448 |
+
msgstr "نوع تقویم برای آخرین بهروزرسانی"
|
449 |
+
|
450 |
+
#: F:\Program
|
451 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:766
|
452 |
+
msgid "English"
|
453 |
+
msgstr "میلادی"
|
454 |
+
|
455 |
+
#: F:\Program
|
456 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:769
|
457 |
+
msgid "Persian"
|
458 |
+
msgstr "شمسی (فارسی)"
|
459 |
+
|
460 |
+
#: F:\Program
|
461 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:779
|
462 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:781
|
463 |
+
msgid "WP-Statistics"
|
464 |
+
msgstr "آمارگیر"
|
465 |
+
|
466 |
+
#: F:\Program
|
467 |
+
#: Files\Apserv\AppServ\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:780
|
468 |
+
msgid "Show site stats in sidebar"
|
469 |
+
msgstr "نمایش آمار سایت در ابزارک"
|
470 |
+
|
471 |
+
#~ msgid "User Online Live"
|
472 |
+
#~ msgstr "کاربران آنلاین زنده"
|
473 |
+
|
474 |
+
#~ msgid "Total Visit Live"
|
475 |
+
#~ msgstr "کل بازدیدها زنده"
|
476 |
+
|
477 |
+
#~ msgid "Added"
|
478 |
+
#~ msgstr "مقدار"
|
479 |
+
|
480 |
+
#~ msgid "value"
|
481 |
+
#~ msgstr "افزوده شد"
|
482 |
+
|
483 |
+
#~ msgid "Was"
|
484 |
+
#~ msgstr "مقدار"
|
485 |
+
|
486 |
+
#~ msgid "low value"
|
487 |
+
#~ msgstr "کم شد"
|
488 |
+
|
489 |
+
#~ msgid "d"
|
490 |
+
#~ msgstr "ططظط"
|
491 |
+
|
492 |
+
#~ msgid ""
|
493 |
+
#~ "This plugin created by <a href=\"http://profile.wordpress.org/mostafa."
|
494 |
+
#~ "s1990\">Mostafa Soufi</a> from <a href=\"http://wpbazar.com\">WPBazar</a> "
|
495 |
+
#~ "and <a href=\"http://wp-persian.com\">WP-Persian</a> group.\n"
|
496 |
+
#~ "\t\t\tfor translate language files. please send files for mst404@gmail.com"
|
497 |
+
#~ msgstr "یبیبیب"
|
498 |
+
|
499 |
+
#~ msgid "Your Report"
|
500 |
+
#~ msgstr "گزارش شما"
|
501 |
+
|
502 |
+
#~ msgid "About Author"
|
503 |
+
#~ msgstr "دربارهی نویسنده"
|
504 |
+
|
505 |
+
#~ msgid "Hide Functions"
|
506 |
+
#~ msgstr "مخفیکردن تابعها"
|
507 |
+
|
508 |
+
#~ msgid "Title Widget"
|
509 |
+
#~ msgstr "عنوان ابزارک"
|
510 |
+
|
511 |
+
#~ msgid "Show items"
|
512 |
+
#~ msgstr "نمایش عناوین"
|
513 |
+
|
514 |
+
#~ msgid "Total Blog Hits: "
|
515 |
+
#~ msgstr "Total Blog Hits: "
|
516 |
+
|
517 |
+
#~ msgid "Summary statistics of blog"
|
518 |
+
#~ msgstr "Summary statistics of blog"
|
519 |
+
|
520 |
+
#~ msgid "Be set up on time"
|
521 |
+
#~ msgstr "برروی زمان بالا محاسبه شود"
|
522 |
+
|
523 |
+
#~ msgid "Updates to"
|
524 |
+
#~ msgstr "دقیقه"
|
525 |
+
|
526 |
+
#~ msgid "Live Statistics"
|
527 |
+
#~ msgstr "بازدید لحظهای"
|
528 |
+
|
529 |
+
#~ msgid "Visitor"
|
530 |
+
#~ msgstr "بازدیدکننده"
|
531 |
+
|
532 |
+
#~ msgid "Ban IP"
|
533 |
+
#~ msgstr "محروم کردن آیپی"
|
534 |
+
|
535 |
+
#~ msgid "Add"
|
536 |
+
#~ msgstr "افزودن"
|
537 |
+
|
538 |
+
#~ msgid "Stats"
|
539 |
+
#~ msgstr "آمار"
|
540 |
+
|
541 |
+
#~ msgid "Enable"
|
542 |
+
#~ msgstr "آمارگیر فعال شود"
|
543 |
+
|
544 |
+
#~ msgid "Latest posts in wpdelicious"
|
545 |
+
#~ msgstr "آخرین ارسالی های وردپرس"
|
546 |
+
|
547 |
+
#~ msgid "Latest Delicious"
|
548 |
+
#~ msgstr "آخرین ارسالی ها"
|
readme.txt
CHANGED
@@ -1,56 +1,157 @@
|
|
1 |
-
=== WP-Statistics ===
|
2 |
-
Contributors:
|
3 |
-
Donate link: http://iran98.org/
|
4 |
-
Tags: statistics, stats, blog, total, post, page, sidebar,
|
5 |
-
Requires at least:
|
6 |
-
Tested up to: 3.1
|
7 |
-
Stable tag:
|
8 |
-
|
9 |
-
Summary statistics of blog.
|
10 |
-
|
11 |
-
== Description ==
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
|
16 |
-
|
17 |
-
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
Total
|
28 |
-
Total
|
29 |
-
Total
|
30 |
-
Total
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
Total
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
-
*
|
56 |
-
*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
=== WP-Statistics ===
|
2 |
+
Contributors: mostafa.s1990
|
3 |
+
Donate link: http://iran98.org/
|
4 |
+
Tags: statistics, stats, blog, today, yesterday, week, month, yearl, total, post, page, sidebar, summary, feedburner, hits, pagerank, google, alexa, live visit
|
5 |
+
Requires at least: 3.0
|
6 |
+
Tested up to: 3.2.1
|
7 |
+
Stable tag: 2.0
|
8 |
+
|
9 |
+
Summary statistics of blog.
|
10 |
+
|
11 |
+
== Description ==
|
12 |
+
a plugin for displaying Summary statistics of blog.
|
13 |
+
|
14 |
+
Features:
|
15 |
+
|
16 |
+
* User Online
|
17 |
+
* Today Visit
|
18 |
+
* Yesterday visit
|
19 |
+
* Week Visit
|
20 |
+
* Month Visit
|
21 |
+
* Years Visit
|
22 |
+
* Total Visit
|
23 |
+
* Search Engine reffered (Google, Yahoo, Bing)
|
24 |
+
* User Online Live [Premium Version](http://www.wpbazar.com/products/wp-statistics-premium)
|
25 |
+
* Total Visit Live [Premium Version](http://www.wpbazar.com/products/wp-statistics-premium)
|
26 |
+
* Total Posts
|
27 |
+
* Total Pages
|
28 |
+
* Total Comments
|
29 |
+
* Total Spams [Need installed akismet plugin](http://automattic.com/wordpress-plugins/)
|
30 |
+
* Total Users
|
31 |
+
* Last Post Date (English, Persian)
|
32 |
+
* Average Posts
|
33 |
+
* Average Comments
|
34 |
+
* Average Users
|
35 |
+
* Total Feedburner Subscribe
|
36 |
+
* Google Pagerank
|
37 |
+
* Alexa Pagerank
|
38 |
+
* Use optimize from Database
|
39 |
+
* Show Useronline and last visitor in setting page (ip, time, agent, reffered)
|
40 |
+
* Supported wordpress shortcode for view function in post/page or widget(text)
|
41 |
+
|
42 |
+
Language Support:
|
43 |
+
|
44 |
+
* English
|
45 |
+
* Persian
|
46 |
+
|
47 |
+
Send email for Translation files: mst404[a]gmail[dot].com
|
48 |
+
|
49 |
+
== Installation ==
|
50 |
+
1. Upload `wp-statistics` to the `/wp-content/plugins/` directory
|
51 |
+
2. Activate the plugin through the 'Plugins' menu in WordPress
|
52 |
+
3. To display stats, using this functions:
|
53 |
+
|
54 |
+
* User Online: `<?php wp_statistics_useronline(); ?>`
|
55 |
+
* Today Visit: `<?php wp_statistics_today(); ?>`
|
56 |
+
* Yesterday Visit: `<?php wp_statistics_yesterday(); ?>`
|
57 |
+
* Week Visit `<?php wp_statistics_week(); ?>`
|
58 |
+
* Month Visit `<?php wp_statistics_month(); ?>`
|
59 |
+
* Years Visit `<?php wp_statistics_year(); ?>`
|
60 |
+
* Total Visit `<?php wp_statistics_total(); ?>`
|
61 |
+
* All Search Engine reffered `<?php wp_statistics_searchengine(); ?>`
|
62 |
+
* Google Search Engine reffered `<?php wp_statistics_searchengine('google'); ?>`
|
63 |
+
* Yahoo Search Engine reffered `<?php wp_statistics_searchengine('yahoo'); ?>`
|
64 |
+
* Bing Search Engine reffered `<?php wp_statistics_searchengine('bing'); ?>`
|
65 |
+
* User Online Live (Premium Version) `<?php wp_statistics_useronline_live(); ?>`
|
66 |
+
* Total Visit Live (Premium Version) `<?php wp_statistics_total_live(); ?>`
|
67 |
+
* Total Posts `<?php wp_statistics_countposts(); ?>`
|
68 |
+
* Total Pages `<?php wp_statistics_countpages(); ?>`
|
69 |
+
* Total Comments `<?php wp_statistics_countcomment(); ?>`
|
70 |
+
* Total Spams `<?php wp_statistics_countspam(); ?>`
|
71 |
+
* Total Users `<?php wp_statistics_countusers(); ?>`
|
72 |
+
* Last Post Date `<?php wp_statistics_lastpostdate(); ?>`
|
73 |
+
* Last Post Date (Persian) `<?php wp_statistics_lastpostdate('farsi'); ?>`
|
74 |
+
* Average Posts `<?php wp_statistics_average_post(); ?>`
|
75 |
+
* Average Comments `<?php wp_statistics_average_comment(); ?>`
|
76 |
+
* Average Users `<?php wp_statistics_average_registeruser(); ?>`
|
77 |
+
* Total Feedburner Subscribe `<?php wp_statistics_yesterday('febnurner address'); ?>`
|
78 |
+
* Google Pagerank `<?php wp_statistics_google_page_rank(); ?>`
|
79 |
+
* Alexa Pagerank `<?php wp_statistics_alexaRank(); ?>`
|
80 |
+
|
81 |
+
or using this Shortcode in Posts pages or Widget:
|
82 |
+
|
83 |
+
* User Online: `[useronline]useronline[/useronline]`
|
84 |
+
* Today Visit: `[today]today[/today]`
|
85 |
+
* Yesterday Visit: `[yesterday]yesterday[/yesterday]`
|
86 |
+
* Week Visit `[week]week[/week]`
|
87 |
+
* Month Visit `[month]month[/month]`
|
88 |
+
* Years Visit `[year]year[/year]`
|
89 |
+
* Total Visit `[total]total[/total]`
|
90 |
+
* All Search Engine reffered `[searchengine]searchengine[/searchengine]`
|
91 |
+
* User Online Live (Premium Version) `[useronlinelive]useronlinelive[/useronlinelive]`
|
92 |
+
* Total Visit Live (Premium Version) `[totallive]totallive[/totallive]`
|
93 |
+
* Total Posts `[countposts]countposts[/countposts]`
|
94 |
+
* Total Pages `[countpages]countpages[/countpages]`
|
95 |
+
* Total Comments `[countcomments]countcomments[/countcomments]`
|
96 |
+
* Total Spams `[countspams]countspams[/countspams]`
|
97 |
+
* Total Users `[countusers]countusers[/countusers]`
|
98 |
+
* Last Post Date `[lastpostdate]lastpostdate[/lastpostdate]`
|
99 |
+
* Average Posts `[averagepost]averagepost[/averagepost]`
|
100 |
+
* Average Comments `[averagecomment]averagecomment[/averagecomment]`
|
101 |
+
* Average Users `[averageusers]averageusers[/averageusers]`
|
102 |
+
* Google Pagerank `[googlepagerank]googlepagerank[/googlepagerank]`
|
103 |
+
* Alexa Pagerank `[alexaRank]alexaRank[/alexaRank]`
|
104 |
+
|
105 |
+
== Frequently Asked Questions ==
|
106 |
+
a plugin for displaying Summary statistics of blog.
|
107 |
+
|
108 |
+
== Screenshots ==
|
109 |
+
1. Screen shot (screenshot-1.png) in WP-Statistics Setting Page
|
110 |
+
|
111 |
+
== Upgrade Notice ==
|
112 |
+
= 2.0 =
|
113 |
+
* Support from Database
|
114 |
+
* Added Setting Page
|
115 |
+
* Addes decimals number
|
116 |
+
* Addes Online user check time
|
117 |
+
* Addes Database check time
|
118 |
+
* Added User Online
|
119 |
+
* Added Today Visit
|
120 |
+
* Added Yesterday Visit
|
121 |
+
* Added Week Visit
|
122 |
+
* Added Month Visit
|
123 |
+
* Added Years Visit
|
124 |
+
* Added Search Engine reffered
|
125 |
+
* Added Average Posts
|
126 |
+
* Added Average Comments
|
127 |
+
* Added Average Users
|
128 |
+
* Added Google Pagerank
|
129 |
+
* Added Alexa Pagerank
|
130 |
+
* Added wordpress shortcode
|
131 |
+
|
132 |
+
= 1.0 =
|
133 |
+
* Start plugin
|
134 |
+
|
135 |
+
== Changelog ==
|
136 |
+
= 2.0 =
|
137 |
+
* Support from Database
|
138 |
+
* Added Setting Page
|
139 |
+
* Addes decimals number
|
140 |
+
* Addes Online user check time
|
141 |
+
* Addes Database check time
|
142 |
+
* Added User Online
|
143 |
+
* Added Today Visit
|
144 |
+
* Added Yesterday Visit
|
145 |
+
* Added Week Visit
|
146 |
+
* Added Month Visit
|
147 |
+
* Added Years Visit
|
148 |
+
* Added Search Engine reffered
|
149 |
+
* Added Average Posts
|
150 |
+
* Added Average Comments
|
151 |
+
* Added Average Users
|
152 |
+
* Added Google Pagerank
|
153 |
+
* Added Alexa Pagerank
|
154 |
+
* Added wordpress shortcode
|
155 |
+
|
156 |
+
= 1.0 =
|
157 |
+
* Start plugin
|
report_problem.php
ADDED
@@ -0,0 +1,21 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
require('../../../wp-blog-header.php');
|
3 |
+
global $user_email;
|
4 |
+
if($_REQUEST['y_name'] && $_REQUEST['d_report']) {
|
5 |
+
$name = $_REQUEST['y_name'];
|
6 |
+
$email = $user_email;
|
7 |
+
$url = get_bloginfo('url');
|
8 |
+
$subject = "Report for WP Statistics";
|
9 |
+
$body0 = $_REQUEST['d_report'];
|
10 |
+
$body = "Name: $name \n\n Email: $email \n\n Blog: $url \n\n Description Problem: $body0";
|
11 |
+
$to = "mst404@gmail.com";
|
12 |
+
$sender = get_option('blogname');
|
13 |
+
$headers = "MIME-Version: 1.0\r\n";
|
14 |
+
$headers = "Content-type: text/html; charset=utf-8\r\n";
|
15 |
+
$headers = "From: $email \r\nX-Mailer: $sender";
|
16 |
+
mail($to, $subject, $body, $headers);
|
17 |
+
echo __('Thanks for your report!', 'wp_statistics');
|
18 |
+
} else {
|
19 |
+
_e('Error! Please Enter all field', 'wp_statistics');
|
20 |
+
}
|
21 |
+
?>
|
screenshot-1.png
CHANGED
Binary file
|
screenshot-2.png
DELETED
Binary file
|
wp-statistics-fa_IR.mo
DELETED
Binary file
|
wp-statistics-fa_IR.po
DELETED
@@ -1,62 +0,0 @@
|
|
1 |
-
msgid ""
|
2 |
-
msgstr ""
|
3 |
-
"Project-Id-Version: wp-statistics\n"
|
4 |
-
"Report-Msgid-Bugs-To: \n"
|
5 |
-
"POT-Creation-Date: 2011-03-20 16:22+0330\n"
|
6 |
-
"PO-Revision-Date: \n"
|
7 |
-
"Last-Translator: Mostafa <mst404@gmail.com>\n"
|
8 |
-
"Language-Team: <mat404@gmail.com>\n"
|
9 |
-
"MIME-Version: 1.0\n"
|
10 |
-
"Content-Type: text/plain; charset=utf-8\n"
|
11 |
-
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"X-Poedit-KeywordsList: __;_e\n"
|
13 |
-
"X-Poedit-Basepath: .\n"
|
14 |
-
"X-Poedit-Language: Persian\n"
|
15 |
-
"X-Poedit-Country: IRAN, ISLAMIC REPUBLIC OF\n"
|
16 |
-
"X-Poedit-SearchPath-0: .\n"
|
17 |
-
|
18 |
-
#: F:\Program
|
19 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:15
|
20 |
-
msgid "Statistics"
|
21 |
-
msgstr "آمارهی وبلاگ"
|
22 |
-
|
23 |
-
#: F:\Program
|
24 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:18
|
25 |
-
msgid "Total Posts: "
|
26 |
-
msgstr "تعداد نوشتهها: "
|
27 |
-
|
28 |
-
#: F:\Program
|
29 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:23
|
30 |
-
msgid "Total Pages: "
|
31 |
-
msgstr "تعداد برگهها: "
|
32 |
-
|
33 |
-
#: F:\Program
|
34 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:28
|
35 |
-
msgid "Total Comments: "
|
36 |
-
msgstr "تعداد دیدگاهها: "
|
37 |
-
|
38 |
-
#: F:\Program
|
39 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:33
|
40 |
-
msgid "Total Spams: "
|
41 |
-
msgstr "تعداد جفنگها: "
|
42 |
-
|
43 |
-
#: F:\Program
|
44 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:38
|
45 |
-
msgid "Last Post Date: "
|
46 |
-
msgstr "تاریخ آخرین نوشته: "
|
47 |
-
|
48 |
-
#: F:\Program
|
49 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:43
|
50 |
-
msgid "Total Blog Hits: "
|
51 |
-
msgstr "تعداد کل بازدیدها: "
|
52 |
-
|
53 |
-
#: F:\Program
|
54 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:49
|
55 |
-
msgid "Summary statistics of blog"
|
56 |
-
msgstr "خلاصهای از آمار وبلاگ"
|
57 |
-
|
58 |
-
#~ msgid "Latest posts in wpdelicious"
|
59 |
-
#~ msgstr "آخرین ارسالی های وردپرس"
|
60 |
-
#~ msgid "Latest Delicious"
|
61 |
-
#~ msgstr "آخرین ارسالی ها"
|
62 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
wp-statistics-totalvisit-live.php
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
require('../../../wp-blog-header.php');
|
3 |
+
global $wpdb, $table_prefix;
|
4 |
+
|
5 |
+
$count_total = $wpdb->get_var("SELECT total FROM {$table_prefix}statistics_visits");
|
6 |
+
echo $count_total;
|
7 |
+
?>
|
wp-statistics-useronline-live.php
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
require('../../../wp-blog-header.php');
|
3 |
+
global $wpdb, $table_prefix;
|
4 |
+
|
5 |
+
$get_users = $wpdb->get_var("SELECT COUNT(ip) FROM {$table_prefix}statistics_useronline");
|
6 |
+
echo $get_users;
|
7 |
+
?>
|
wp-statistics.mo
DELETED
Binary file
|
wp-statistics.php
CHANGED
@@ -3,112 +3,800 @@
|
|
3 |
Plugin Name: WP-Statistics
|
4 |
Plugin URI: http://iran98.org/category/wordpress/wp-statistics/
|
5 |
Description: Summary statistics of blog.
|
6 |
-
Version:
|
7 |
Author: Mostafa Soufi
|
8 |
Author URI: http://iran98.org/
|
9 |
License: GPL2
|
10 |
*/
|
11 |
-
load_plugin_textdomain('wp-statistics','wp-content/plugins/wp-statistics');
|
12 |
-
add_action("plugins_loaded", "statistics_admin_widget");
|
13 |
|
14 |
-
|
15 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
echo "<ul>";
|
17 |
echo "<li>";
|
18 |
-
|
19 |
-
|
20 |
echo "</li>";
|
21 |
|
22 |
echo "<li>";
|
23 |
-
|
24 |
-
|
25 |
echo "</li>";
|
26 |
-
|
27 |
echo "<li>";
|
28 |
-
|
29 |
-
|
30 |
echo "</li>";
|
31 |
|
32 |
echo "<li>";
|
33 |
-
|
34 |
-
|
|
|
|
|
|
|
|
|
|
|
35 |
echo "</li>";
|
36 |
|
37 |
echo "<li>";
|
38 |
-
|
39 |
-
|
40 |
echo "</li>";
|
41 |
|
42 |
echo "<li>";
|
43 |
-
|
44 |
-
|
45 |
-
|
|
|
|
|
|
|
|
|
|
|
46 |
}
|
47 |
-
|
48 |
-
function statistics_admin_widget() {
|
49 |
-
register_sidebar_widget(__('Summary statistics of blog', 'wp-statistics'), 'statistics_widget'); }
|
50 |
|
51 |
-
function
|
52 |
-
|
53 |
-
|
54 |
-
|
55 |
|
56 |
-
|
57 |
-
|
58 |
-
|
59 |
-
}
|
60 |
|
61 |
-
|
62 |
-
|
63 |
-
|
64 |
-
|
65 |
-
echo $countcomms;
|
66 |
-
}
|
67 |
|
68 |
-
|
69 |
-
|
70 |
-
|
|
|
|
|
|
|
|
|
|
|
71 |
|
72 |
-
|
73 |
-
|
74 |
-
echo $result['total_users'];
|
75 |
-
}
|
76 |
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
86 |
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
curl_setopt($ch, CURLOPT_URL, $whaturl);
|
95 |
-
$data = curl_exec($ch);
|
96 |
-
curl_close($ch);
|
97 |
-
$xml = new SimpleXMLElement($data);
|
98 |
-
$fb = $xml->feed->entry['circulation'];
|
99 |
-
$feedcount['count'] = number_format($fb);
|
100 |
-
$feedcount['lastcheck'] = mktime();
|
101 |
-
update_option("feedrsscount",$feedcount);}
|
102 |
-
echo $feedcount['count'];
|
103 |
-
}
|
104 |
-
|
105 |
-
function statistics_totalhits() {
|
106 |
-
$file_counter = ("wp-content/plugins/wp-statistics/wp-statistics.txt");
|
107 |
-
$hits = file($file_counter);
|
108 |
-
$hits[0] ++;
|
109 |
-
$fp = fopen($file_counter , "w");
|
110 |
-
fwrite($fp, "$hits[0]");
|
111 |
-
fclose($fp);
|
112 |
-
echo $hits[0];
|
113 |
-
}
|
114 |
?>
|
3 |
Plugin Name: WP-Statistics
|
4 |
Plugin URI: http://iran98.org/category/wordpress/wp-statistics/
|
5 |
Description: Summary statistics of blog.
|
6 |
+
Version: 2.0
|
7 |
Author: Mostafa Soufi
|
8 |
Author URI: http://iran98.org/
|
9 |
License: GPL2
|
10 |
*/
|
|
|
|
|
11 |
|
12 |
+
load_plugin_textdomain('wp_statistics','wp-content/plugins/wp-statistics/langs');
|
13 |
+
add_action("plugins_loaded", "wp_statistics_widget");
|
14 |
+
add_action('admin_menu', 'wp_statistics_menu');
|
15 |
+
register_activation_hook(__FILE__,'wp_statistics_install');
|
16 |
+
|
17 |
+
global $wp_statistics_db_version, $wpdb;
|
18 |
+
$wp_statistics_db_version = "1.0";
|
19 |
+
|
20 |
+
/* Date And time Varieble */
|
21 |
+
$get_date = date('Y-m-d H:i:s' ,current_time('timestamp',0));
|
22 |
+
$get_now = date('Y-m-d' ,current_time('timestamp',0));
|
23 |
+
$get_week = date('W');
|
24 |
+
$get_month = date('m');
|
25 |
+
$get_year = date('Y');
|
26 |
+
|
27 |
+
/* Server Varieble */
|
28 |
+
$get_referred = $_SERVER['HTTP_REFERER'];
|
29 |
+
$get_useragent = $_SERVER['HTTP_USER_AGENT'];
|
30 |
+
$get_userip = $_SERVER['REMOTE_ADDR'];
|
31 |
+
|
32 |
+
function wp_statistics_install() {
|
33 |
+
global $wp_statistics_db_version, $table_prefix;
|
34 |
+
$table_visit = $table_prefix."statistics_visits";
|
35 |
+
$table_dates = $table_prefix."statistics_date";
|
36 |
+
$table_users = $table_prefix."statistics_useronline";
|
37 |
+
$table_referred = $table_prefix."statistics_reffered";
|
38 |
+
$time_1 = date('i');
|
39 |
+
|
40 |
+
$create_visit_table = ("CREATE TABLE ".$table_visit."
|
41 |
+
(today int(10),
|
42 |
+
yesterday int(10),
|
43 |
+
week int(20),
|
44 |
+
month int(20),
|
45 |
+
year int (20),
|
46 |
+
total int(20),
|
47 |
+
google int(10),
|
48 |
+
yahoo int (10),
|
49 |
+
bing int (10)) CHARSET=utf8");
|
50 |
+
|
51 |
+
$create_dates_table = ("CREATE TABLE ".$table_dates."
|
52 |
+
(last_counter DATE,
|
53 |
+
last_week int(2),
|
54 |
+
last_month int(2),
|
55 |
+
last_year int(5),
|
56 |
+
timestamp int(10),
|
57 |
+
last_visit DATETIME) CHARSET=utf8");
|
58 |
+
|
59 |
+
$create_users_table = ("CREATE TABLE ".$table_users."
|
60 |
+
(ip char(20),
|
61 |
+
timestamp int(10),
|
62 |
+
time DATETIME,
|
63 |
+
referred text,
|
64 |
+
agent char(255))");
|
65 |
+
|
66 |
+
$create_referr_table = ("CREATE TABLE ".$table_referred."
|
67 |
+
(referred text,
|
68 |
+
ip char(20),
|
69 |
+
time DATETIME,
|
70 |
+
agent char(255))");
|
71 |
+
|
72 |
+
if($create_visit_table) {
|
73 |
+
$primary_visit_value = ("INSERT INTO ".$table_visit."
|
74 |
+
(today, yesterday, week, month, year, total, google, yahoo, bing) VALUES
|
75 |
+
(0, 0, 0, 0, 0, 0, 0, 0, 0)");
|
76 |
+
|
77 |
+
$primary_date_value = ("INSERT INTO ".$table_dates."
|
78 |
+
(last_counter, last_week, last_month, last_year, timestamp, last_visit) VALUES
|
79 |
+
('00-00-00', '".$get_week."', '".$get_month."', '".$get_year."', '".$time_1."', '".$get_date."')");
|
80 |
+
}
|
81 |
+
|
82 |
+
require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
|
83 |
+
|
84 |
+
dbDelta($create_visit_table);
|
85 |
+
dbDelta($create_dates_table);
|
86 |
+
dbDelta($create_users_table);
|
87 |
+
dbDelta($create_referr_table);
|
88 |
+
|
89 |
+
dbDelta($primary_visit_value);
|
90 |
+
dbDelta($primary_date_value);
|
91 |
+
|
92 |
+
add_option('wp_statistics_db_version', 'wp_statistics_db_version');
|
93 |
+
}
|
94 |
+
|
95 |
+
function wp_statistics() {
|
96 |
+
global $wpdb, $table_prefix, $get_date, $get_now, $get_week, $get_month, $get_year, $get_referred, $get_userip, $get_useragent;
|
97 |
+
|
98 |
+
$get_dates_row = $wpdb->get_row("SELECT * FROM {$table_prefix}statistics_date");
|
99 |
+
|
100 |
+
if( ($get_dates_row->last_visit) != $get_date ) {
|
101 |
+
if( ($get_dates_row->last_counter) == $get_now ) {
|
102 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET today = today+1, total = total+1");
|
103 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_visit = '".$get_date."'");
|
104 |
+
} else {
|
105 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET yesterday = today, total = total+1");
|
106 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET today = 0");
|
107 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_counter = '".$get_now."', last_visit = '".$get_date."'");
|
108 |
+
}
|
109 |
+
if( ($get_dates_row->last_week) == $get_week ) {
|
110 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET week = week+1");
|
111 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_week = '".$get_week."'");
|
112 |
+
} else {
|
113 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET week = 0");
|
114 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_week = '".$get_week."'");
|
115 |
+
}
|
116 |
+
if( ($get_dates_row->last_month) == $get_month ) {
|
117 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET month = month+1");
|
118 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_month = '".$get_month."'");
|
119 |
+
} else {
|
120 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET month = 0");
|
121 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_month = '".$get_month."'");
|
122 |
+
}
|
123 |
+
if( ($get_dates_row->last_year) == $get_year ) {
|
124 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET year = year+1");
|
125 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_year = '".$get_year."'");
|
126 |
+
} else {
|
127 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET year = 0");
|
128 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_date SET last_year = '".$get_year."'");
|
129 |
+
}
|
130 |
+
}
|
131 |
+
|
132 |
+
if(strstr($get_referred, 'google.com')) {
|
133 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET google = google+1");
|
134 |
+
} else if(strstr($get_referred, 'yahoo.com')) {
|
135 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET yahoo = yahoo+1");
|
136 |
+
} else if(strstr($get_referred, 'bing.com')) {
|
137 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_visits SET bing = bing+1");
|
138 |
+
}
|
139 |
+
|
140 |
+
$get_items_statistics = get_option('items_statistics');
|
141 |
+
if(!$get_items_statistics) {
|
142 |
+
$get_items_statistics = '5';
|
143 |
+
}
|
144 |
+
|
145 |
+
$get_num_reffered = $wpdb->get_var("SELECT COUNT(*) FROM {$table_prefix}statistics_reffered");
|
146 |
+
if($get_num_reffered < $get_items_statistics) {
|
147 |
+
$get_var_ip = $wpdb->get_var("SELECT ip FROM {$table_prefix}statistics_reffered WHERE ip = '".$get_userip."'");
|
148 |
+
if(!$get_var_ip) {
|
149 |
+
$wpdb->query("INSERT INTO {$table_prefix}statistics_reffered (referred, ip, time, agent) VALUES ('".$get_referred."', '".$get_userip."', '".$get_date."', '".$get_useragent."')");
|
150 |
+
}
|
151 |
+
}
|
152 |
+
}
|
153 |
+
$get_enable_stats = get_option('enable_stats');
|
154 |
+
if($get_enable_stats) {
|
155 |
+
add_action('wp_head', 'wp_statistics');
|
156 |
+
}
|
157 |
+
|
158 |
+
/* Start: functions for user in theme */
|
159 |
+
function wp_statistics_useronline() {
|
160 |
+
global $wpdb, $table_prefix, $get_date, $get_referred, $get_useragent, $get_userip;
|
161 |
+
$timestamp = date("U");
|
162 |
+
|
163 |
+
$get_time_useronline = get_option('time_useronline');
|
164 |
+
|
165 |
+
if(!$get_time_useronline) {
|
166 |
+
$get_time_useronline = '1'; // Default value for check accurate user online
|
167 |
+
} $get_time_useronline = $get_time_useronline * 60;
|
168 |
+
|
169 |
+
$get_ip = $wpdb->get_var("SELECT * FROM {$table_prefix}statistics_useronline WHERE ip = '".$get_userip."'");
|
170 |
+
if($get_ip) {
|
171 |
+
$wpdb->query("UPDATE {$table_prefix}statistics_useronline SET timestamp = '".$timestamp."', time = '".$get_date."', referred = '".$get_referred."', agent = '".$get_useragent."' WHERE ip = '".$get_ip."'");
|
172 |
+
} else {
|
173 |
+
$wpdb->query("INSERT INTO {$table_prefix}statistics_useronline(ip, timestamp, time, referred, agent) VALUES ('".$get_userip."', '".$timestamp."', '".$get_date."', '".$get_referred."', '".$get_useragent."')");
|
174 |
+
}
|
175 |
+
|
176 |
+
$time = $timestamp - $get_time_useronline;
|
177 |
+
$wpdb->get_var("DELETE FROM {$table_prefix}statistics_useronline WHERE timestamp < '".$time."'");
|
178 |
+
|
179 |
+
$get_users = $wpdb->get_var("SELECT COUNT(ip) FROM {$table_prefix}statistics_useronline");
|
180 |
+
echo $get_users;
|
181 |
+
}
|
182 |
+
|
183 |
+
function wp_statistics_today() {
|
184 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
185 |
+
$get_var = $wpdb->get_var("SELECT today FROM {$table_prefix}statistics_visits");
|
186 |
+
|
187 |
+
if(get_option('enable_decimals')) {
|
188 |
+
echo number_format($get_var);
|
189 |
+
} else {
|
190 |
+
echo $get_var;
|
191 |
+
}
|
192 |
+
|
193 |
+
if (!$get_enable_stats) {
|
194 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
195 |
+
}
|
196 |
+
}
|
197 |
+
|
198 |
+
function wp_statistics_yesterday() {
|
199 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
200 |
+
$get_var = $wpdb->get_var("SELECT yesterday FROM {$table_prefix}statistics_visits");
|
201 |
+
|
202 |
+
if(get_option('enable_decimals')) {
|
203 |
+
echo number_format($get_var);
|
204 |
+
} else {
|
205 |
+
echo $get_var;
|
206 |
+
}
|
207 |
+
|
208 |
+
if (!$get_enable_stats) {
|
209 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
210 |
+
}
|
211 |
+
}
|
212 |
+
|
213 |
+
function wp_statistics_week() {
|
214 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
215 |
+
$get_var = $wpdb->get_var("SELECT week FROM {$table_prefix}statistics_visits");
|
216 |
+
|
217 |
+
if(get_option('enable_decimals')) {
|
218 |
+
echo number_format($get_var);
|
219 |
+
} else {
|
220 |
+
echo $get_var;
|
221 |
+
}
|
222 |
+
|
223 |
+
if (!$get_enable_stats) {
|
224 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
225 |
+
}
|
226 |
+
}
|
227 |
+
|
228 |
+
function wp_statistics_month() {
|
229 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
230 |
+
$get_var = $wpdb->get_var("SELECT month FROM {$table_prefix}statistics_visits");
|
231 |
+
|
232 |
+
if(get_option('enable_decimals')) {
|
233 |
+
echo number_format($get_var);
|
234 |
+
} else {
|
235 |
+
echo $get_var;
|
236 |
+
}
|
237 |
+
|
238 |
+
if (!$get_enable_stats) {
|
239 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
240 |
+
}
|
241 |
+
}
|
242 |
+
|
243 |
+
function wp_statistics_year() {
|
244 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
245 |
+
$get_var = $wpdb->get_var("SELECT year FROM {$table_prefix}statistics_visits");
|
246 |
+
|
247 |
+
if(get_option('enable_decimals')) {
|
248 |
+
echo number_format($get_var);
|
249 |
+
} else {
|
250 |
+
echo $get_var;
|
251 |
+
}
|
252 |
+
|
253 |
+
if (!$get_enable_stats) {
|
254 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
255 |
+
}
|
256 |
+
}
|
257 |
+
|
258 |
+
function wp_statistics_total() {
|
259 |
+
global $wpdb, $table_prefix, $get_enable_stats;
|
260 |
+
$get_var = $wpdb->get_var("SELECT total FROM {$table_prefix}statistics_visits");
|
261 |
+
|
262 |
+
if(get_option('enable_decimals')) {
|
263 |
+
echo number_format($get_var);
|
264 |
+
} else {
|
265 |
+
echo $get_var;
|
266 |
+
}
|
267 |
+
|
268 |
+
if (!$get_enable_stats) {
|
269 |
+
echo "<span style='font-size:10px;color:#FF0000'> ".__('(Disable)', 'wp_statistics')."</span>";
|
270 |
+
}
|
271 |
+
}
|
272 |
+
|
273 |
+
function wp_statistics_searchengine($referred='') {
|
274 |
+
global $wpdb, $table_prefix;
|
275 |
+
if($referred == 'google') {
|
276 |
+
echo $wpdb->get_var("SELECT google FROM {$table_prefix}statistics_visits");
|
277 |
+
} else if ($referred == 'yahoo') {
|
278 |
+
echo $wpdb->get_var("SELECT yahoo FROM {$table_prefix}statistics_visits");
|
279 |
+
} else if ($referred == 'bing') {
|
280 |
+
echo $wpdb->get_var("SELECT bing FROM {$table_prefix}statistics_visits");
|
281 |
+
} else {
|
282 |
+
$total_referred = $wpdb->get_row("SELECT * FROM {$table_prefix}statistics_visits");
|
283 |
+
echo $total_referred->google + $total_referred->yahoo + $total_referred->bing;
|
284 |
+
}
|
285 |
+
}
|
286 |
+
|
287 |
+
function wp_statistics_countposts($type=publish) {
|
288 |
+
$count_posts = wp_count_posts();
|
289 |
+
echo $count_posts->$type;
|
290 |
+
}
|
291 |
+
|
292 |
+
function wp_statistics_countpages() {
|
293 |
+
$count_pages = wp_count_posts('page');
|
294 |
+
echo $count_pages->publish;
|
295 |
+
}
|
296 |
+
|
297 |
+
function wp_statistics_countcomment() {
|
298 |
+
global $wpdb;
|
299 |
+
$countcomms = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->comments WHERE comment_approved = '1'");
|
300 |
+
if (0 < $countcomms) $countcomms = number_format($countcomms);
|
301 |
+
echo $countcomms;
|
302 |
+
}
|
303 |
+
|
304 |
+
function wp_statistics_countspam() {
|
305 |
+
echo number_format_i18n(get_option('akismet_spam_count'));
|
306 |
+
}
|
307 |
+
|
308 |
+
function wp_statistics_countusers() {
|
309 |
+
$result = count_users();
|
310 |
+
echo $result['total_users'];
|
311 |
+
}
|
312 |
+
|
313 |
+
function wp_statistics_lastpostdate($type=english) {
|
314 |
+
global $wpdb;
|
315 |
+
$db_date = $wpdb->get_var("SELECT post_date FROM $wpdb->posts WHERE post_type='post' AND post_status='publish' ORDER BY ID DESC LIMIT 1");
|
316 |
+
$date_format = get_option('date_format');
|
317 |
+
if ( $type == 'farsi' ) {
|
318 |
+
echo jdate($date_format, strtotime($db_date));
|
319 |
+
} else
|
320 |
+
echo date($date_format, strtotime($db_date));
|
321 |
+
}
|
322 |
+
|
323 |
+
function wp_statistics_average_post() {
|
324 |
+
global $wpdb;
|
325 |
+
$get_first_post = $wpdb->get_var("SELECT post_date FROM $wpdb->posts WHERE post_status = 'publish' ORDER BY post_date LIMIT 1");
|
326 |
+
$get_total_post = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->posts WHERE post_status = 'publish' AND post_type = 'post'");
|
327 |
+
|
328 |
+
$days_spend = intval((time() - strtotime($get_first_post) ) / (60*60*24));
|
329 |
+
echo $get_total_post / $days_spend;
|
330 |
+
}
|
331 |
+
|
332 |
+
function wp_statistics_average_comment() {
|
333 |
+
global $wpdb;
|
334 |
+
$get_first_comment = $wpdb->get_var("SELECT comment_date FROM $wpdb->comments ORDER BY comment_date LIMIT 1");
|
335 |
+
$get_total_comment = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->comments WHERE comment_approved = '1'");
|
336 |
+
|
337 |
+
$days_spend = intval((time() - strtotime($get_first_comment) ) / (60*60*24));
|
338 |
+
echo $get_total_comment / $days_spend;
|
339 |
+
}
|
340 |
+
|
341 |
+
function wp_statistics_average_registeruser() {
|
342 |
+
global $wpdb;
|
343 |
+
$get_first_user = $wpdb->get_var("SELECT user_registered FROM $wpdb->users ORDER BY user_registered LIMIT 1");
|
344 |
+
$get_total_user = $wpdb->get_var("SELECT COUNT(*) FROM $wpdb->users");
|
345 |
+
|
346 |
+
$days_spend = intval((time() - strtotime($get_first_user) ) / (60*60*24));
|
347 |
+
echo $get_total_user / $days_spend;
|
348 |
+
}
|
349 |
+
|
350 |
+
// Show Count Feedburner Subscribe by Affiliate Marketer
|
351 |
+
function wp_statistics_countsubscrib($feed_url) {
|
352 |
+
$feedcount = get_option("feedrsscount");
|
353 |
+
if ($feedcount['lastcheck'] < (mktime()-3600)) {
|
354 |
+
$whaturl='https://feedburner.google.com/api/awareness/1.0/GetFeedData?uri='.$feed_url;
|
355 |
+
$ch = curl_init();
|
356 |
+
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
|
357 |
+
curl_setopt($ch, CURLOPT_URL, $whaturl);
|
358 |
+
$data = curl_exec($ch);
|
359 |
+
curl_close($ch);
|
360 |
+
$xml = new SimpleXMLElement($data);
|
361 |
+
$fb = $xml->feed->entry['circulation'];
|
362 |
+
$feedcount['count'] = number_format($fb);
|
363 |
+
$feedcount['lastcheck'] = mktime();
|
364 |
+
update_option("feedrsscount",$feedcount);
|
365 |
+
}
|
366 |
+
echo $feedcount['count'];
|
367 |
+
}
|
368 |
+
|
369 |
+
include("include/google_pagerank.php");
|
370 |
+
include("include/alexa_pagerank.php");
|
371 |
+
|
372 |
+
/* End: functions for user in theme */
|
373 |
+
|
374 |
+
function wp_statistics_menu() {
|
375 |
+
if (function_exists('add_options_page')) {
|
376 |
+
add_menu_page(__('Statistics', 'wp_statistics'), __('Statistics', 'wp_statistics'), 'manage_options', 'wp-statistics', 'wp_statistics_config_permission', plugin_dir_url( __FILE__ ).'/images/icon.png');
|
377 |
+
add_submenu_page( 'wp-statistics', __('Stats weblog', 'wp_statistics'), __('Stats weblog', 'wp_statistics'), 'manage_options', 'wp-statistics/stats', 'wp_statistics_stats_permission');
|
378 |
+
add_submenu_page( 'wp-statistics', __('User Online', 'wp_statistics'), __('User Online', 'wp_statistics'), 'manage_options', 'wp-statistics/online', 'wp_statistics_online_permission');
|
379 |
+
}
|
380 |
+
}
|
381 |
+
|
382 |
+
function wp_statistics_config_permission() {
|
383 |
+
if (!current_user_can('manage_options')) {
|
384 |
+
wp_die( __('You do not have sufficient permissions to access this page.', 'wp_statistics') );
|
385 |
+
|
386 |
+
settings_fields( 'wp_statistics_options' );
|
387 |
+
function register_mysettings() {
|
388 |
+
register_setting('wp_statistics_options', 'enable_stats');
|
389 |
+
register_setting('wp_statistics_options', 'enable_decimals');
|
390 |
+
register_setting('wp_statistics_options', 'time_useronline');
|
391 |
+
register_setting('wp_statistics_options', 'items_statistics');
|
392 |
+
register_setting('wp_statistics_options', 'pagerank_google_url');
|
393 |
+
register_setting('wp_statistics_options', 'pagerank_alexa_url');
|
394 |
+
}} ?>
|
395 |
+
|
396 |
+
<script type="text/javascript" src="http://code.jquery.com/jquery-1.4.4.js"></script>
|
397 |
+
<script type="text/javascript">
|
398 |
+
$(document).ready(function(){
|
399 |
+
$("span#increase_total_visit").click(function(){
|
400 |
+
var total_increase_value = $("input#increase_total_visit").val();
|
401 |
+
$("input#increase_total_visit").attr("disabled", "disabled");
|
402 |
+
$("span#increase_total_visit").attr("disabled", "disabled");
|
403 |
+
$("div#result_increase_total_visit").html("<img src='<?php echo plugin_dir_url( __FILE__ ); ?>images/loading.gif'/>");
|
404 |
+
$.post("<?php echo plugin_dir_url( __FILE__ );?>/actions.php",{increase_value:total_increase_value},function(result){
|
405 |
+
$("div#result_increase_total_visit").html(result);
|
406 |
+
$("input#increase_total_visit").removeAttr("disabled");
|
407 |
+
$("span#increase_total_visit").removeAttr("disabled");
|
408 |
+
});
|
409 |
+
});
|
410 |
+
|
411 |
+
$("span#reduction_total_visit").click(function(){
|
412 |
+
var total_reduction_value = $("input#reduction_total_visit").val();
|
413 |
+
$("input#reduction_total_visit").attr("disabled", "disabled");
|
414 |
+
$("span#reduction_total_visit").attr("disabled", "disabled");
|
415 |
+
$("div#result_reduction_total_visit").html("<img src='<?php echo plugin_dir_url( __FILE__ ); ?>images/loading.gif'/>");
|
416 |
+
$.post("<?php echo plugin_dir_url( __FILE__ );?>/actions.php",{reduction_value:total_reduction_value},function(result){
|
417 |
+
$("div#result_reduction_total_visit").html(result);
|
418 |
+
$("input#reduction_total_visit").removeAttr("disabled");
|
419 |
+
$("span#reduction_total_visit").removeAttr("disabled");
|
420 |
+
});
|
421 |
+
});
|
422 |
+
|
423 |
+
$("span#show_function").click(function(){
|
424 |
+
$("div#report_problem").hide(1000);
|
425 |
+
$("ul#show_function").show(1000, function(){
|
426 |
+
$("code").delay(1000).fadeIn(1000);
|
427 |
+
});
|
428 |
+
});
|
429 |
+
|
430 |
+
$("span#hide_function").click(function(){
|
431 |
+
$("ul#show_function").hide(1000);
|
432 |
+
});
|
433 |
+
|
434 |
+
$("span#hide_report").click(function(){
|
435 |
+
$("div#report_problem").hide(1000);
|
436 |
+
});
|
437 |
+
|
438 |
+
$("span#report_problem").click(function(){
|
439 |
+
$("ul#show_function").hide(1000);
|
440 |
+
$("div#report_problem").show(1000);
|
441 |
+
});
|
442 |
+
|
443 |
+
$("span#send_report").click(function(){
|
444 |
+
var your_name = $("input#your_name").val();
|
445 |
+
var your_report = $("textarea#your_report").val();
|
446 |
+
$("div#result_problem").html("<img src='<?php echo plugin_dir_url( __FILE__ ); ?>images/loading.gif'/>");
|
447 |
+
$("div#result_problem").load("<?php echo plugin_dir_url( __FILE__ );?>/report_problem.php", {y_name:your_name, d_report:your_report});
|
448 |
+
});
|
449 |
+
});
|
450 |
+
</script>
|
451 |
+
|
452 |
+
<div class="wrap">
|
453 |
+
<h2><img src="<?php echo plugin_dir_url( __FILE__ ); ?>/images/icon_big.png"/> <?php _e('Configuration', 'wp_statistics'); ?></h2>
|
454 |
+
<table class="form-table">
|
455 |
+
<form method="post" action="options.php">
|
456 |
+
<?php wp_nonce_field('update-options');?>
|
457 |
+
<tr style="background-color:#EEEEEE; border:1px solid #DDDDDD;">
|
458 |
+
<td width="250"><?php _e('Enable Statistics', 'wp_statistics'); ?>:</td>
|
459 |
+
<td width="200">
|
460 |
+
<?php $get_enable_stats = get_option('enable_stats'); ?>
|
461 |
+
<input type="checkbox" name="enable_stats" id="enable_stats" <?php echo $get_enable_stats==true? "checked='checked'" : '';?>/>
|
462 |
+
<label for="enable_stats"><?php _e('Yes', 'wp_statistics'); ?></label>
|
463 |
+
</td>
|
464 |
+
<td>
|
465 |
+
<?php if($get_enable_stats) { ?>
|
466 |
+
<span style="font-size:11px; color:#009900;">(<?php _e('Statistics are disabled.', 'wp_statistics'); ?>)</span>
|
467 |
+
<?php } else { ?>
|
468 |
+
<span style="font-size:11px; color:#FF0000;">(<?php _e('Statistics are disabled!', 'wp_statistics'); ?>)</span>
|
469 |
+
<?php } ?>
|
470 |
+
</td>
|
471 |
+
</tr>
|
472 |
+
|
473 |
+
<tr><th><h3><?php _e('General configuration', 'wp_statistics'); ?></h4></th></tr>
|
474 |
+
|
475 |
+
<tr>
|
476 |
+
<td><?php _e('Show decimals number', 'wp_statistics'); ?>:</td>
|
477 |
+
<td>
|
478 |
+
<?php $get_enable_stats = get_option('enable_decimals'); ?>
|
479 |
+
<input type="checkbox" name="enable_decimals" id="enable_decimals" <?php echo $get_enable_stats==true? "checked='checked'" : '';?>/>
|
480 |
+
<label for="enable_decimals"><?php _e('Yes', 'wp_statistics'); ?></label>
|
481 |
+
</td>
|
482 |
+
<td><span style="font-size:11px;">(<?php _e('Show number stats with decimal. For examle: 3,500', 'wp_statistics'); ?>)</span></td>
|
483 |
+
</tr>
|
484 |
+
|
485 |
+
<tr>
|
486 |
+
<td><?php _e('Online user check time', 'wp_statistics'); ?>:</td>
|
487 |
+
<td>
|
488 |
+
<span style="font-size:10px;"><?php _e('Each', 'wp_statistics'); ?></span>
|
489 |
+
<input type="text" name="time_useronline" style="direction:ltr; width:60px" maxlength="3" value="<?php echo get_option('time_useronline'); ?>"/>
|
490 |
+
<span style="font-size:10px;"><?php _e('Compute min', 'wp_statistics'); ?></span>
|
491 |
+
</td>
|
492 |
+
<td><span style="font-size:11px;">(<?php _e('Time for the check accurate online user in the site. Default: 5 Minutes', 'wp_statistics'); ?>)</span></td>
|
493 |
+
</tr>
|
494 |
+
|
495 |
+
<tr>
|
496 |
+
<td><?php _e('Increase value of the total hits', 'wp_statistics'); ?>:</td>
|
497 |
+
<td>
|
498 |
+
<input type="text" name="increase_total_visit" id="increase_total_visit" style="direction:ltr; width:100px" maxlength="10"/>
|
499 |
+
<span class="button" id="increase_total_visit" style="width:50px;"><?php _e('Done', 'wp_statistics'); ?></span>
|
500 |
+
<div id="result_increase_total_visit" style="font-size:11px;"></div>
|
501 |
+
</td>
|
502 |
+
<td><span style="font-size:11px;">(<?php _e('Your total visit sum with this value', 'wp_statistics'); ?>)</span></td>
|
503 |
+
</tr>
|
504 |
+
|
505 |
+
<tr>
|
506 |
+
<td><?php _e('Reduction value of the total hits', 'wp_statistics'); ?>:</td>
|
507 |
+
<td>
|
508 |
+
<input type="text" name="reduction_total_visit" id="reduction_total_visit" style="direction:ltr; width:100px" maxlength="10"/>
|
509 |
+
<span class="button" id="reduction_total_visit" style="width:50px;"><?php _e('Done', 'wp_statistics'); ?></span>
|
510 |
+
<div id="result_reduction_total_visit" style="font-size:11px;"></div>
|
511 |
+
</td>
|
512 |
+
<td><span style="font-size:11px;">(<?php _e('Your total visit minus with this value', 'wp_statistics'); ?>)</span></td>
|
513 |
+
</tr>
|
514 |
+
|
515 |
+
<tr>
|
516 |
+
<td><?php _e('Number item for show Statistics', 'wp_statistics'); ?>:</td>
|
517 |
+
<td>
|
518 |
+
<input type="text" name="items_statistics" style="direction:ltr; width:70px" maxlength="3" value="<?php echo get_option('items_statistics'); ?>"/>
|
519 |
+
<span style="font-size:10px;"><?php _e('Default 5', 'wp_statistics'); ?></span>
|
520 |
+
</td>
|
521 |
+
<td><span style="font-size:11px;">(<?php _e('Number for submit item in Database and show that', 'wp_statistics'); ?>)</span></td>
|
522 |
+
</tr>
|
523 |
+
|
524 |
+
<tr><th><h3><?php _e('Live Statistics configuration', 'wp_statistics'); ?></h4></th></tr>
|
525 |
+
|
526 |
+
<tr>
|
527 |
+
<td><?php _e('Database check time', 'wp_statistics'); ?>:</td>
|
528 |
+
<td>
|
529 |
+
<span style="font-size:10px;"><?php _e('Each', 'wp_statistics'); ?></span>
|
530 |
+
<input type="text" style="direction:ltr; width:60px" maxlength="3" disabled="disable"/>
|
531 |
+
<span style="font-size:10px;"><?php _e('Minute updates', 'wp_statistics'); ?></span>
|
532 |
+
</td>
|
533 |
+
<td>
|
534 |
+
<span style="font-size:11px; color:#FF0000;"><?php _e('Recommended', 'wp_statistics'); ?></span>
|
535 |
+
<span style="font-size:11px;">(<?php _e('Due to pressure on the server, Be set up on time. Default 1 min.', 'wp_statistics'); ?>)</span>
|
536 |
+
</td>
|
537 |
+
</tr>
|
538 |
+
|
539 |
+
<tr><th><h3><?php _e('Pagerank configuration', 'wp_statistics'); ?></h4></th></tr>
|
540 |
+
|
541 |
+
<tr>
|
542 |
+
<td><?php _e('Your url for Google pagerank check', 'wp_statistics'); ?>:</td>
|
543 |
+
<td>
|
544 |
+
<input type="text" name="pagerank_google_url" style="direction:ltr; width:200px" value="<?php echo get_option('pagerank_google_url'); ?>"/>
|
545 |
+
</td>
|
546 |
+
<td>
|
547 |
+
<span style="font-size:11px;">(<?php _e('If this input is empty, The website url uses', 'wp_statistics'); ?>)</span>
|
548 |
+
</td>
|
549 |
+
</tr>
|
550 |
+
|
551 |
+
<tr>
|
552 |
+
<td><?php _e('Your url for Alexa pagerank check', 'wp_statistics'); ?>:</td>
|
553 |
+
<td>
|
554 |
+
<input type="text" name="pagerank_alexa_url" style="direction:ltr; width:200px" value="<?php echo get_option('pagerank_alexa_url'); ?>"/>
|
555 |
+
</td>
|
556 |
+
<td>
|
557 |
+
<span style="font-size:11px;">(<?php _e('If this input is empty, The website url uses', 'wp_statistics'); ?>)</span>
|
558 |
+
</td>
|
559 |
+
</tr>
|
560 |
+
|
561 |
+
<tr>
|
562 |
+
<th>
|
563 |
+
<h3><?php _e('About plugin', 'wp_statistics'); ?></h4>
|
564 |
+
<?php _e('Plugin Version', 'wp_statistics'); ?>: <?php _e('Free!', 'wp_statistics'); ?>
|
565 |
+
<a href="http://www.wpbazar.com/products/wp-statistics-premium"><span style="font-size:10px; color:#009900;"><?php _e('Get Premium version', 'wp_statistics'); ?></span></a>
|
566 |
+
</th>
|
567 |
+
</tr>
|
568 |
+
|
569 |
+
<td colspan="3">
|
570 |
+
<?php _e('This plugin created by', 'wp_statistics'); ?> <a href="http://profile.wordpress.org/mostafa.s1990">Mostafa Soufi</a> <?php _e('from', 'wp_statistics'); ?> <a href="http://wpbazar.com">WPBazar</a> <?php _e('and', 'wp_statistics'); ?> <a href="http://wp-persian.com">WP-Persian</a> <?php _e('group', 'wp_statistics'); ?>.
|
571 |
+
<?php _e('for translate language files. please send files for', 'wp_statistics'); ?> <code>mst404@gmail.com</code>
|
572 |
+
<p style="padding-top: 5px;">
|
573 |
+
<span class="button" id="show_function"><?php _e('Show Functions', 'wp_statistics'); ?></span>
|
574 |
+
<span class="button" id="report_problem"><?php _e('Report Problem', 'wp_statistics'); ?></span>
|
575 |
+
</p>
|
576 |
+
|
577 |
+
<style>
|
578 |
+
a{text-decoration: none}
|
579 |
+
ul#show_function code{border-radius:5px; padding: 5px; display: none;}
|
580 |
+
ul#show_function{list-style-type: decimal; margin: 20px; display:none;}
|
581 |
+
ul#show_function li{line-height: 25px;}
|
582 |
+
div#report_problem{display: none;}
|
583 |
+
</style>
|
584 |
+
<ul id="show_function">
|
585 |
+
<li><?php _e('User Online', 'wp_statistics'); ?> <code>wp_statistics_useronline();</code>
|
586 |
+
<li><?php _e('Today Visit', 'wp_statistics'); ?> <code>wp_statistics_today();</code>
|
587 |
+
<li><?php _e('Yesterday visit', 'wp_statistics'); ?> <code>wp_statistics_yesterday();</code>
|
588 |
+
<li><?php _e('Week Visit', 'wp_statistics'); ?> <code>wp_statistics_week();</code>
|
589 |
+
<li><?php _e('Month Visit', 'wp_statistics'); ?> <code>wp_statistics_month();</code>
|
590 |
+
<li><?php _e('Years Visit', 'wp_statistics'); ?> <code>wp_statistics_year();</code>
|
591 |
+
<li><?php _e('Total Visit', 'wp_statistics'); ?> <code>wp_statistics_total();</code>
|
592 |
+
<li><?php _e('Search Engine reffered', 'wp_statistics'); ?> <code>wp_statistics_searchengine();</code>
|
593 |
+
<li><?php _e('Total Posts', 'wp_statistics'); ?> <code>wp_statistics_countposts();</code>
|
594 |
+
<li><?php _e('Total Pages', 'wp_statistics'); ?> <code>wp_statistics_countpages();</code>
|
595 |
+
<li><?php _e('Total Comments', 'wp_statistics'); ?> <code>wp_statistics_countcomment();</code>
|
596 |
+
<li><?php _e('Total Spams', 'wp_statistics'); ?> <code>wp_statistics_countspam();</code>
|
597 |
+
<li><?php _e('Total Users', 'wp_statistics'); ?> <code>wp_statistics_countusers();</code>
|
598 |
+
<li><?php _e('Last Post Date', 'wp_statistics'); ?> <code>wp_statistics_lastpostdate();</code>
|
599 |
+
<li><?php _e('Average Posts', 'wp_statistics'); ?> <code>wp_statistics_average_post();</code>
|
600 |
+
<li><?php _e('Average Comments', 'wp_statistics'); ?> <code>wp_statistics_average_comment();</code>
|
601 |
+
<li><?php _e('Average Users', 'wp_statistics'); ?> <code>wp_statistics_average_registeruser();</code>
|
602 |
+
<li><?php _e('Total Feedburner Subscribe', 'wp_statistics'); ?> <code>wp_statistics_countsubscrib();</code>
|
603 |
+
<li><?php _e('Google Pagerank', 'wp_statistics'); ?> <code>wp_statistics_google_page_rank();</code>
|
604 |
+
<li><?php _e('Alexa Pagerank', 'wp_statistics'); ?> <code>wp_statistics_alexaRank();</code>
|
605 |
+
<br /><span class="button" id="hide_function"><?php _e('Hide', 'wp_statistics'); ?></span>
|
606 |
+
</ul>
|
607 |
+
|
608 |
+
<div id="report_problem">
|
609 |
+
<p><?php _e('Your Name', 'wp_statistics'); ?>:<br /><input type="text" name="your_name" id="your_name"/></p>
|
610 |
+
|
611 |
+
<p><?php _e('Description Problem', 'wp_statistics'); ?>:<br /><textarea name="your_report" id="your_report"/></textarea></p>
|
612 |
+
<div id="result_problem"></div>
|
613 |
+
<br />
|
614 |
+
<span class="button" id="send_report"><?php _e('Send Problem', 'wp_statistics'); ?></span>
|
615 |
+
<span class="button" id="hide_report"><?php _e('Hide', 'wp_statistics'); ?></span>
|
616 |
+
</div>
|
617 |
+
</th>
|
618 |
+
|
619 |
+
<tr>
|
620 |
+
<td>
|
621 |
+
<p class="submit">
|
622 |
+
<input type="hidden" name="action" value="update" />
|
623 |
+
<input type="hidden" name="page_options" value="enable_stats,enable_decimals,time_useronline,items_statistics,pagerank_google_url,pagerank_alexa_url" />
|
624 |
+
<input type="submit" class="button-primary" name="Submit" value="<?php _e('Update', 'wp_statistics'); ?>" />
|
625 |
+
</p>
|
626 |
+
</td>
|
627 |
+
</tr>
|
628 |
+
</form>
|
629 |
+
</table>
|
630 |
+
</div>
|
631 |
+
|
632 |
+
<?php }
|
633 |
+
function wp_statistics_stats_permission() {
|
634 |
+
if (!current_user_can('manage_options')) {
|
635 |
+
wp_die( __('You do not have sufficient permissions to access this page.', 'wp_statistics') ); } ?>
|
636 |
+
<div class="wrap">
|
637 |
+
<h2><img src="<?php echo plugin_dir_url( __FILE__ ); ?>/images/icon_big.png"/> <?php _e('Stats weblog', 'wp_statistics'); ?></h2>
|
638 |
+
<table class="form-table">
|
639 |
+
<?php
|
640 |
+
global $wpdb, $table_prefix;
|
641 |
+
$get_user_ip = $wpdb->get_col("SELECT ip FROM {$table_prefix}statistics_reffered");
|
642 |
+
$get_user_time = $wpdb->get_col("SELECT time FROM {$table_prefix}statistics_reffered");
|
643 |
+
$get_user_referred = $wpdb->get_col("SELECT referred FROM {$table_prefix}statistics_reffered");
|
644 |
+
$get_user_agent = $wpdb->get_col("SELECT agent FROM {$table_prefix}statistics_reffered");
|
645 |
+
$get_total_online = $wpdb->get_var("SELECT COUNT(*) FROM {$table_prefix}statistics_reffered");
|
646 |
+
|
647 |
+
echo "<tr style='background-color:#EEEEEE; border:1px solid #DDDDDD;' align='center'>";
|
648 |
+
echo "<td width='5'>".__('No', 'wp_statistics')."</td>";
|
649 |
+
echo "<td>".__('IP', 'wp_statistics')."</td>";
|
650 |
+
echo "<td>".__('Time', 'wp_statistics')."</td>";
|
651 |
+
echo "<td>".__('Referred', 'wp_statistics')."</td>";
|
652 |
+
echo "<td>".__('Agent', 'wp_statistics')."</td>";
|
653 |
+
echo "</tr>";
|
654 |
+
|
655 |
+
for($i=0; $i<$get_total_online; $i++) {
|
656 |
+
$j = $i+1;
|
657 |
+
echo "<tr style='border:1px solid #EEEEEE; direction:ltr;'>";
|
658 |
+
echo "<td>$j</td>";
|
659 |
+
echo "<td>$get_user_ip[$i]</td>";
|
660 |
+
echo "<td>$get_user_time[$i]</td>";
|
661 |
+
echo "<td><a href='$get_user_referred[$i]' target='_blank'>$get_user_referred[$i]</a></td>";
|
662 |
+
echo "<td>$get_user_agent[$i]</td>";
|
663 |
+
echo "</tr>";
|
664 |
+
}
|
665 |
+
?>
|
666 |
+
</table>
|
667 |
+
</div>
|
668 |
+
<?php }
|
669 |
+
function wp_statistics_online_permission() {
|
670 |
+
if (!current_user_can('manage_options')) {
|
671 |
+
wp_die( __('You do not have sufficient permissions to access this page.', 'wp_statistics') ); } ?>
|
672 |
+
<div class="wrap">
|
673 |
+
<h2><img src="<?php echo plugin_dir_url( __FILE__ ); ?>/images/icon_big.png"/> <?php _e('User Online', 'wp_statistics'); ?></h2>
|
674 |
+
<table class="form-table">
|
675 |
+
<?php
|
676 |
+
global $wpdb, $table_prefix;
|
677 |
+
$get_user_ip = $wpdb->get_col("SELECT ip FROM {$table_prefix}statistics_useronline");
|
678 |
+
$get_user_time = $wpdb->get_col("SELECT time FROM {$table_prefix}statistics_useronline");
|
679 |
+
$get_user_referred = $wpdb->get_col("SELECT referred FROM {$table_prefix}statistics_useronline");
|
680 |
+
$get_user_agent = $wpdb->get_col("SELECT agent FROM {$table_prefix}statistics_useronline");
|
681 |
+
$get_total_online = $wpdb->get_var("SELECT COUNT(*) FROM {$table_prefix}statistics_useronline");
|
682 |
+
|
683 |
+
echo "<tr style='background-color:#EEEEEE; border:1px solid #DDDDDD;' align='center'>";
|
684 |
+
echo "<td width='5'>".__('No', 'wp_statistics')."</td>";
|
685 |
+
echo "<td>".__('IP', 'wp_statistics')."</td>";
|
686 |
+
echo "<td>".__('Time', 'wp_statistics')."</td>";
|
687 |
+
echo "<td>".__('Referred', 'wp_statistics')."</td>";
|
688 |
+
echo "<td>".__('Agent', 'wp_statistics')."</td>";
|
689 |
+
echo "</tr>";
|
690 |
+
|
691 |
+
for($i=0; $i<$get_total_online; $i++) {
|
692 |
+
$j = $i+1;
|
693 |
+
echo "<tr style='border:1px solid #EEEEEE; direction:ltr;'>";
|
694 |
+
echo "<td>$j</td>";
|
695 |
+
echo "<td>$get_user_ip[$i]</td>";
|
696 |
+
echo "<td>$get_user_time[$i]</td>";
|
697 |
+
echo "<td><a href='$get_user_referred[$i]' target='_blank'>$get_user_referred[$i]</a></td>";
|
698 |
+
echo "<td>$get_user_agent[$i]</td>";
|
699 |
+
echo "</tr>";
|
700 |
+
}
|
701 |
+
?>
|
702 |
+
</table>
|
703 |
+
</div>
|
704 |
+
<?php }
|
705 |
+
function wp_statistics_show_widget() {
|
706 |
+
echo "<h3 class='widget-title'>".get_option('wp_statistics_widget_title')."</h3>";
|
707 |
echo "<ul>";
|
708 |
echo "<li>";
|
709 |
+
echo __('User Online', 'wp_statistics'). ": ";
|
710 |
+
wp_statistics_useronline();
|
711 |
echo "</li>";
|
712 |
|
713 |
echo "<li>";
|
714 |
+
echo __('Today Visit', 'wp_statistics'). ": ";
|
715 |
+
wp_statistics_today();
|
716 |
echo "</li>";
|
717 |
+
|
718 |
echo "<li>";
|
719 |
+
echo __('Yesterday Visit', 'wp_statistics'). ": ";
|
720 |
+
wp_statistics_yesterday();
|
721 |
echo "</li>";
|
722 |
|
723 |
echo "<li>";
|
724 |
+
echo __('Total Visit', 'wp_statistics'). ": ";
|
725 |
+
wp_statistics_total();
|
726 |
+
echo "</li>";
|
727 |
+
|
728 |
+
echo "<li>";
|
729 |
+
echo __('Total Posts', 'wp_statistics'). ": ";
|
730 |
+
wp_statistics_countposts();
|
731 |
echo "</li>";
|
732 |
|
733 |
echo "<li>";
|
734 |
+
echo __('Total Comments', 'wp_statistics'). ": ";
|
735 |
+
wp_statistics_countcomment();
|
736 |
echo "</li>";
|
737 |
|
738 |
echo "<li>";
|
739 |
+
echo __('Last Post Date', 'wp_statistics'). ": ";
|
740 |
+
if(get_option('wp_statistics_widget_typedate') == 'farsi') {
|
741 |
+
wp_statistics_lastpostdate('farsi');
|
742 |
+
} else {
|
743 |
+
wp_statistics_lastpostdate();
|
744 |
+
}
|
745 |
+
echo "</li>";
|
746 |
+
echo "</ul>";
|
747 |
}
|
|
|
|
|
|
|
748 |
|
749 |
+
function wp_statistics_control_widget(){
|
750 |
+
if ($_POST['wp_statistics_control_widget_submit']) {
|
751 |
+
$get_wp_statistics_widget_title = $_POST['wp_statistics_widget_title'];
|
752 |
+
update_option('wp_statistics_widget_title', $get_wp_statistics_widget_title);
|
753 |
|
754 |
+
$get_wp_statistics_widget_typedate = $_POST['wp_statistics_widget_typedate'];
|
755 |
+
update_option('wp_statistics_widget_typedate', $get_wp_statistics_widget_typedate);
|
756 |
+
} ?>
|
|
|
757 |
|
758 |
+
<p>
|
759 |
+
<?php _e('Name', 'wp_statistics'); ?><br />
|
760 |
+
<input id="wp_statistics_widget_title" name="wp_statistics_widget_title" type="text" value="<?php echo get_option('wp_statistics_widget_title'); ?>" />
|
761 |
+
</p>
|
|
|
|
|
762 |
|
763 |
+
<p>
|
764 |
+
<?php _e('Type date for last update', 'wp_statistics'); ?><br />
|
765 |
+
<input id="wp_statistics_widget_endate" name="wp_statistics_widget_typedate" value="english" type="radio" <?php checked( 'english', get_option('wp_statistics_widget_typedate') ); ?>/>
|
766 |
+
<label for="wp_statistics_widget_endate"><?php _e('English', 'wp_statistics'); ?><br />
|
767 |
+
|
768 |
+
<input id="wp_statistics_widget_jdate" name="wp_statistics_widget_typedate" value="farsi" type="radio" <?php checked( 'farsi', get_option('wp_statistics_widget_typedate') ); ?>/>
|
769 |
+
<label for="wp_statistics_widget_jdate"><?php _e('Persian', 'wp_statistics'); ?>
|
770 |
+
</p>
|
771 |
|
772 |
+
<input type="hidden" id="wp_statistics_control_widget_submit" name="wp_statistics_control_widget_submit" value="1" />
|
773 |
+
<?php }
|
|
|
|
|
774 |
|
775 |
+
add_shortcode('useronline', 'wp_statistics_useronline');
|
776 |
+
add_shortcode('today', 'wp_statistics_today');
|
777 |
+
add_shortcode('yesterday', 'wp_statistics_yesterday');
|
778 |
+
add_shortcode('week', 'wp_statistics_week');
|
779 |
+
add_shortcode('month', 'wp_statistics_month');
|
780 |
+
add_shortcode('year', 'wp_statistics_year');
|
781 |
+
add_shortcode('total', 'wp_statistics_total');
|
782 |
+
add_shortcode('searchengine', 'wp_statistics_searchengine');
|
783 |
+
add_shortcode('countposts', 'wp_statistics_countposts');
|
784 |
+
add_shortcode('countpages', 'wp_statistics_countpages');
|
785 |
+
add_shortcode('countcomments', 'wp_statistics_countcomment');
|
786 |
+
add_shortcode('countspams', 'wp_statistics_countspam');
|
787 |
+
add_shortcode('countusers', 'wp_statistics_countusers');
|
788 |
+
add_shortcode('lastpostdate', 'wp_statistics_lastpostdate');
|
789 |
+
add_shortcode('averagepost', 'wp_statistics_average_post');
|
790 |
+
add_shortcode('averagecomment', 'wp_statistics_average_comment');
|
791 |
+
add_shortcode('averageusers', 'wp_statistics_average_registeruser');
|
792 |
+
add_shortcode('googlepagerank', 'wp_statistics_google_page_rank');
|
793 |
+
add_shortcode('alexaRank', 'wp_statistics_alexaRank');
|
794 |
|
795 |
+
add_filter('widget_text', 'do_shortcode');
|
796 |
+
|
797 |
+
function wp_statistics_widget() {
|
798 |
+
wp_register_sidebar_widget('wp_statistics_widget', __('WP-Statistics', 'wp_statistics'), 'wp_statistics_show_widget', array(
|
799 |
+
'description' => __('Show site stats in sidebar', 'wp_statistics')));
|
800 |
+
wp_register_widget_control('wp_statistics_widget', __('WP-Statistics', 'wp_statistics'), 'wp_statistics_control_widget');
|
801 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
802 |
?>
|
wp-statistics.po
DELETED
@@ -1,62 +0,0 @@
|
|
1 |
-
msgid ""
|
2 |
-
msgstr ""
|
3 |
-
"Project-Id-Version: wp-statistics\n"
|
4 |
-
"Report-Msgid-Bugs-To: \n"
|
5 |
-
"POT-Creation-Date: 2011-03-20 16:22+0330\n"
|
6 |
-
"PO-Revision-Date: \n"
|
7 |
-
"Last-Translator: Mostafa <mst404@gmail.com>\n"
|
8 |
-
"Language-Team: <mat404@gmail.com>\n"
|
9 |
-
"MIME-Version: 1.0\n"
|
10 |
-
"Content-Type: text/plain; charset=utf-8\n"
|
11 |
-
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"X-Poedit-KeywordsList: __;_e\n"
|
13 |
-
"X-Poedit-Basepath: .\n"
|
14 |
-
"X-Poedit-Language: English\n"
|
15 |
-
"X-Poedit-Country: UNITED KINGDOM\n"
|
16 |
-
"X-Poedit-SearchPath-0: .\n"
|
17 |
-
|
18 |
-
#: F:\Program
|
19 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:15
|
20 |
-
msgid "Statistics"
|
21 |
-
msgstr "Statistics"
|
22 |
-
|
23 |
-
#: F:\Program
|
24 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:18
|
25 |
-
msgid "Total Posts: "
|
26 |
-
msgstr "Total Posts: "
|
27 |
-
|
28 |
-
#: F:\Program
|
29 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:23
|
30 |
-
msgid "Total Pages: "
|
31 |
-
msgstr "Total Pages: "
|
32 |
-
|
33 |
-
#: F:\Program
|
34 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:28
|
35 |
-
msgid "Total Comments: "
|
36 |
-
msgstr "Total Comments: "
|
37 |
-
|
38 |
-
#: F:\Program
|
39 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:33
|
40 |
-
msgid "Total Spams: "
|
41 |
-
msgstr "Total Spams: "
|
42 |
-
|
43 |
-
#: F:\Program
|
44 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:38
|
45 |
-
msgid "Last Post Date: "
|
46 |
-
msgstr "Last Post Date: "
|
47 |
-
|
48 |
-
#: F:\Program
|
49 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:43
|
50 |
-
msgid "Total Blog Hits: "
|
51 |
-
msgstr "Total Blog Hits: "
|
52 |
-
|
53 |
-
#: F:\Program
|
54 |
-
#: Files\wamp\www\wordpress\wp-content\plugins\wp-statistics/wp-statistics.php:49
|
55 |
-
msgid "Summary statistics of blog"
|
56 |
-
msgstr "Summary statistics of blog"
|
57 |
-
|
58 |
-
#~ msgid "Latest posts in wpdelicious"
|
59 |
-
#~ msgstr "آخرین ارسالی های وردپرس"
|
60 |
-
#~ msgid "Latest Delicious"
|
61 |
-
#~ msgstr "آخرین ارسالی ها"
|
62 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
wp-statistics.txt
DELETED
@@ -1 +0,0 @@
|
|
1 |
-
81
|
|