Detect cURL and SimpleXMLElement for FeedBurner Counter

Before you implement FeedBurner counter (text mode) in any of your WordPress theme always remember to check for cURL and SimpleXMLElement.

function stream_capability() {
	return (!!class_exists("SimpleXMLElement") AND !!function_exists("curl_init") ? TRUE : FALSE);
}
Posted in Asides, Code Snippet, PHP, Programming, WordPress | Leave a comment

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>