Recently in PHP Category

/*note*/

$proxy_opts = array('http' => array('proxy' => 'tcp://proxy.name.com:8080',),);
$proxy_context=stream_context_create($proxy_opts);
    
$file = file_get_contents($rss,false,$proxy_context);


PHP:stream_context_create-Manual

(PHP) header() function

| No Comments | No TrackBacks
/*note*/

xml/html/css/javascript/plain
header("Content-Type: text/xml");
jpg/gif/png/
header("Content-Type: image/jpg");

Errors
header("HTTP/1.0 301 Moved Parmanently");
header("HTTP/1.0 401 Unauthorized");
header("HTTP/1.0 403 Forbidden");
header("HTTP/1.0 404 Not Found");
header("HTTP/1.0 500 Internal Server Error");

Redirect
header("Location: http://fkob.net");

No cash
header( 'Expires: Mon, 26 Jul 1997 05:00:00 GMT' );
header( 'Last-Modified: ' . gmdate( 'D, d M Y H:i:s' ) . ' GMT' );
header( 'Cache-Control: no-store, no-cache, must-revalidate' );
header( 'Cache-Control: post-check=0, pre-check=0', false );
header( 'Pragma: no-cache' );

(AS3) Strip Html Tags with allowable tags

| No Comments | No TrackBacks
As I was looking for the best way to remove the HTML tags from the feeds retrieved from Tumblr, I finally found this on Flex{er}.
Like strip_tags in PHP, "you could strip all HTML tags but the ones you specified as allowable tags. "

Strip Html Tags - with allowable tags | Flex{er}