<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>BytesitePHP</title>
	<atom:link href="http://www.bytesite.co.uk/tag/php/feed" rel="self" type="application/rss+xml" />
	<link>http://www.bytesite.co.uk</link>
	<description></description>
	<lastBuildDate>Fri, 12 Mar 2010 09:26:43 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.3</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Checking if an object is empty &#8211; PHP</title>
		<link>http://www.bytesite.co.uk/checking-if-an-object-is-empty-php</link>
		<comments>http://www.bytesite.co.uk/checking-if-an-object-is-empty-php#comments</comments>
		<pubDate>Mon, 15 Feb 2010 15:26:04 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.bytesite.co.uk/?p=289</guid>
		<description><![CDATA[As of PHP 5, objects with no properties are no longer considered empty.  Therefore is you use empty() to test if an object is empty will always return true.
The easiest way to check for an empty object is to cast it to an array:

$objAsArray = &#40;array&#41;$object;
if &#40; empty&#40; $objAsArray &#41; &#123;...&#125;

Incidently there are a [...]]]></description>
		<wfw:commentRss>http://www.bytesite.co.uk/checking-if-an-object-is-empty-php/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Drupal 6 &#8211; Views, programmatically set arguments</title>
		<link>http://www.bytesite.co.uk/drupal-6-views2-programmatically-set-arguments</link>
		<comments>http://www.bytesite.co.uk/drupal-6-views2-programmatically-set-arguments#comments</comments>
		<pubDate>Fri, 03 Jul 2009 15:33:45 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Drupal]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.bytesite.co.uk/?p=238</guid>
		<description><![CDATA[It is sometimes useful to programmatically load a view in Drupal, to execute it and then utilise the results.  This is all straightforward and well documented.  A little less documented is how to set the view arguements.

As with a lot of things, once you know it is easy:

$view = views_get_view&#40;$view_name&#41;;
$view-&#62;set_arguments&#40;$args&#41;;
$view-&#62;execute&#40;&#41;;
return $view-&#62;result;

Where $args is an array, [...]]]></description>
		<wfw:commentRss>http://www.bytesite.co.uk/drupal-6-views2-programmatically-set-arguments/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Alternative Syntax for UI</title>
		<link>http://www.bytesite.co.uk/php-alternative-syntax-for-ui</link>
		<comments>http://www.bytesite.co.uk/php-alternative-syntax-for-ui#comments</comments>
		<pubDate>Thu, 12 Feb 2009 11:58:22 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Syntax]]></category>

		<guid isPermaLink="false">http://www.bytesite.co.uk/?p=160</guid>
		<description><![CDATA[PHP has a slightly underused alternative syntax for control structures, which generally is more effective in template files than the standard block-style code.

If

if &#40;$a == 5&#41;:
    statement
    …
elseif &#40;$a == 6&#41;:
    statement
    …
else:
    statement
    …
endif;

While

while &#40;expr&#41;:
  [...]]]></description>
		<wfw:commentRss>http://www.bytesite.co.uk/php-alternative-syntax-for-ui/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
