summary refs log tree commit diff stats
path: root/pages/welcome.php
diff options
context:
space:
mode:
Diffstat (limited to 'pages/welcome.php')
-rwxr-xr-xpages/welcome.php22
1 files changed, 20 insertions, 2 deletions
diff --git a/pages/welcome.php b/pages/welcome.php index e224c8e..26f9938 100755 --- a/pages/welcome.php +++ b/pages/welcome.php
@@ -22,13 +22,24 @@ if (!defined('S_INCLUDE_FILE')) {define('S_INCLUDE_FILE',1);}
22 22
23require('headerproc.php'); 23require('headerproc.php');
24 24
25$pageCategory = 'home'; 25$pageCategory = 'blog';
26
27$hatNav = array( array( 'title' => 'Archive',
28 'url' => 'http://fourisland.com/blog/',
29 'icon' => '16-file-archive'));
30
26 31
27$template = new FITemplate('post'); 32$template = new FITemplate('post');
28$template->adds_block('EXTERNAL',array('exi'=>1)); 33$template->adds_block('EXTERNAL',array('exi'=>1));
29 34
30$curID = 0; 35$curID = 0;
31 36
37$gettrack = "SELECT * FROM tracking WHERE ip = \"" . $_SERVER['REMOTE_ADDR'] . "\"";
38$gettrack2 = mysql_query($gettrack);
39$gettrack3 = mysql_fetch_array($gettrack2);
40
41$trackArr = explode(',',$gettrack3['rating']);
42
32$getpost = "SELECT * FROM updates ORDER BY id DESC LIMIT 0,4"; 43$getpost = "SELECT * FROM updates ORDER BY id DESC LIMIT 0,4";
33$getpost2 = mysql_query($getpost); 44$getpost2 = mysql_query($getpost);
34while ($getpost3 = mysql_fetch_array($getpost2)) 45while ($getpost3 = mysql_fetch_array($getpost2))
@@ -59,7 +70,7 @@ while ($getpost3 = mysql_fetch_array($getpost2))
59 70
60 $template->add_ref($curID, 'POST', array( 'ID' => $getpost3['id'], 71 $template->add_ref($curID, 'POST', array( 'ID' => $getpost3['id'],
61 'YEARID' => ((date('Y',strtotime($getpost3['pubDate']))-2006) % 4), 72 'YEARID' => ((date('Y',strtotime($getpost3['pubDate']))-2006) % 4),
62 'DATE' => date('F dS Y \a\\t g:i:s a',strtotime($getpost3['pubDate'])), 73 'DATE' => date('F jS Y \a\\t g:i:s a',strtotime($getpost3['pubDate'])),
63 'MONTH' => date('M',strtotime($getpost3['pubDate'])), 74 'MONTH' => date('M',strtotime($getpost3['pubDate'])),
64 'DAY' => date('d',strtotime($getpost3['pubDate'])), 75 'DAY' => date('d',strtotime($getpost3['pubDate'])),
65 'CODED' => $getpost3['slug'], 76 'CODED' => $getpost3['slug'],
@@ -76,6 +87,13 @@ while ($getpost3 = mysql_fetch_array($getpost2))
76 $template->adds_ref_sub($curID, 'TAGS', array('TAG' => $tag)); 87 $template->adds_ref_sub($curID, 'TAGS', array('TAG' => $tag));
77 } 88 }
78 89
90 if (($gettrack3['ip'] != $_SERVER['REMOTE_ADDR']) || (array_search($getpost3['id'],$trackArr) === FALSE))
91 {
92 $template->adds_ref_sub($curID, 'CANVOTE', array('exi'=>1));
93 } else {
94 $template->adds_ref_sub($curID, 'NOVOTE', array('exi'=>1));
95 }
96
79 $curID++; 97 $curID++;
80} 98}
81 99