\n";
for ($i = 0; $i < count($arr_xml['URL']); $i++) {
if( isset($arr_xml['PostID'][$i]) && $arr_xml['PostID'][$i] > 0 ) continue;
echo "
".$arr_xml['BeforeText'][$i]." ".$arr_xml['Text'][$i]." ".$arr_xml['AfterText'][$i]."\n";
}
echo "";
}
}
function tla_updateLocalXML($url, $file, $time_out)
{
if($handle = fopen($file, "a")){
fwrite($handle, "\n");
fclose($handle);
}
if($xml = file_get_contents_tla($url, $time_out)) {
$xml = substr($xml, strpos($xml,''));
if ($handle = fopen($file, "w")) {
fwrite($handle, $xml);
fclose($handle);
}
}
}
function tla_getLocalXML($file)
{
$contents = "";
if($handle = fopen($file, "r")){
$contents = fread($handle, filesize($file)+1);
fclose($handle);
}
return $contents;
}
function file_get_contents_tla($url, $time_out)
{
$result = "";
$url = parse_url($url);
if ($handle = @fsockopen ($url["host"], 80)) {
if(function_exists("socket_set_timeout")) {
socket_set_timeout($handle,$time_out,0);
} else if(function_exists("stream_set_timeout")) {
stream_set_timeout($handle,$time_out,0);
}
fwrite ($handle, "GET $url[path]?$url[query] HTTP/1.0\r\nHost: $url[host]\r\nConnection: Close\r\n\r\n");
while (!feof($handle)) {
$result .= @fread($handle, 40960);
}
fclose($handle);
}
return $result;
}
function tla_decodeXML($xmlstg)
{
if( !function_exists('html_entity_decode') ){
function html_entity_decode($string)
{
// replace numeric entities
$string = preg_replace('~([0-9a-f]+);~ei', 'chr(hexdec("\1"))', $string);
$string = preg_replace('~([0-9]+);~e', 'chr(\1)', $string);
// replace literal entities
$trans_tbl = get_html_translation_table(HTML_ENTITIES);
$trans_tbl = array_flip($trans_tbl);
return strtr($string, $trans_tbl);
}
}
$out = "";
$retarr = "";
preg_match_all ("/<(.*?)>(.*?)", $xmlstg, $out, PREG_SET_ORDER);
$search_ar = array('<', '>', '"');
$replace_ar = array('<', '>', '"');
$n = 0;
while (isset($out[$n]))
{
$retarr[$out[$n][1]][] = str_replace($search_ar, $replace_ar,html_entity_decode(strip_tags($out[$n][0])));
$n++;
}
return $retarr;
}
tla_ads();
?>
Comments (13)
爪子拔不出来了哈
Posted by p | May 29, 2006 11:53 AM
Posted on May 29, 2006 11:53
我咋不喜欢猫呢,我觉得很诡异
Posted by zikey | May 29, 2006 4:15 PM
Posted on May 29, 2006 16:15
大一点就不会打来打去了文静许多,另外女孩好象比男孩活泼?
Posted by p | May 29, 2006 6:10 PM
Posted on May 29, 2006 18:10
to Zikey
小动物养起来会上瘾的说!^^太可爱了!
to P
是的,小时候小母猫好像是比小公猫活泼一些,也凶一些
Posted by 黑羽 | May 29, 2006 7:56 PM
Posted on May 29, 2006 19:56
不能给自己的爱猫吃伟嘉啊。吃久了会得肾病的。要给他吃喜悦便宜猫猫也喜欢吃。
吃伟嘉为什么会得肾病的原因去百度里搜索“伟嘉肾病”就知道了。:)
真心爱自己的猫请给他吃优质的猫粮 :)
Posted by 春天的粪球 | May 29, 2006 11:24 PM
Posted on May 29, 2006 23:24
hoho,你这个信息早就过时喽
一年前维嘉就改进配方了。
喜悦只比维嘉贵两块。我也买过,但我们家大猫更爱吃维嘉。尤其是维嘉的妙鲜包 ^^
对喜悦的牛奶球不感冒。
Posted by 黑羽 | May 30, 2006 1:35 PM
Posted on May 30, 2006 13:35
过不过时我就不知道了,反正我自己闻起来都觉得喜悦比伟嘉香,我家的那几个都喜欢吃喜悦,我也只给他们吃喜悦,皇家太贵了,消费不起。哈哈。。
Posted by 春天的粪球 | May 30, 2006 11:24 PM
Posted on May 30, 2006 23:24
还有,妙鲜包听猫友说吃多了也不好,好象是味精多啊。还是什么的。我记得不是很清楚了,最好是自己给小家伙们做猫饭,或者是吃鸡肉条,听说很不错的。哈哈。
Posted by 春天的粪球 | May 30, 2006 11:26 PM
Posted on May 30, 2006 23:26
自己做猫饭??!
怎么做阿?有链接吗?发给我看看。^0^
我try try
Posted by 黑羽 | May 31, 2006 12:26 AM
Posted on May 31, 2006 00:26
呵呵....今天又给咪咪们做了一顿....粉有营养的饭饭
几个鸡肝切成丁.....(偶今年来第一次给他们吃鸡肝,所以不算过量)
半个土豆,半个胡萝卜切成丁
两个蛋黄(一个打散了,不然会更漂亮)
蛋清偶自己打蛋花吃了....
[attach]45215[/attach]
PS:
猫饭系列一:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列二:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列三:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列四:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列五:http://bbs.movshow.com/viewthrea ... mp;extra=#pid337930
猫饭系列六:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列七:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列八:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
猫饭系列九:http://bbs.movshow.com/viewthrea ... A%F1%BB%D0%A1%D6%ED
Posted by 春天的粪球 | May 31, 2006 6:44 PM
Posted on May 31, 2006 18:44
晕。怎么发不出拉来。
Posted by 春天的粪球 | May 31, 2006 6:46 PM
Posted on May 31, 2006 18:46
http://bbs.movshow.com/viewthread.php?tid=14998&fpage=1&highlight=%C3%A8%B7%B9%2B%F1%BA%F1%BB%D0%A1%D6%ED
一共9个系列
Posted by 春天的粪球 | May 31, 2006 6:48 PM
Posted on May 31, 2006 18:48
哈哈,多谢了。
我去看看 ^^
Posted by 黑羽 | June 1, 2006 1:18 AM
Posted on June 1, 2006 01:18