<?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>Vim, Cygwin, MySQL &#38; Zsh Tips by zzapper &#187; PHP</title>
	<atom:link href="http://zzapper.co.uk/tag/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://zzapper.co.uk</link>
	<description></description>
	<lastBuildDate>Wed, 18 Jan 2012 23:15:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>How to Design a Database Driven PHP Page</title>
		<link>http://zzapper.co.uk/how-to-design-a-database-driven-php-page/</link>
		<comments>http://zzapper.co.uk/how-to-design-a-database-driven-php-page/#comments</comments>
		<pubDate>Wed, 11 Nov 2009 13:30:55 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://zzapper.co.uk/?p=40</guid>
		<description><![CDATA[Design a Database Driven PHP Page Many PHP pages turn into a mess because the PHP code is embedded into the HTML and. Over time this gets more and more tangled as the requirements change. What is required is to make all the necessary database queries and all the manipulation of the data BEFORE you [...]]]></description>
			<content:encoded><![CDATA[<p>Design a Database Driven PHP Page</p>
<p>Many PHP pages turn into a mess because the PHP code is embedded into the HTML and. Over time this gets more and more tangled as the requirements change.</p>
<p>What is required is to make all the necessary database queries and all the manipulation of the data BEFORE you reach the first  tag.</p>
<p>All that should appear in the HTML are the various php echos to output the dynamic parts of the page.</p>
<p>So here is the structure of a PHP page<br />
<table border=1>
<tr>
<td width=90%>
query database
</td>
</tr>
<tr>
<td width=90%>
insert data from queries into php arrays (hashs)
</td>
</tr>
<tr>
<td width=90%>
General functions
</td>
</tr>
<tr>
<td width=90%>
Main section call functions, which manipulate the data to get that required by the dynamic web page
</td>
</tr>
<tr>
<td width=90%>
html section
</td>
</tr>
</table>
]]></content:encoded>
			<wfw:commentRss>http://zzapper.co.uk/how-to-design-a-database-driven-php-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

