1 <?xml version="1.0" encoding="utf-8" ?>
4 xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
5 xmlns:admin="http://webns.net/mvcb/"
6 xmlns:dc="http://purl.org/dc/elements/1.1/"
7 xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
8 xmlns:wfw="http://wellformedweb.org/CommentAPI/"
9 xmlns:content="http://purl.org/rss/1.0/modules/content/"
12 <title><?paul</title>
13 <link>http://blog.preinheimer.com/</link>
14 <description>Paul Reinheimer</description>
15 <dc:language>en</dc:language>
16 <generator>Serendipity 1.2 - http://www.s9y.org/</generator>
17 <pubDate>Mon, 21 Jul 2008 21:37:01 GMT</pubDate>
20 <url>http://blog.preinheimer.com/templates/default/img/s9y_banner_small.png</url>
21 <title>RSS: <?paul - Paul Reinheimer</title>
22 <link>http://blog.preinheimer.com/</link>
28 <title>Climbing</title>
29 <link>http://blog.preinheimer.com/index.php?/archives/272-Climbing.html</link>
31 <comments>http://blog.preinheimer.com/index.php?/archives/272-Climbing.html#comments</comments>
32 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=272</wfw:comment>
34 <slash:comments>0</slash:comments>
35 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=272</wfw:commentRss>
38 <author>nospam@example.com (Paul Reinheimer)</author>
40 I climbed recently at Val-David, and had a rather interesting time. The climbs weren't particularly hard, just... different. Most of them were "slab" I think. Where the rock isn't straight up, but actually leans in, which makes it easier, which is cool. The problem was a near complete lack of handholds. <br />
\r
42 I think the climbs were really good for me from a technical prospective. I (and apparently most men) use a lot of upper body strength when climbing. Now while I'm actually not that strong, it's not uncommon to see me hanging off one or both hands while my feet do something rather silly that generally works out in the end. Another favourite is pulling with a hand and pushing with my feet to jump up and grab something higher. This works, but it can only get me so far.<br />
\r
44 Rock climbing shoes are curiously good at gripping things, putting all your weight on a small rock sticking out less than a centimeter is pretty common. So once I actually started trusting my feet to carry all my weight, things went pretty well. I'd like to try a few slabs at allez-up next time, and restrict myself from using any hand holds while I'm on them. <br />
\r
47 I've also discovered my new favorite formation, the crack. Easier than stairs!<br />
\r
51 Note to my PHP friends: I had zero posts for a long time, so I've gone with some personal posts to get back in the swing of things, I should get back into PHP posts soon.
54 <pubDate>Mon, 21 Jul 2008 17:37:01 -0400</pubDate>
55 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/272-guid.html</guid>
59 <title>Cycling</title>
60 <link>http://blog.preinheimer.com/index.php?/archives/271-Cycling.html</link>
62 <comments>http://blog.preinheimer.com/index.php?/archives/271-Cycling.html#comments</comments>
63 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=271</wfw:comment>
65 <slash:comments>2</slash:comments>
66 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=271</wfw:commentRss>
69 <author>nospam@example.com (Paul Reinheimer)</author>
71 So I've been biking for a while, and I'm really starting to enjoy it. As I mentioned before I aim to rock climb, cycle, or hit the weights at the gym every day so I generally bike about three times a week. I went biking with a friend earlier this week and he contrasted our cycling styles. <br />
\r
73 Apparently, I bike like I'm a car, while he cycles like he's a pedestrian (apparently my methodology requires a bit more guts). While when biking down the road I'll stick to the right, but I'm more than willing to take the left lane when I'm turning (there's something empowering about towering over almost every car on the road), even on some of Montreal's busier roads. I also signal my turns, and stop for red lights. My friend on the other hand relentlessly sticks to the right, crosses roads with pedestrian lights rather than the big turn, and runs lights like any true Montreal pedestrian would.<br />
\r
75 As a small disclaimer, I also wear a helmet, have a blinking LED tail light, appropriate headlight and all required reflectors. <br />
\r
77 On a side note, I found a bigger hill. <a href="http://www.screencast.com/users/preinheimer/folders/Jing/media/8c3c649d-6bfb-449a-bf9f-464205b10ee4">54.8km/h</a>, I could have gone much faster but there's always a street light at the bottom of these things, and the roads here are horrible. I find I actually peak well after the bottom of the hill (after I've passed the street light).
80 <pubDate>Fri, 11 Jul 2008 23:38:58 -0400</pubDate>
81 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/271-guid.html</guid>
85 <title>Getting in Shape</title>
86 <link>http://blog.preinheimer.com/index.php?/archives/270-Getting-in-Shape.html</link>
88 <comments>http://blog.preinheimer.com/index.php?/archives/270-Getting-in-Shape.html#comments</comments>
89 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=270</wfw:comment>
91 <slash:comments>6</slash:comments>
92 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=270</wfw:commentRss>
95 <author>nospam@example.com (Paul Reinheimer)</author>
97 So, I've decided this is the summer that I finally get into shape. Apart from not being happy with my current weight, getting out will also allow me to meet more people in Montreal which can only be a good thing. <br />
\r
99 I've come up with three key activities, and my goal is to do one every day. I don't always make it, but I've had some good stretches. The activities are: rock climbing, cycling (currently 12k, planning on upping this a bit once I find a better half way point), and weights at the gym. <br />
\r
101 Rock Climbing: A friend introduced me to this a few months ago, and apart from a rather difficult first experience I quite enjoy it. There's a couple local climbing gyms, as well as a great group of people who go out doors every week or two. Thanks to some great help and instruction I'm now gaining confidence on 5.7s (<a href="http://www.climber.org/data/decimal.html">Yosemite Decimal System</a>). I usually climb at <a href="http://www.allezup.com/">Allez Up</a> but tried <a href="http://www.horizonroc.com/">Horizen Roc</a> this past weekend. I can't wait until I'm good enough to take a lead climbing class. Also, there's a trapeze class at Horizen Roc <img src="http://blog.preinheimer.com/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" />. <br />
\r
103 Cycling: I've loved riding a bike forever, and it seems to satisfy a need to spend time doing <strong>something</strong> thoughtless while being outdoors that's been left empty since I didn't have a dog to take for a walk. I bought a bike a while back, and have started biking to a distant grocery store for a bottle of water and an apple, then back. I've already had several minor repairs to my bike as a result of Montreal's crappy roads. I average 24Km/h, and my max speed so far is 47Km/h. <br />
\r
105 Gym: I joined the YMCA a while back with a friend. The downtown YMCA here has two gyms, the regular one on the third floor (that's huge, and quite busy), and a "technogym" on the second floor that's small, doesn't have the nice big windows, and is usually almost dead. They've got this great program where included in your membership every 6 weeks you can have a meeting (~1hr) with a personal trainer to work on setting up a program, your goals etc. They will also teach you how to use the machines (critical for me). In the techno-gym, it goes one step further where your work out program is encoded into a smart key, all the machines take the key, they then: set the appropriate weight/resistance, #repetitions, #sets, seat height and other adjustments, plus it records your work out. I like this option, as it basically lets me shut my brain down for an hour while I work out. Thanks to the computerized machines, I get handy little reports, so for example: during my first workout I lifted a total of 7,945Kg (that total could be obtained by lifting a 1Kg weight 7954 times, or some more sensible combination of more weight on different muscles), I'm now past 10,500Kg. <br />
\r
108 I'm pretty sure I've got some new muscles where there was none before, though you'd have to be quite familiar with my body in order to notice... So if you've noticed please stop stalking me. <br />
\r
112 <pubDate>Mon, 30 Jun 2008 22:55:09 -0400</pubDate>
113 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/270-guid.html</guid>
117 <title>Selling stuff to the pawn shop</title>
118 <link>http://blog.preinheimer.com/index.php?/archives/269-Selling-stuff-to-the-pawn-shop.html</link>
120 <comments>http://blog.preinheimer.com/index.php?/archives/269-Selling-stuff-to-the-pawn-shop.html#comments</comments>
121 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=269</wfw:comment>
123 <slash:comments>0</slash:comments>
124 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=269</wfw:commentRss>
127 <author>nospam@example.com (Paul Reinheimer)</author>
129 Well, my apartment is a mess. I'm single, and don't have a roommate, so there's been little incentive to clean. However, I'd rather not live in a pig sty forever, so it was time to clean. I like fancy new technology, so I've got a bunch kicking around that I don't use anymore. Parting with junk is tough, but it's way easier if you can get money for it, it seems easier. Plus, you get money. So I took my <a href="http://blog.preinheimer.com/index.php?/archives/239-The-Look-and-Sound-of-Perfect.html">aforementioned</a> (but unplayed for the past year) PSP to the pawn shop to sell it (once I did one last game for memories sake).<br />
\r
131 Running a pawn shop has to suck, apart from needing to take down details on everyone they buy from, they need to hold onto everything they buy for 30 days before they can sell it again. So they pay first, then can sell again after a month. This is reverse of a lot of retailers who manage to get products, then pay for them later!
134 <pubDate>Sun, 27 Apr 2008 01:56:25 -0400</pubDate>
135 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/269-guid.html</guid>
139 <title>Open Web Vancouver</title>
140 <link>http://blog.preinheimer.com/index.php?/archives/268-Open-Web-Vancouver.html</link>
142 <comments>http://blog.preinheimer.com/index.php?/archives/268-Open-Web-Vancouver.html#comments</comments>
143 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=268</wfw:comment>
145 <slash:comments>0</slash:comments>
146 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=268</wfw:commentRss>
149 <author>nospam@example.com (Paul Reinheimer)</author>
151 I (despite Air Canada's best efforts) have arrived safely in Vancouver in preperation for <a href="http://www.openwebvancouver.ca/">Open Web Vancouver</a>. I'll be doing a new talk on State and History in Ajax. I'll be leveraging the <a href="http://developer.yahoo.com/yui/">YUI</a> throughout the talk. Registration is still open for the conference so if you're in the area come on by, tickets are a steal at only $150!<br />
\r
153 I'd also like to thank <a href="http://phparchitect.com">php|architect</a> for sponsoring my attendance once again this year.
156 <pubDate>Fri, 11 Apr 2008 13:40:21 -0400</pubDate>
157 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/268-guid.html</guid>
161 <title>PDO Week!</title>
162 <link>http://blog.preinheimer.com/index.php?/archives/267-PDO-Week!.html</link>
163 <category>PHP</category>
165 <comments>http://blog.preinheimer.com/index.php?/archives/267-PDO-Week!.html#comments</comments>
166 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=267</wfw:comment>
168 <slash:comments>4</slash:comments>
169 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=267</wfw:commentRss>
172 <author>nospam@example.com (Paul Reinheimer)</author>
174 So we're half way into PDO week at <a href="http://funcaday.com/" title="PHP Function a Day">funcaday</a>. I've wanted to do theme weeks since the beginning, a few emails prompted me to take a look at PDO for this first theme week, and now that i've gotten i started I'm quite enjoying it. If you've got any suggestions for future weeks let me know.<br />
\r
178 <pubDate>Wed, 05 Mar 2008 00:25:00 -0500</pubDate>
179 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/267-guid.html</guid>
183 <title>I miss Zend Studio</title>
184 <link>http://blog.preinheimer.com/index.php?/archives/266-I-miss-Zend-Studio.html</link>
185 <category>PHP</category>
187 <comments>http://blog.preinheimer.com/index.php?/archives/266-I-miss-Zend-Studio.html#comments</comments>
188 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=266</wfw:comment>
190 <slash:comments>4</slash:comments>
191 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=266</wfw:commentRss>
194 <author>nospam@example.com (Paul Reinheimer)</author>
196 So I dual develop, I flip back and forth between Active State's <a href="http://activestate.com/Products/komodo_ide/">Komodo</a>, and Zend's <a href="http://www.zend.com/products/studio/studio55">Zend Studio</a> (the first generation). One of my favourite features of Zend Studio is the Code Analyzer, it basically reads through your code and tells you about all your bugs. No, I'm not talking about syntax errors, I'm talking about using variables before they were defined, an assignment in condition, variables only being used once, functions returning something sometimes and nothing other times. It helps you find those tiny annoying bugs that take you hours to find normally in less than a second. Anyways, it's great, it's something I flip over for.<br />
\r
198 I miss it because it wont register...
201 <pubDate>Tue, 04 Mar 2008 00:20:19 -0500</pubDate>
202 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/266-guid.html</guid>
206 <title>Contest</title>
207 <link>http://blog.preinheimer.com/index.php?/archives/265-Contest.html</link>
208 <category>PHP</category>
210 <comments>http://blog.preinheimer.com/index.php?/archives/265-Contest.html#comments</comments>
211 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=265</wfw:comment>
213 <slash:comments>6</slash:comments>
214 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=265</wfw:commentRss>
217 <author>nospam@example.com (Paul Reinheimer)</author>
219 Hey all, if you like PHP and are looking for some fun stuff to just experiment with, why not try one of our contests? php|architect is launching regular PHP Programming contests, so take a look at our first running, <a href="http://c7y-bb.phparchitect.com/viewtopic.php?f=2&t=1108">a link parser</a><br />
\r
221 Also, take a look at some of our new free great articles up at <a href="http://c7y.phparch.com/c/tag/ART">C7Y</a>.
224 <pubDate>Sat, 23 Feb 2008 11:14:19 -0500</pubDate>
225 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/265-guid.html</guid>
229 <title>Happy Valentines Day - The funcaday way</title>
230 <link>http://blog.preinheimer.com/index.php?/archives/264-Happy-Valentines-Day-The-funcaday-way.html</link>
231 <category>PHP</category>
233 <comments>http://blog.preinheimer.com/index.php?/archives/264-Happy-Valentines-Day-The-funcaday-way.html#comments</comments>
234 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=264</wfw:comment>
236 <slash:comments>0</slash:comments>
237 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=264</wfw:commentRss>
240 <author>nospam@example.com (Paul Reinheimer)</author>
242 I trust you've seen today's <a href="http://funcaday.com/">funcaday</a>, if not head over and look now. Want a custom one to share with someone you care about. Fill out the form <a href="http://funcaday.com/form.php">here</a>. It's a subtle effect though, they'll need to read it. <br />
\r
244 Valid characters for names are just alphabetics and the underscore, sorry. <br />
\r
246 You could also buy advertising, I'd like to eat this month.<br />
\r
250 <pubDate>Thu, 14 Feb 2008 00:01:00 -0500</pubDate>
251 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/264-guid.html</guid>
255 <title>Today's Funcaday</title>
256 <link>http://blog.preinheimer.com/index.php?/archives/263-Todays-Funcaday.html</link>
257 <category>PHP</category>
259 <comments>http://blog.preinheimer.com/index.php?/archives/263-Todays-Funcaday.html#comments</comments>
260 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=263</wfw:comment>
262 <slash:comments>9</slash:comments>
263 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=263</wfw:commentRss>
266 <author>nospam@example.com (Paul Reinheimer)</author>
268 I'm really restricted on space, so I wanted to present a counter point on today's <a href="http://funcaday.com/">funcaday</a>: Performance.<br />
\r
270 The disadvantage with the escape for now, not for later approach is simple. If you save a user's post to the database, then that user's post is displayed 2,000 times there will be some serious differences. Under the approach I reccomend the post will be escaped with mysql_real_escape_string() once, and with htmlentiteis() 2,000 times. If you had escaped it twice in the first place those functions would have been called once each, saving you 1,999 calls to htmlentities.<br />
\r
272 You will need to balance your security concerns with performance needs. <br />
\r
275 Note: This blog post was written well in advance, I'm on vacation, don't have my laptop or internet, and it's likely that my cell phone won't even turn on. So replies may be a bit tardy. <br />
\r
277 Note^2: But I'm not dumb, someone's looking after my server <img src="http://blog.preinheimer.com/templates/default/img/emoticons/smile.png" alt=":-)" style="display: inline; vertical-align: bottom;" class="emoticon" /><br />
\r
282 <pubDate>Sat, 05 Jan 2008 01:21:00 -0500</pubDate>
283 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/263-guid.html</guid>
287 <title>Merry Christmas</title>
288 <link>http://blog.preinheimer.com/index.php?/archives/262-Merry-Christmas.html</link>
290 <comments>http://blog.preinheimer.com/index.php?/archives/262-Merry-Christmas.html#comments</comments>
291 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=262</wfw:comment>
293 <slash:comments>2</slash:comments>
294 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=262</wfw:commentRss>
297 <author>nospam@example.com (Paul Reinheimer)</author>
299 <!-- s9ymdb:3 --><img width="800" height="536" style="float: right; border: 0px; padding-left: 5px; padding-right: 5px;" src="http://blog.preinheimer.com/uploads/Christmas-Eau-Claire.jpg" alt="" /><br />
\r
301 Talk to you in the new year.
304 <pubDate>Tue, 25 Dec 2007 00:08:11 -0500</pubDate>
305 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/262-guid.html</guid>
309 <title>Photoshop - Working with different pixel ratios</title>
310 <link>http://blog.preinheimer.com/index.php?/archives/261-Photoshop-Working-with-different-pixel-ratios.html</link>
312 <comments>http://blog.preinheimer.com/index.php?/archives/261-Photoshop-Working-with-different-pixel-ratios.html#comments</comments>
313 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=261</wfw:comment>
315 <slash:comments>1</slash:comments>
316 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=261</wfw:commentRss>
319 <author>nospam@example.com (Paul Reinheimer)</author>
321 My grandparents are getting a digital photo frame for Christmas, they don't own a computer so the cat's not out of the bag. This digital frame has a stated resolution that's way off what you're looking at, the frame is like 16:9, but the pixel is... something else. I had a hard time working in Photoshop trying to prep the images for the system, since the pixels aren't square, they're rectangles, what looked good here looked like crap over there, etc. Then I found the pixel aspect ratio option under Image, created my own aspect ratio (using a ruler, and the pixel counts) and voila, I could now draw squares in photoshop that were square within the frame. <br />
\r
323 I still had a problem, when I converted existing images over to the new ratio, they got squished, it showed me a preview (which is all it really does), but didn't resample the image to look right under the new ratio. The solution is pretty easy, open up image size, turn off constrain properties then divide the width by the pixel aspect ratio and apply. Your image is now stretched. Then apply the pixel aspect ratio, and it should look normal.
326 <pubDate>Tue, 18 Dec 2007 15:46:51 -0500</pubDate>
327 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/261-guid.html</guid>
331 <title>Get it Right or Get it Up.</title>
332 <link>http://blog.preinheimer.com/index.php?/archives/260-Get-it-Right-or-Get-it-Up..html</link>
333 <category>PHP</category>
335 <comments>http://blog.preinheimer.com/index.php?/archives/260-Get-it-Right-or-Get-it-Up..html#comments</comments>
336 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=260</wfw:comment>
338 <slash:comments>4</slash:comments>
339 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=260</wfw:commentRss>
342 <author>nospam@example.com (Paul Reinheimer)</author>
344 When working on any web development project, you have two central choices, Get it Right, or Get it Up. While the same choices dominate development as a whole, the low cost, high speed, and largely transparent nature of updates on the web make getting it up more tempting. <br />
\r
346 Getting it Right is what most developers strive for: clean code, easy to read, easy to use, easy to refractor. It's great, but it's not fast. I would even go as far to say that it's relatively easy to estimate how long it will take to develop something, but very difficult to estimate how long it will take to develop something "right". <br />
\r
348 Getting it Up (pun unintentional) is when you release just as soon as things work (mostly). You get the code working in some manner that vaguely represents what you're actually hoping for, push it live, then fix things as they break, add new features as they're required. It's faster, but you don't get to have that grand release party as soon as the application goes live, as you're probably madly mashing the keyboard trying to fix all the bugs that your users are finding. <br />
\r
350 (more after the jump) <br /><a href="http://blog.preinheimer.com/index.php?/archives/260-Get-it-Right-or-Get-it-Up..html#extended">Continue reading "Get it Right or Get it Up."</a>
353 <pubDate>Sun, 16 Dec 2007 16:55:58 -0500</pubDate>
354 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/260-guid.html</guid>
358 <title>Resources are "special"</title>
359 <link>http://blog.preinheimer.com/index.php?/archives/259-Resources-are-special.html</link>
360 <category>PHP</category>
362 <comments>http://blog.preinheimer.com/index.php?/archives/259-Resources-are-special.html#comments</comments>
363 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=259</wfw:comment>
365 <slash:comments>2</slash:comments>
366 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=259</wfw:commentRss>
369 <author>nospam@example.com (Paul Reinheimer)</author>
371 Working on <a href="http://funcaday.com">funcaday</a> I've spent a lot of time dealing with variables of the type resource in the past few weeks, after all GD images are held in variables of that type. I ran into some "functionality" of resources late last night that I initially chalked up to a bug, a variable of type resource went from being a resource of type GD to unknown while merely getting returned back a few steps. After some experimentation (and the inevitable epiphany while brushing my teeth) I've figured it out, and there's no bug. <br />
\r
373 Here's a longish snippet explaining what I was encountering:<br />
\r
374 <blockquote>class imageTest {<br />
\r
375 private $image;<br />
\r
376 public function __construct() {<br />
\r
377 $this->image = imagecreatetruecolor(2,2);<br />
\r
379 public function getImage() {<br />
\r
380 var_dump($this->image);<br />
\r
381 return array($this->image);<br />
\r
383 public function __destruct() {<br />
\r
384 imagedestroy($this->image);<br />
\r
387 function test() {<br />
\r
388 $x = new imageTest();<br />
\r
389 $image = $x->getImage();<br />
\r
390 var_dump($image);<br />
\r
391 return $image;<br />
\r
394 $image = test();<br />
\r
395 var_dump($image);<br />
\r
396 </blockquote><br />
\r
398 Which returns something like:<br />
\r
399 <blockquote>resource(3, gd)<br />
\r
400 resource(3, gd)<br />
\r
401 resource(3, Unknown)<br />
\r
402 </blockquote><br />
\r
403 (more after the jump)<br />
\r
404 <br /><a href="http://blog.preinheimer.com/index.php?/archives/259-Resources-are-special.html#extended">Continue reading "Resources are &quot;special&quot;"</a>
407 <pubDate>Sat, 15 Dec 2007 19:08:52 -0500</pubDate>
408 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/259-guid.html</guid>
412 <title>funcaday</title>
413 <link>http://blog.preinheimer.com/index.php?/archives/258-funcaday.html</link>
414 <category>PHP</category>
416 <comments>http://blog.preinheimer.com/index.php?/archives/258-funcaday.html#comments</comments>
417 <wfw:comment>http://blog.preinheimer.com/wfwcomment.php?cid=258</wfw:comment>
419 <slash:comments>1</slash:comments>
420 <wfw:commentRss>http://blog.preinheimer.com/rss.php?version=2.0&type=comments&cid=258</wfw:commentRss>
423 <author>nospam@example.com (Paul Reinheimer)</author>
425 Sorry to everyone for the issues this evening, non-feed based users of the site should have seen everything up and working perfectly by 12:05am EST, while feed users needed to wait until almost 1:00am EST<br />
\r
426 1) Today's post posed a few issues, namely, it's the first weekend based post we've had so it's running through a different image creation path. <br />
\r
427 2) Since there's only one image for two days over the weekend, there's a whole bunch of code in various places to handle that. <br />
\r
429 The Real Issue:<br />
\r
430 I think I've found a bug in PHP. I didn't have time to develop a base case to prove it this evening (while the clock struck down towards midnight) but it seems as though resources can get mangled when being returned a few levels.<br />
\r
431 <blockquote><br />
\r
432 Generating Weekday!<br />
\r
433 resource(532) of type (gd)<br />
\r
434 resource(532) of type (Unknown)<br />
\r
435 </blockquote><br />
\r
438 If you're interested in presenting funcaday to anyone through a project of your own, I'd reccomend taking a look at the json feed. Either <a href="http://funcaday.com/json.xml">json.xml</a>, or <a href="http://funcaday.com/funcaday.json">funcaday.json</a>. The information is identical in those two files, the difference is really just the extension, Technically if you're using JS the XHR object wants a text/html content type, so I provide the .xml version to get Apache to give you that header, if you're using anything else, go for the .json. Let me know if there's anything else you'd like to see in there. <br />
\r
440 One question for the mindful readers, in the RSS code I have:<br />
\r
441 <blockquote><br />
\r
442 file_put_contents('/path/funcaday.com/rss.xml.temp', $rss);<br />
\r
443 rename('/path/funcaday.com/rss.xml.temp', '/path/funcaday.com/rss.xml');<br />
\r
444 </blockquote><br />
\r
445 Can anyone tell me why I would add the extra step? Do I actually need to do this, or is this just me following outdated practices? <br />
\r
449 There's aparently a <a href="http://funcaday.blip.tv">video version</a> of funcaday by an anonymous... fan?
452 <pubDate>Sat, 15 Dec 2007 01:03:59 -0500</pubDate>
453 <guid isPermaLink="false">http://blog.preinheimer.com/index.php?/archives/258-guid.html</guid>