Help
-
Search
-
Members
-
Calendar
Full Version:
code for the people
Forums
>
Resource Center
>
Support Center
>
Xanga Support
>
Xanga Resolved Topics
xnikkay
Apr 25 2005, 10:22 PM
whats the code for the people who visit ur site, if there still is one.
YourSuperior
Apr 25 2005, 10:25 PM
There is one from here on Cb, but you have to be an offical member to use it. But you can also get an xanga tracker.
XANGA TRACKER
<!-- begin code provided by createblog.com --><br />
<html><br />
<head><br />
<title></title><br />
</head><br />
<body><br />
<?php<br />
<br />
$date = date("MjY"); <br />
if (!$filename) { <br />
$filename = "logs/".$date.".txt"; <br />
if (file_exists("$filename")) {<br />
}<br />
<br />
// If you want to change the way your log looks, change whatever is in the string<br />
else {<br />
$fp = fopen($filename,"x");<br />
fputs($fp,"<html>");<br />
fputs($fp,"<font face=\"Century Gothic\" size=\"2\">");<br />
fputs($fp,"Log File<BR>");<br />
fputs($fp,"<HR width=\"50%\" align=\"left\"><BR>");<br />
fputs($fp,"<table border=\"0\" width=\"50%\" style=\"font: normal 12px\">");<br />
<br />
<br />
fclose($fp); <br />
}<br />
}<br />
<br />
//the main code<br />
function ticker($filename,$remoted,$mode,$stuff) {<br />
$fp = fopen("checklist.txt","w+");<br />
$filename2 = "checklist.txt"; <br />
fputs($fp,"$remoted\n");<br />
fclose($fp);<br />
$check_var = 0;<br />
$inlines = file($filename2);<br />
$inline = file($filename);<br />
$number_of_lines = count($inline);<br />
return $check_var;<br />
}<br />
if (!ticker($filename,$REMOTE_ADDR,null,null)) {<br />
$fp = fopen($filename,"a");<br />
$date = date("M j, Y");<br />
$hour = (gmdate("g")-$offset+2);<br />
$time = date("i a");<br />
if($hour>12){<br />
$hour=$hour-12;<br />
}<br />
<br />
fputs($fp,"<tr><td width=80%>");<br />
fputs($fp,"<font face=\"Century Gothic\" size=\"2\">");<br />
fputs($fp,"<a href = \"".$link."\" style=\"text-decoration: none\">".$username."</a> - [".$hour.":".$time."] on ".$date<br />
."</td><td width=20%><p align=\"right\">"."$REMOTE_ADDR");<br />
<br />
fclose($fp);<br />
}<br />
?><br />
</body><br />
</html><br />
<br />
<br />
then put this on yer webstats on xanga. make shure where it says (http://www.yourhost.com/log.php) you put tha url .<br />
HOSTS :: i use hostultra.com <br />
<br />
<br />
<script><br />
// Programmed By Paul Chen<br />
<br />
if(location.pathname == '/home.aspx'){<br />
var links = document.getElementsByTagName ('a');<br />
<br />
phpLink = "http://www.yourhost.com/log.php";<br />
offset = -5;<br />
<br />
name = "";<br />
for (i = 0; i < links.length; i++) {<br />
Last = links[i+2].href<br />
if (links [i].innerHTML.match (/xanga/i) && (Last.match('signin.aspx') || Last.match('logout.aspx'))) {<br />
i++;link = links[i].href;<br />
if (link.match ('/private/home.aspx') || link.match ('register.aspx')) {<br />
name = links [i].innerHTML;break;<br />
}<br />
}<br />
}<br />
<br />
if(name=='join'){name = "Guest"}<br />
<br />
link = 'http://www.xanga.com/' + name;<br />
<br />
document.write('<img src="' + phpLink + '?username=' + name + '&link=' + link + '&offset=' + offset + '" width="0" height="0">');<br />
}<br />
</script><br />
<!-- end code provided by createblog.com -->
Teesa
Apr 25 2005, 10:27 PM
Do you mean a visitor logger? Here are sites that brianna (sweetxsimplicity) posted a while ago that might help-->
http://www.xanga.com/home.aspx?user=kaiyotee
http://www.xangaspy.com/
http://www.ocf.berkeley.edu/~bkp/xt/
http://www.syberdave.net/xanga/
http://suhock.net/xanga/xasm.html
http://www.mrpalmguru.com/php/logger.htm
http://www.milkwasabadchoice.com/xangalogger/
or you can always become an official member here
xnikkay
Apr 25 2005, 10:53 PM
alrite. thanks guys!
Teesa
Apr 25 2005, 10:53 PM
QUOTE(xnikkay @ Apr 25 2005, 10:53 PM)
alrite. thanks guys!
no problem
If you have any more questions, PM me.
topic closed
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here
.