<?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"
	>

<channel>
	<title>Jenny’s Web World</title>
	<atom:link href="http://www.jennyconnors.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.jennyconnors.com</link>
	<description>music~computers~coffee~and more</description>
	<pubDate>Tue, 17 Jun 2008 22:42:08 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6</generator>
	<language>en</language>
			<item>
		<title>Articles of Impeachment for President George W Bush</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2/articles-of-impeachment-for-president-george-w-bush</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2/articles-of-impeachment-for-president-george-w-bush#comments</comments>
		<pubDate>Tue, 17 Jun 2008 22:42:08 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/politics/articles-of-impeachment-for-president-george-w-bush</guid>
		<description><![CDATA[Did you know that Dennis Kucinich introduced articles of impeachment in Congress last week??  Hardly anyone does.?  Why the mainstream media is ignoring this story is beyond my comprehension.
Read the articles at ImpeachBush.org.
]]></description>
			<content:encoded><![CDATA[<p>Did you know that Dennis Kucinich introduced articles of impeachment in Congress last week??  Hardly anyone does.?  Why the mainstream media is ignoring this story is beyond my comprehension.</p>
<p><a href="http://www.impeachbush.org/site/News2?page=NewsArticle&amp;id=5283" target="_blank">Read the articles</a> at <a href="http://www.impeachbush.org/" target="_blank">ImpeachBush.org</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2/articles-of-impeachment-for-president-george-w-bush/feed</wfw:commentRss>
		</item>
		<item>
		<title>A Nation In Debt</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2/a-nation-in-debt</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2/a-nation-in-debt#comments</comments>
		<pubDate>Tue, 10 Jun 2008 14:58:29 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/politics/a-nation-in-debt</guid>
		<description><![CDATA[A very important article A Nation In Debt: How we killed thrift, enthroned loan sharks and undermined American prosperity, by Barbara Dafoe Whitehead at http://www.the-american-interest.com/ai2/article.cfm?Id=458&#38;MId=20.
]]></description>
			<content:encoded><![CDATA[<p>A very important article <em>A Nation In Debt: How we killed thrift, enthroned loan sharks and undermined American prosperity</em>, by Barbara Dafoe Whitehead at <a href="http://www.the-american-interest.com/ai2/article.cfm?Id=458&amp;MId=20" target="_blank">http://www.the-american-interest.com/ai2/article.cfm?Id=458&amp;MId=20</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2/a-nation-in-debt/feed</wfw:commentRss>
		</item>
		<item>
		<title>cat shelter in Pepperell Massachusetts is being closed</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2-2-2/cat-shelter-in-pepperell-massachusetts-is-being-closed</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2-2-2/cat-shelter-in-pepperell-massachusetts-is-being-closed#comments</comments>
		<pubDate>Sun, 20 Apr 2008 01:02:54 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/uncategorized/cat-shelter-in-pepperell-massachusetts-is-being-closed</guid>
		<description><![CDATA[This sent to me from a friend who used to live in Pepperell:
&#8220;Due to the owner&#8217;s unexpected/untimely death a cat shelter in Pepperell Massachusetts is being closed by the state and 150 cats will have to be put down. The daughter doesn&#8217;t have a license to run the shelter. So in the next week or [...]]]></description>
			<content:encoded><![CDATA[<p>This sent to me from a friend who used to live in Pepperell:</p>
<p class="MsoNormal" style="margin-bottom: 12pt"><span>&#8220;Due to the owner&#8217;s unexpected/untimely death a cat shelter in Pepperell Massachusetts is being closed by the state and 150 cats will have to be put down. The daughter doesn&#8217;t have a license to run the shelter. So in the next week or 2 all these cats will be euthanized. If anyone you know can take one that would be great, but pass this along to anyone just to get it out there. Maybe a friend of a friend of a friend would take one in. It&#8217;s on Sheffield St in Pepperell, 30 min. from Acton. The # is 978-433-0404, Fund for Dogs and Cats.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color: black"></span><span style="overflow: hidden">Get the <a href="http://www.mapquest.com/toolbar?NCID=mpqmap00030000000003" target="_blank" title="http://www.mapquest.com/toolbar?NCID=mpqmap00030000000003">MapQuest Toolbar</a>, Maps, Traffic, Directions &amp; More!&#8221;</span></p>
<p class="MsoNormal">If you can, please adopt a cat! If you know someone who is looking for furry friend, please send this information along.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2-2-2/cat-shelter-in-pepperell-massachusetts-is-being-closed/feed</wfw:commentRss>
		</item>
		<item>
		<title>build readable strings recursively out of a form array in PHP</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/build-readable-strings-recursively-out-of-a-form-array-in-php</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/build-readable-strings-recursively-out-of-a-form-array-in-php#comments</comments>
		<pubDate>Wed, 12 Mar 2008 02:01:46 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/computers-programming/build-readable-strings-recursively-out-of-a-form-array-in-php</guid>
		<description><![CDATA[Here&#8217;s a great way to turn an array into readable strings in PHP.  For example, I want an error notice to be sent to me automatically when a database action in a function fails.  The problem is, I cannot possibly know what is going to be in every form that is used in [...]]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s a great way to turn an array into readable strings in PHP.  For example, I want an error notice to be sent to me automatically when a database action in a function fails.  The problem is, I cannot possibly know what is going to be in every form that is used in the function that generates the database query. While I *can* easily get the keys and values using</p>
<p><code>foreach ($in_array as $key =&gt; $value)</code></p>
<p>and building a string, what if the value itself is an array? The value for any array within the array would be &#8220;Array&#8221;.  Not very useful!</p>
<p>Fortunately, PHP functions can be recursive.  Here&#8217;s a function I wrote to handle that:</p>
<p><code>function getArrayAsString($in_array)<br />
{</code></p>
<blockquote><p><code> $string = '&lt;br /&gt;';<br />
foreach ($in_array as $key =&gt; $value)<br />
{</code></p>
<blockquote><p><code> if (is_array($value)) $string = $string.'&lt;br /&gt;&lt;strong&gt;'.$key.'&lt;/strong&gt;: '.getArrayAsString($value).'&lt;br /&gt;';<br />
else $string = $string.'&lt;strong&gt;'.$key.'&lt;/strong&gt;: '.$value.'&lt;br /&gt;';</code></p></blockquote>
<p><code>}<br />
return $string;</code></p></blockquote>
<p><code>}</code></p>
<p>Each value is checked to see if it is an array. If it is, it (the array value) is sent to this function, and it processes until all of its values have been evaluated, sending any of those array values into this function as well.</p>
<p>I use this function by concatenating the result to an error message by calling the function with the $_POST variable as the array parameter. This way, I have my custom-built message specific to the failed function, and I get all the information that was posted so I can evaluate the error without having to generate the array values one at a time, or worrying if any values are themselves arrays.  <a href="http://www.jennyconnors.com/samples/print-post-form-recursively.php" target="_blank">Click here</a> to fill out a form and see how this recursive function works.</p>
<p>Personally, I like my &#8220;keys&#8221; to be bold and the values to be normal, but you can change that to suit your tastes.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/build-readable-strings-recursively-out-of-a-form-array-in-php/feed</wfw:commentRss>
		</item>
		<item>
		<title>When Insults Had Class (i.e., no 4-letter words)</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/when-insults-had-class-ie-no-4-letter-words</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/when-insults-had-class-ie-no-4-letter-words#comments</comments>
		<pubDate>Sat, 08 Mar 2008 16:15:30 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/the-family/when-insults-had-class-ie-no-4-letter-words</guid>
		<description><![CDATA[My mother-in-law is always complaining about language these days, especially in movies. Vin sent me this (in an email) and I immediately thought of how much she&#8217;d approve of these!
These glorious insults are from an era when cleverness with words was still valued, before a great portion of the English language got boiled down to [...]]]></description>
			<content:encoded><![CDATA[<p>My mother-in-law is always complaining about language these days, especially in movies. Vin sent me this (in an email) and I immediately thought of how much she&#8217;d approve of these!</p>
<p>These glorious insults are from an era when cleverness with words was still valued, before a great portion of the English language got boiled down to 4-letter words.</p>
<p>The exchange between Churchill &amp; Lady Astor: She said, &#8220;If you were my husband I&#8217;d give you poison,&#8221; and he said, &#8220;If you were my wife, I&#8217;d drink it.&#8221;</p>
<p>A member of Parliament to Disraeli: &#8220;Sir, you will either die on the gallows or of some unspeakable disease.&#8221; &#8220;That depends, Sir,&#8221; said Disraeli, &#8220;whether I embrace your policies or your mistress.&#8221;</p>
<p>&#8220;He had delusions of adequacy.&#8221; - Walter Kerr</p>
<p>&#8220;He has all the virtues I dislike and none of the vices I admire.&#8221; - Winston Churchill &#8220;A modest little person, with much to be modest about.&#8221; - Winston Churchill</p>
<p>&#8220;I have never killed a man, but I have read many obituaries with great pleasure.&#8221;? ?  Clarence Darrow</p>
<p>&#8220;He has never been known to use a word that might send a reader to the dictionary.&#8221; - William Faulkner (about Ernest Hemingway).</p>
<p>&#8220;Poor Faulkner. Does he really think big emotions come from big words?&#8221;?  - Ernest Hemingway (about William Faulkner)</p>
<p>&#8220;Thank you for sending me a copy of your book; I&#8217;ll waste no time reading it.&#8221; - Moses Hadas</p>
<p>&#8220;He can compress the most words into the smallest idea of any man I know.&#8221;?  -?  Abraham Lincoln</p>
<p>&#8220;I didn&#8217;t attend the funeral, but I sent a nice letter saying I approved of it.&#8221; - Mark Twain</p>
<p>&#8220;He has no enemies, but is intensely disliked by his friends.&#8221; - Oscar Wilde</p>
<p>&#8220;I am enclosing two tickets to the first night of my new play; bring a friend&#8230;. if you have one.&#8221; - George Bernard Shaw to Winston Churchill</p>
<p>&#8220;Cannot possibly attend first night, will attend second&#8230; if there is one.&#8221; - Winston Churchill, in response.</p>
<p>&#8220;I feel so miserable without you; it&#8217;s almost like having you here.&#8221; - Stephen Bishop</p>
<p>&#8220;He is a self-made man and worships his creator.&#8221; - John Bright</p>
<p>&#8220;I&#8217;ve just learned about his illness. Let&#8217;s hope it&#8217;s nothing trivial.&#8221; - Irvin S. Cobb</p>
<p>&#8220;He is not only dull himself, he is the cause of dullness in others.&#8221; - Samuel Johnson</p>
<p>&#8220;He is simply a shiver looking for a spine to run up.&#8221; - Paul Keating</p>
<p>&#8220;There&#8217;s nothing wrong with you that reincarnation won&#8217;t cure.&#8221; Jack E. Leonard</p>
<p>&#8220;He has the attention span of a lightning bolt.&#8221; - Robert Redford</p>
<p>&#8220;They never open their mouths without subtracting from the sum of human knowledge.&#8221; - Thomas Brackett Reed</p>
<p>&#8220;In order to avoid being called a flirt, she always yielded easily.&#8221; - Charles, Count Talleyrand</p>
<p>&#8220;He loves nature in spite of what it did to him.&#8221; - Forrest Tucker</p>
<p>&#8220;Why do you sit there look ing like an envelope without any address on it?&#8221; - Mark Twain</p>
<p>&#8220;His mother should have thrown him away and kept the stork.&#8221; - Mae West</p>
<p>&#8220;Some cause happiness wherever they go; others, whenever they go.&#8221; - Oscar Wilde</p>
<p>&#8220;He uses statistics as a drunken man uses lamp-posts&#8230; for support rather than illumination.&#8221; - Andrew Lang (1844-1912)</p>
<p>&#8220;He has Van Gogh&#8217;s ear for music.&#8221; - Billy Wilder</p>
<p>&#8220;I&#8217;ve had a perfectly wonderful evening. But this wasn&#8217;t it.&#8221; - Groucho Marx</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/when-insults-had-class-ie-no-4-letter-words/feed</wfw:commentRss>
		</item>
		<item>
		<title>troubleshooting obscure php email issues</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/troubleshooting-obscure-php-email-issues</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/troubleshooting-obscure-php-email-issues#comments</comments>
		<pubDate>Tue, 26 Feb 2008 18:09:50 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/computers-programming/troubleshooting-obscure-php-email-issues</guid>
		<description><![CDATA[One of my current web development/programming projects is being built on a server that I have no access to. It&#8217;s quite challenging, to say the least! One of my issues, and the hardest to resolve, was email.
I use the ordinary mail() PHP function. No classes, no cgi, just the function with HTML headers. But it [...]]]></description>
			<content:encoded><![CDATA[<p>One of my current web development/programming projects is being built on a server that I have no access to. It&#8217;s quite challenging, to say the least! One of my issues, and the hardest to resolve, was email.</p>
<p>I use the ordinary <a href="http://www.php.net/mail" target="_blank">mail() PHP function</a>. No classes, no cgi, just the function with HTML headers. But it seemed that certain emails I sent from the server were going nowhere, and no failure was being reported either.  For example, I could receive mail at my &#8220;theconnorswebsite.com&#8221; domain, but not my &#8220;whitewavedesigns.com&#8221; domain.</p>
<p>Well, first I learned that there was no formal MX record, and my server followed that protocol. One was set up on this particular server, but still, I could not receive email at my wwd domain.</p>
<p>I then tried to specify the smtp server, port and from address:</p>
<p><code>ini_set("smtp","mail.website.com");<br />
ini_set("smtp_port","25");<br />
ini_set("sendmail_from","info@website.com");</code></p>
<p>That didn&#8217;t work either. I also made sure that the server would allow &#8220;from&#8221; emails to be from any domain by substituting various emails at different domains as the &#8220;from&#8221;.  I even double-checked my HTML headers:</p>
<p><code>MIME-Version: 1.0<br />
Content-type: text/html; charset=iso-8859-1<br />
From: Website &lt;info@website.com&gt;</code></p>
<p>Then, one of the programmers who works on this mystery server told me that their MTA (mail transfer agent) was Postfix, and a quirky thing about Postfix on a Linux box was that it would not tolerate the &#8220;\r&#8221; tag when adding additional headers such as &#8220;CC&#8221; or BCC&#8221;.  For example, this is how I was writing my headers:</p>
<p><code>$headers.= "\r\nCC:".$postformAR['Email'];<br />
$headers.= &#8220;\r\nBCC:&#8221;.$postformAR['Webmaster'];</code></p>
<p>(I put the carriage-return/line feed in front of the cc and bcc so it can be optional.) I had heard that Windows servers don&#8217;t especially like the &#8220;\r&#8221; carriage-return tag, but a Linux server?  Well, okay, I removed it.</p>
<p>Then, as if by miracle, some of the emails were coming through! But still not all of them&#8230;  I finally sat down today and line-by-line tried to figure out why some of my code was working and some wasn&#8217;t.  Eventually, I got down to the actual mail() function.</p>
<p>Now, according to php.net, this is the mail() function description:</p>
<p><span class="type">bool</span> <span class="methodname"><strong><strong>mail</strong></strong></span>     ( <span class="methodparam"><span class="type">string</span> <tt class="parameter">$to</tt></span>    , <span class="methodparam"><span class="type">string</span> <tt class="parameter">$subject</tt></span>    , <span class="methodparam"><span class="type">string</span> <tt class="parameter">$message</tt></span>    [, <span class="methodparam"><span class="type">string</span> <tt class="parameter">$additional_headers</tt></span>    [, <span class="methodparam"><span class="type">string</span> <tt class="parameter">$additional_parameters</tt></span>   ]] )</p>
<p>Note the last &#8220;additional_parameters&#8221;.  Sometimes, I use this last parameter &#8220;-finfo@website.com&#8221; for failed messages, bouncebacks, etc.  I don&#8217;t tend to use it when someone submits an email to my site, but I do use it when sending out bulk emails like newsletters. As I found out today, for whatever reason, that last parameter was actually <strong>required</strong>!</p>
<p>So, my fellow programmers, should you ever have email that is sent from your serve simply vanish into cyber-space, I hope this gives you a few more tricks up your sleeve to resolve the issue.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/troubleshooting-obscure-php-email-issues/feed</wfw:commentRss>
		</item>
		<item>
		<title>more reasons to reduce beef consumption</title>
		<link>http://www.jennyconnors.com/-2-2-2-2/41</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2/41#comments</comments>
		<pubDate>Sat, 16 Feb 2008 18:40:50 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/coffee-food-and-drink/41</guid>
		<description><![CDATA[Today, I read an article in the New York Times, and watched the accompanying video, about sick cows made to stand and/or walk so they could be slaughtered, and then eaten.
About a year ago, I lowered my conventional beef intake to once a week.  Now, I have decided that I will only eat naturally-raised [...]]]></description>
			<content:encoded><![CDATA[<p>Today, I <a href="http://theboard.blogs.nytimes.com/2008/02/15/would-you-like-sick-cow-with-those-fries/" target="_blank">read an article in the New York Times</a>, and watched the accompanying video, about sick cows made to stand and/or walk so they could be slaughtered, and then eaten.</p>
<p>About a year ago, I lowered my conventional beef intake to once a week.  Now, I have decided that I will only eat naturally-raised beef once a week.  I don&#8217;t want to be a vegetarian, and I don&#8217;t care for fish (even if I did, we hear so much about over-fishing that I wonder if that&#8217;s a viable option), so I will continue to eat meat.  Beef is (was) the only conventional meat I eat.  No more.</p>
<p>The image of the cow just waiting to die reminded me (literally) of the look on Timone (my deceased Italian Greyhound, my poopsie) when he was extremely ill.  At that point, we knew we had no alternative than to put him down.  How sad (that&#8217;s an understatement) that people could see that cow and not be moved.</p>
<p>What is with the USDA that they could allow this? Honestly, we&#8217;re talking about food that millions of people, including children, eat! Do <em><strong>they </strong></em>eat this stuff? Do <em><strong>they </strong></em>feed it to their children? I am appalled enough about the notion of not labeling genetically modified foods or even meat that may be from cloned animals*, but to allow us to each sick animals is horrendous. At least they closed down this plant. I wish we could close down the USDA! Well, maybe not, but at least get it to do the job it&#8217;s supposed to do.</p>
<p>*To the best of my knowledge, cloned meat is not (yet) used for human consumption. I don&#8217;t know if I&#8217;d want to eat cloned meat, but sure as hell know I&#8217;d want to make that choice myself!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2/41/feed</wfw:commentRss>
		</item>
		<item>
		<title>lol cats</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/lol-cats</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/lol-cats#comments</comments>
		<pubDate>Fri, 18 Jan 2008 18:01:46 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/uncategorized/lol-cats</guid>
		<description><![CDATA[One of my favorite sites is http://icanhascheezburger.com/.  It&#8217;s a fun site with (mainly) cat photos of kitties in various positions and funny captions. My husband and mom-in-law can always tell when I&#8217;m looking at this site (as opposed to getting my work done) because of the way I laugh.
Here&#8217;s a great one!  Do [...]]]></description>
			<content:encoded><![CDATA[<p>One of my favorite sites is <a href="http://icanhascheezburger.com/" target="_blank">http://icanhascheezburger.com/</a>.  It&#8217;s a fun site with (mainly) cat photos of kitties in various positions and funny captions. My husband and mom-in-law can always tell when I&#8217;m looking at this site (as opposed to getting my work done) because of the way I laugh.</p>
<p>Here&#8217;s a great one!  Do you like MythBusters? Who does this look like???</p>
<p><img src="http://icanhascheezburger.files.wordpress.com/2008/01/funny-pictures-mythbuster-cat.jpg" title="LOL" alt="LOL" height="375" width="500" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2/lol-cats/feed</wfw:commentRss>
		</item>
		<item>
		<title>quick way to print an array in php</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/quick-way-to-print-an-array-in-php</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/quick-way-to-print-an-array-in-php#comments</comments>
		<pubDate>Sat, 15 Dec 2007 18:26:15 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/computers/quick-way-to-print-an-array-in-php</guid>
		<description><![CDATA[Printing arrays in PHP can be maddening if you don&#8217;t know the shortcuts! There is always the standard:
foreach ($array as $key =&#62; $value)
{
echo $key.' is key&#60;br&#62;';
echo $value.' is value&#60;br&#62;';
}

but if it&#8217;s not an array (and you have error checking on), you&#8217;ll get an error:
Warning: Invalid argument supplied for foreach() in /home/username/public_html/file.php on line x
And unfortunately, [...]]]></description>
			<content:encoded><![CDATA[<p>Printing arrays in PHP can be maddening if you don&#8217;t know the shortcuts! There is always the standard:</p>
<p><code>foreach ($array as $key =&gt; $value)<br />
{<br />
echo $</code><code>key</code><code>.' is </code><code>key</code><code>&lt;br&gt;';<br />
</code><code>echo $</code><code>value</code><code>.' is </code><code>value</code><code>&lt;br&gt;';</code><br />
<code>}<br />
</code></p>
<p>but if it&#8217;s not an array (and you have error checking on), you&#8217;ll get an error:</p>
<p><code>Warning: Invalid argument supplied for foreach() in /home/username/public_html/file.php on line x</code></p>
<p>And unfortunately, putting the &#8216;@&#8217; in front of the &#8216;foreach&#8217; only yields another error:</p>
<p><code>Parse error:  syntax error, unexpected T_FOREACH in /home/username/public_html/file.php on line x</code></p>
<p>Of course, you could do a check to see if it *is* an array, but that&#8217;s more lines of code, and we want it <em>quick</em>.</p>
<p>Here&#8217;s a clever way to get what I call in my Dreamweaver snippets panel a &#8220;quick print of array&#8221;:</p>
<p><code>print '&lt;pre&gt;'; print_r($_POST); print '&lt;/pre&gt;';</code></p>
<p>Here&#8217;s what it will look like:</p>
<p><code>Array<br />
(<br />
[asso_key_name_1] =&gt; value 1<br />
[asso_key_name_2] =&gt; value 2<br />
)</code></p>
<p>That&#8217;s great, but suppose you have several arrays on one page you want to print the results for, how can you keep them apart?  Simple! Put the name of the array after the first &lt;pre&gt; tag, like this:</p>
<p><code>print '&lt;pre&gt;_POST '; print_r($_POST); print '&lt;/pre&gt;';</code></p>
<p>The results will be like this:</p>
<p><code>_POST Array<br />
(<br />
[asso_key_name_1] =&gt; value 1<br />
[asso_key_name_2] =&gt; value 2<br />
)</code></p>
<p>You can use this quick printing of arrays to print POST vars, SESSION vars, recordsets, any kind of PHP array!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/quick-way-to-print-an-array-in-php/feed</wfw:commentRss>
		</item>
		<item>
		<title>my sunday</title>
		<link>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/my-sunday</link>
		<comments>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/my-sunday#comments</comments>
		<pubDate>Sun, 28 Oct 2007 18:26:29 +0000</pubDate>
		<dc:creator>jenny</dc:creator>
		
		<category><![CDATA[]]></category>

		<guid isPermaLink="false">http://www.jennyconnors.com/computers/my-sunday</guid>
		<description><![CDATA[Working like mad &#8230; under several deadlines &#8230; must practice oboe, clarinet, tenor solos &#8230; must put away laundry &#8230; must make cookies &#8230; must make pumpkin seeds &#8230; and this sums up how my day is going:
http://www.irregularwebcomic.net/1736.html
I suppose it&#8217;s good news that it&#8217;s been more like 2 hours than 2 days, but still&#8230;
]]></description>
			<content:encoded><![CDATA[<p>Working like mad &#8230; under several deadlines &#8230; must practice oboe, clarinet, tenor solos &#8230; must put away laundry &#8230; must make cookies &#8230; must make pumpkin seeds &#8230; and this sums up how my day is going:</p>
<p><a href="http://www.irregularwebcomic.net/1736.html" target="_blank">http://www.irregularwebcomic.net/1736.html</a></p>
<p>I suppose it&#8217;s good news that it&#8217;s been more like 2 hours than 2 days, but still&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.jennyconnors.com/-2-2-2-2-2-2-2-2-2-2/my-sunday/feed</wfw:commentRss>
		</item>
	</channel>
</rss>
