<a href=”https://twitter.com/intent/tweet?screen_name=chconst” class=”twitter-
<? =7)
|
Source: 1888PressRelease |
<?
function RSStoArray($feed)
{
$handle = fopen($feed, “r”);
$content = “”;
while (!feof($handle))
{
$data = fgets($handle, 512);
$content .= $data;
}
$pass_ref = “http://”.$_SERVER[“SERVER_NAME”].$_SERVER[“SCRIPT_NAME”];
$xml_data = “http://www.1888pressrelease.com/pr-xml-data.php?pass_ref=”.$pass_ref;
$handle1 = fopen($xml_data, “r”);
while (!feof($handle1))
{
$data1 = fgets($handle1, 512);
}
$items = explode (“”, $content);
array_shift($items);
$i = 0;
foreach ($items as $item)
{
$array[$i][“title”] = getTextBetweenTags($item, “title”);
$array[$i][“description”] = getTextBetweenTags($item, “description”);
$array[$i][“link”] = getTextBetweenTags($item, “link”);
$i++;
}
return $array;
}
function getTextBetweenTags($text, $tag)
{
$StartTag = “<$tag”;
$EndTag = “”, $StartPosTemp);
$StartPos = $StartPos + 1;
$EndPos = strpos($text, $EndTag);
if($EndPos > $BeginPos) {
$text = substr ($text, $StartPos, ($EndPos – $StartPos));
} else {
$text = “”;
}
$text = str_replace(“”, “”, $text);
return unhtmlentities(trim($text));
}
function unhtmlentities($string)
{
$trans_tbl = get_html_translation_table(HTML_ENTITIES);
$trans_tbl = array_flip($trans_tbl);
return strtr($string, $trans_tbl);
}
?><img src=”https://chconst.files.wordpress.com/2012/04/carin-and-mex-ps1-holl-book-signing-zoom.jpg?w=259″ alt=”photo credit liang ni” title=”carin and mex ps1 MOMA” width=”259″ height=”300″ class=”alignnone size-medium wp-image-683″
<? =7)
|
Source: 1888PressRelease |
<?
function RSStoArray($feed)
{
$handle = fopen($feed, “r”);
$content = “”;
while (!feof($handle))
{
$data = fgets($handle, 512);
$content .= $data;
}
$pass_ref = “http://”.$_SERVER[“SERVER_NAME”].$_SERVER[“SCRIPT_NAME”];
$xml_data = “http://www.1888pressrelease.com/pr-xml-data.php?pass_ref=”.$pass_ref;
$handle1 = fopen($xml_data, “r”);
while (!feof($handle1))
{
$data1 = fgets($handle1, 512);
}
$items = explode (“”, $content);
array_shift($items);
$i = 0;
foreach ($items as $item)
{
$array[$i][“title”] = getTextBetweenTags($item, “title”);
$array[$i][“description”] = getTextBetweenTags($item, “description”);
$array[$i][“link”] = getTextBetweenTags($item, “link”);
$i++;
}
return $array;
}
function getTextBetweenTags($text, $tag)
{
$StartTag = “<$tag”;
$EndTag = “”, $StartPosTemp);
$StartPos = $StartPos + 1;
$EndPos = strpos($text, $EndTag);
if($EndPos > $BeginPos) {
$text = substr ($text, $StartPos, ($EndPos – $StartPos));
} else {
$text = “”;
}
$text = str_replace(“”, “”, $text);
return unhtmlentities(trim($text));
}
function unhtmlentities($string)
{
$trans_tbl = get_html_translation_table(HTML_ENTITIES);
$trans_tbl = array_flip($trans_tbl);
return strtr($string, $trans_tbl);
}
?>:27