/usr/share/php/tests/Horde_Feed/Horde/Feed/fixtures/lexicon/http-blog.phpdeveloper.org-%2Ffeed=rss2 is in php-horde-feed 2.0.1-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 | <?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>blog.phpdeveloper.org</title>
<atom:link href="http://blog.phpdeveloper.org/?feed=rss2" rel="self" type="application/rss+xml" />
<link>http://blog.phpdeveloper.org</link>
<description>The Official Blog of PHPDeveloper.org</description>
<pubDate>Wed, 25 Jun 2008 02:22:07 +0000</pubDate>
<generator>http://wordpress.org/?v=2.5.1</generator>
<language>en</language>
<item>
<title>Ivo Jansch’s “Guide to Enterprise PHP Development”</title>
<link>http://blog.phpdeveloper.org/?p=105</link>
<comments>http://blog.phpdeveloper.org/?p=105#comments</comments>
<pubDate>Wed, 25 Jun 2008 02:21:20 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Book Review]]></category>
<category><![CDATA[PHP]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=105</guid>
<description><![CDATA[I’ve been working through this book for the past few days and let me just say from the get-go, this book would be any asset to pretty much anyone on the PHP development food chain. It’s not a book for programmers telling you how to survive in an enterprise environment (there’s some of that, but [...]]]></description>
<content:encoded><![CDATA[<p>I’ve been working through <a href="http://phparch.com/c/books/id/9780973862188">this book</a> for the past few days and let me just say from the get-go, this book would be any asset to pretty much anyone on the PHP development food chain. It’s not a book for programmers telling you how to survive in an enterprise environment (there’s some of that, but that’s not the focus). <a href="http://phparch.com/c/books/id/9780973862188">The book</a> gives the reader one of the most valuable things anyone in a corporate environment can have - how it all works. It might not be 100% the same as things around your office, but Ivo does a great job of giving everyone involved in the development of web apps (and it doesn’t have to be PHP!) a better idea of how all the pieces fit together.</p>
<p>The flow of the book follows a typical project flow with topics like:
<ul>
<li>Gathering requirements
</li>
<li>the Planning stages
</li>
<li>which of your Building Blocks you’ll need to get the job done
</li>
<li>Developing the application
</li>
<li>Pushing it out to the public and keeping it maintained for its users
</li>
</ul>
<p>For each, there’s lots of great tips crammed in with suggestions and recommendations based on some of his previous experiences.</p>
<p>There’s little to no code in the book, so don’t buy it expecting tutorials on writing code in an enterprise environment. What you will find here, though, is a better idea of where that code you’re writing will fit in the bigger picture.</p>
<p>Let me also reinforce that this book is not just for developers. Honestly, anyone involved with the creation of web-based applications can benefit from it. Managers, developers and testers will all find bits in here that they can pick up and hang on to for current and future projects.</p>
<p>I also like that he included the part there at the end about the different development methodologies. It’s a nice addition that can help open up the reader/developer’s eyes to new ways of doing things (Agile is especially fun).</p>
<p>I’d definitely recommend that you pick up this book if you’re going to be doing development in anything more than a one man shop. Actually, strike that - I’d recommend it for anyone that wants to get more familiar with the management side of development and how their code works in.</p>
<p>More information: <a href="http://phparch.com/c/books/id/9780973862188">php|architect’s Guide to Enterprise PHP Development</a></p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=105</wfw:commentRss>
</item>
<item>
<title>Subdomain Setup with Solar</title>
<link>http://blog.phpdeveloper.org/?p=104</link>
<comments>http://blog.phpdeveloper.org/?p=104#comments</comments>
<pubDate>Sat, 21 Jun 2008 11:38:12 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[PHP]]></category>
<category><![CDATA[Solar]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=104</guid>
<description><![CDATA[So here was my situation - I wanted to have a subdomain off of my main site, but I didn't want to have to create a whole new docroot with an entire new Solar framework application in it. Besides being "yet another install" of the same sort of thing, it would also be a pain [...]]]></description>
<content:encoded><![CDATA[<p>So here was my situation - I wanted to have a subdomain off of my main site, but I didn't want to have to create a whole new docroot with an entire new <a href="http://solarphp.com">Solar framework</a> application in it. Besides being "yet another install" of the same sort of thing, it would also be a pain to keep up more than one codebase that does a lot of the same things.</p>
<p>This got me to thinking that there had to be a way to convince Solar that it could use the same code with the subdomain without issue. Sure enough, it could - and it was actually really easy. Here's my situation:</p>
<p>I wanted to have the main domain's stuff still work (www.mydomain.com) just like it always has but I wanted the subdomain to point to one controller out of the main application (in this case, the Solar_App_Foo controller) when the subdomain was called (foo.mydomain.com). Solar makes it dead simple - it's just a change in your config file.</p>
<p>Since it's PHP driven, you can do fun things like checking to see what the value of $_SERVER['HTTP_HOST'] is right there in the definition:</p>
<div class="igBar"><span id="lcode-2"><a href="#" onclick="javascript:showPlainTxt('code-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-2">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$act=<span style="color:#006600; font-weight:bold;">(</span>$_SERVER<span style="color:#006600; font-weight:bold;">[</span><span style="color:#CC0000;">'HTTP_HOST'</span><span style="color:#006600; font-weight:bold;">]</span>==<span style="color:#CC0000;">'foo.mydomain.com'</span><span style="color:#006600; font-weight:bold;">)</span> ? <span style="color:#CC0000;">'foo'</span> : <span style="color:#CC0000;">'index'</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$config<span style="color:#006600; font-weight:bold;">[</span><span style="color:#CC0000;">'Solar_Controller_Front'</span><span style="color:#006600; font-weight:bold;">]</span><span style="color:#006600; font-weight:bold;">[</span><span style="color:#CC0000;">'default'</span><span style="color:#006600; font-weight:bold;">]</span>=$act </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>That's all there is to it - the ternary check looks for the subdomain and sets the default controller to our Solar_App_Foo instead of the Index the rest of the site calls. And, since it's just part of the same site, all of the links and other functionality work just fine. Plus no extra code to maintain!</p>
<p>Hope this helps to anyone else out there trying to work with subdomains with <a href="http://www.solarphp.com">Solar</a>. Thanks to the crew in #solarphp on <a href="http://www.freenode.net">Freenode</a> for the help!</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=104</wfw:commentRss>
</item>
<item>
<title>Enterprise PHP (the Magazine)</title>
<link>http://blog.phpdeveloper.org/?p=102</link>
<comments>http://blog.phpdeveloper.org/?p=102#comments</comments>
<pubDate>Sun, 01 Jun 2008 18:53:21 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Community]]></category>
<category><![CDATA[PHP]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=102</guid>
<description><![CDATA[Opening my mailbox yesterday welcomed me with a brown paper envelope addresses to "Herr Cornutt" and postmarked. I was confused since I wasn't expecting any bit of German to be coming my way. I was happily surprised, though, when I opened it to find the free issue of Enterprise PHP, one of the newest offerings [...]]]></description>
<content:encoded><![CDATA[<p>Opening my mailbox yesterday welcomed me with a brown paper envelope addresses to "Herr Cornutt" and postmarked. I was confused since I wasn't expecting any bit of German to be coming my way. I was happily surprised, though, when I opened it to find the free issue of <a href="http://it-republik.de/php/enterprisephp/index.php?lang=en">Enterprise PHP</a>, one of the newest offerings into the PHP magazine category.</p>
<p>The publication is from the <a href="http://it-republik.de/">IT Republik</a> folks and is a nice looking magazine. It comes in at about 50 pages but it has a good ad to story ratio so you don't feel slighted. Stories include:</p>
<ul>
<li>Test 'em all! (by Sebastian Bergmann)
</li>
<li>Worlds apart... (by Patrick Lobacher covering PHP intagration and SAP systems)
</li>
<li>an interview with Jens Paul Berndt about decisions regarding PHP
</li>
<li>a case study of the Fiat Group SpA's use of PHP in their systems
</li>
<li>and the cover story, "Java is not PHP"
</li>
</ul>
<p>The quality of the articles if good - it's interesting to see their use of so much clip art as illustrations. I suppose its due to the different audience than some of the other <a href="http://www.phparch.com">magazines</a>. It's less about the development and more about the high-level thoughts and processes behind PHP in business - how it can function in their corporation (or small business!) and what sorts of considerations need to be made. The articles are good quality and keep consistent with the tone of the magazine. The quality of the printing is nice too (always a plus) and the thicker pages make the "enterpriseness" of it all feel even better. </p>
<p>Oh, and let's not forget about two articles by Cal Evans of the <a href="http://devzone.zend.com">Zend Developer Zone</a>! One covers several of the popular PHP frameworks and the other about how PHP security has advanced in the past few years.</p>
<p>If you get a chance and want to check out something a bit different in PHP Magazines, head over and <a href="http://it-republik.de/php/enterprisephp/index.php?lang=en">grab a trial issue</a> of this newest addition to the PHP publication world. Here's hoping we'll see great things from them!</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=102</wfw:commentRss>
</item>
<item>
<title>Simple Content Management (with Templates & Permissions)</title>
<link>http://blog.phpdeveloper.org/?p=101</link>
<comments>http://blog.phpdeveloper.org/?p=101#comments</comments>
<pubDate>Sat, 31 May 2008 00:47:18 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[PHP]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=101</guid>
<description><![CDATA[I've been working on a sort-of content management system at work and I wanted to get some opinions on the structure of it. Here's the basic summary:
I have a database table that keeps the content for me (title, content, date stamp, etc) - each item has a type. My goal was to have a system [...]]]></description>
<content:encoded><![CDATA[<p>I've been working on a sort-of content management system at work and I wanted to get some opinions on the structure of it. Here's the basic summary:</p>
<p>I have a database table that keeps the content for me (title, content, date stamp, etc) - each item has a type. My goal was to have a system that would be flexible and allow me to store both hierarchal and date sorted information easily and all in one place. I set out with the intent to make it something I could potentially use for simple blogs, forums and even static content like FAQs.</p>
<p>Basically, everything is a child of something - there's a starting point (the top parent) and all of the children from there down. Since it's on Oracle, CONNECT BY is my best friend. I can point it at a parent and get back a recursive array of the values. So, if our top level was "blog" then its children might each be a "blogentry" with each of those having a collection of "blogcomment" content blocks.</p>
<p>You can see how the same sort of thing could apply itself to a forum layout (remarkably similar, actually). Parent/child all the way down, allowing for any number of nested levels of categories and topics.</p>
<p>Now comes the fun part - the PHP code.</p>
<p>I'm not quite done working all of the kinks out of it yet, but it's close. Here's the though process behind it, though. A fetch() function is called on the top-most parent to get it and its children's data. This is passed to a display() call to be handled. Inside of the display() call is a bit of logic that starts looking at the types of the data. The TYPE column in our table is really the key to how the whole system works. The display() logic looks at the type of the first item of data passed in and loads in a Helper from a predefined directory (include_once, of course). These are named according to the type they help with - so HelperBlog helps with type "blog", HelperBlogentry helps with "blogentry", etc. These are loaded, a new object is made and the display() method is called on it.</p>
<p>The children are passed in to this method where, if the child class (HelperBlog or whatever) chooses, they can be iterated over. The fun thing is that since the class extends our main class (in my case DynContent), we can just call the parent::display() method with the child data and it will recurse down through each of the layers.</p>
<p>There's more to it than just this (templating, permissions, etc) that I'm still working on, but it seems like it has potential. I'm curious as to if anyone else out there has approached this kind of idea in a similar way. I'd love to hear feedback/comments/whatever about the idea from anyone out there.</p>
<p>I don't have the code posted anywhere yet, but if you have an interest let me know in the comments.</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=101</wfw:commentRss>
</item>
<item>
<title>Book Review: Beginning PHP and Oracle (Apress)</title>
<link>http://blog.phpdeveloper.org/?p=100</link>
<comments>http://blog.phpdeveloper.org/?p=100#comments</comments>
<pubDate>Tue, 13 May 2008 19:54:04 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Community]]></category>
<category><![CDATA[PHP]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=100</guid>
<description><![CDATA[The nice friendly people over at APress sent me a few new books the other day, one of which is "Beginning PHP and Oracle: From Novice to Professional" by W. Jason Gilmore and Bob Bryla. Of the three, I was most interested in this one as a possible resource to hand off to other people [...]]]></description>
<content:encoded><![CDATA[<p>The nice friendly people over at APress sent me <a href="http://flickr.com/photos/ccornutt/2477244108/">a few new books</a> the other day, one of which is <a href="http://apress.com/book/view/1590597702">"Beginning PHP and Oracle: From Novice to Professional"</a> by W. Jason Gilmore and Bob Bryla. Of the three, I was most interested in this one as a possible resource to hand off to other people in our company (the Oracle developers, specifically) for them to get started with PHP. Thankfully I can say that, after going through the book, it looks like an excellent fill to bridge the gap between most Oracle developers and the world of PHP.</p>
<p>If you're a PHP developer, pick up your copy of the book and follow my lead - set the book, spine down, on the table and stick your finger right in the middle. To your left is all of the PHP knowledge you've already learned and to your right is a wide open range of Oracle goodness just waiting for you to soak it all in. The first half of the book is an excellent introduction to PHP and can be handed to that special Oracle developer in your life who would like to get to know the language. The usual topics are there - the basic syntax, functions, arrays, object oriented programming, PEAR and lots more. If you're just going in for the Oracle/PHP combo, you'll find a lot more than you were asking for (which can be good and bad).</p>
<p>Things switch around at about the Chapter 26 mark where the first hints of Oracle start to show. This is where a lot of the Oracle developers out there can tune out a little more. The first few Oracle chapters deal with setting up and getting to know the Oracle environment, how to use views and transactions. Things get interesting when PHP jumps back in, though. PHP and Oracle developers alike can learn lots here.</p>
<p>Starting from Chapter 32 on, the rest of the book is devoted to the happy union of PHP making requests via the Oracle drivers to a local database (they use a local copy of Oracle Database XE in their examples). They include examples using transactions, generating a table of results with PEAR's HTML_Table and using views and triggers in your application.</p>
<p>This book works well for both audiences - the PHP developer wanting to learn what all the fuss surrounding Oracle is about and the Oracle developer looking for a peek into the world of the web's most popular web development language. There's a little something here for everyone (there's even a chapter on web services!) and it will be finding its way to the desks of several Oracle devs around here that have been bugging me to show them "that PHP thing" they've been hearing about.</p>
<p>Something a little more substantial - the Table of Contents:
<ul>
<li>Chapter 1 Introducing PHP
</li>
<li>Chapter 2 Configuring Your Environment
</li>
<li>Chapter 3 PHP Basics
</li>
<li>Chapter 4 Functions
</li>
<li>Chapter 5 Arrays
</li>
<li>Chapter 6 Object-Oriented PHP
</li>
<li>Chapter 7 Advanced OOP Features
</li>
<li>Chapter 8 Error and Exception Handling
</li>
<li>Chapter 9 Strings and Regular Expressions
</li>
<li>Chapter 10 Working with the File and Operating System
</li>
<li>Chapter 11 PEAR
</li>
<li>Chapter 12 Date and Time
</li>
<li>Chapter 13 Forms
</li>
<li>Chapter 14 Authentication
</li>
<li>Chapter 15 Handling File Uploads
</li>
<li>Chapter 16 Networking
</li>
<li>Chapter 17 PHP and LDAP
</li>
<li>Chapter 18 Session Handlers
</li>
<li>Chapter 19 Templating with Smarty
</li>
<li>Chapter 20 Web Services
</li>
<li>Chapter 21 Secure PHP Programming
</li>
<li>Chapter 22 SQLite
</li>
<li>Chapter 23 Introducing PDO
</li>
<li>Chapter 24 Building Web Sites for the World
</li>
<li>Chapter 25 MVC and the Zend Framework
</li>
<li>Chapter 26 Introducing Oracle
</li>
<li>Chapter 27 Installing and Configuring Oracle Database XE
</li>
<li>Chapter 28 Oracle Database XE Administration
</li>
<li>Chapter 29 Interacting with Oracle Database XE
</li>
<li>Chapter 30 From Databases to Datatypes
</li>
<li>Chapter 31 Securing Oracle Database XE
</li>
<li>Chapter 32 PHP’s Oracle Functionality
</li>
<li>Chapter 33 Transactions
</li>
<li>Chapter 34 Using HTML_Table with Advanced Queries
</li>
<li>Chapter 35 Using Views
</li>
<li>Chapter 36 Oracle PL/SQL Subprograms
</li>
<li>Chapter 37 Oracle Triggers
</li>
<li>Chapter 38 Indexes and Optimizing Techniques
</li>
<li>Chapter 39 Importing and Exporting Data
</li>
<li>Chapter 40 Backup and Recovery
</li>
</ul>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=100</wfw:commentRss>
</item>
<item>
<title>Deploying PHP Applications?</title>
<link>http://blog.phpdeveloper.org/?p=99</link>
<comments>http://blog.phpdeveloper.org/?p=99#comments</comments>
<pubDate>Mon, 12 May 2008 20:35:28 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[PHP]]></category>
<category><![CDATA[Personal]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=99</guid>
<description><![CDATA[So, a question for everyone out there - we're looking to do a bit of an overhaul for our build and release system and I was wondering what kind of setups you all out there had for your releases?
I've seen all sorts of different things (including a version control->rsync to production push and a fully [...]]]></description>
<content:encoded><![CDATA[<p>So, a question for everyone out there - we're looking to do a bit of an overhaul for our build and release system and I was wondering what kind of setups you all out there had for your releases?</p>
<p>I've seen all sorts of different things (including a version control->rsync to production push and a fully CruiseControled push for everything) but I wanted to hear back from you fellow PHPers out there as to the kind of stuff you're using. We're looking to try to keep it open sourceish stuff, so suggestions down that line would be best but we're pretty open.</p>
<p>I don't have much experience with a more formalized build process but we're coming up against a need to separate out the responsibilities a bit more.</p>
<p>What do you use for your build (and deployment) process for your PHP applications and websites?</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=99</wfw:commentRss>
</item>
<item>
<title>Keep PHP Alive! Grow a Beard!</title>
<link>http://blog.phpdeveloper.org/?p=98</link>
<comments>http://blog.phpdeveloper.org/?p=98#comments</comments>
<pubDate>Thu, 01 May 2008 16:42:10 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Community]]></category>
<category><![CDATA[PHP]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=98</guid>
<description><![CDATA[Apparently, beards and programming languages have a direct correlation with each other, at least according to Tamir Khason. His latest list (a "take two" from this older post) reinforces the idea, pointing out lots of different languages and the people involved. Basically, the facial hair (beard, mutton chops, goatee, soul patch, whatever) of the major [...]]]></description>
<content:encoded><![CDATA[<p>Apparently, beards and programming languages have a direct correlation with each other, at least <a href="http://blogs.microsoft.co.il/blogs/tamir/archive/2008/04/28/computer-languages-and-facial-hair-take-two.aspx">according to Tamir Khason</a>. His latest list (a "take two" from <a href="http://www.alenz.org/mirror/khason/why-microsoft-can-blow-off-with-c.html">this older post</a>) reinforces the idea, pointing out lots of different languages and the people involved. Basically, the facial hair (beard, mutton chops, goatee, soul patch, whatever) of the major players involved is an indication as to how well the programming language is doing. Language in the "No Facial Hair" crowd include F#, IronPython and Prolog while the cool cats in the "Facial Hair Everywhere" group include C, Perl, Ruby and Python.</p>
<p>So, where does PHP fit on the list? Well, he points to <a href="http://blogs.microsoft.co.il/blogs/tamir/WindowsLiveWriter/Computerlanguagesandfacialhairtaketwo_11FB7/image_275220c1-4d7a-4095-aa16-8a6c4e2afa08.png">this picture</a> of Rasmus Lerdorf as a positive indicator for our beloved language, but there just might be enough other developers out there to counteract his effect. </p>
<p>For example:
<ul>
<li><a href="http://flickr.com/photos/benandliz/30335189/">not a mustache to be found here</a>
</li>
<li><a href="http://flickr.com/photos/benandliz/31002306/">a bit found here</a> (go John and Ilia!)
</li>
<li><a href="http://flickr.com/photos/benandliz/202895001/">a huge point for the good guys</a> with Zak's crumb-catcher
</li>
<li><a href="http://flickr.com/photos/benandliz/59728227/">Ben Ramsey</a> sporting a mighty fine bit of face fuzz
</li>
<li><a href="http://flickr.com/photos/moosh_claroline/2219809160/">awesome representation</a> from Belgium (I have been corrected)
</li>
<li><a href="http://flickr.com/photos/calevans/2455324766/">a bit of fuzz</a> from Cal Evans (of Zend)
</li>
<li>a sad <a href="http://flickr.com/photos/sebastian_bergmann/52408671/">lack of facial hair</a> from the Zend Twins - Andi Gutmans and Zeev Suraski
</li>
<li><a href="http://flickr.com/photos/sebastian_bergmann/243527223/">another plus</a> from Marco Tabini (of php|architect)
</li>
<li>and, of course, <a href="http://flickr.com/photos/sebastian_bergmann/243527226/in/photostream/">The Wez</a>
</li>
<li>Marcus, Dan and Wez <a href="http://flickr.com/photos/whitney1230/3408432/">showing off</a> their contributions toward the cause
</li>
<li>and <a href="http://flickr.com/photos/jeremyjohnstone/2208434859/">this guy</a> gets a little extra credit for not only the mutton-chops and goatee but also for the amount of time he put in to make the rest of the hair on his head do that
</li>
</ul>
<p>Though thankfully, there's one growing part of the PHP community that makes it so much better without even having to worry about the facial hair (thank goodness) - the <a href="http://flickr.com/photos/pollita/501715748/">PHP Women</a> (coming soon to a <a href="http://flickr.com/photos/dotjay/2302084866/">conference near you</a>!)</p>
<p>So, what's the result? Does PHP pass the "Khason Test" for survival? Could the best way to support the community possibly be to let that facial hair grow? It's too soon to tell, if you ask me - right now, though, I'd say the current follicle count is tipping in favor of PHP being around for a good long time... </p>
<p>(Oh, and in case you're wondering - yes, I am a <a href="http://flickr.com/photos/calevans/286952353/">little</a> on the <a href="http://flickr.com/photos/calevans/284207844/">scruffy side</a> myself)</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=98</wfw:commentRss>
</item>
<item>
<title>Save your Site, Cache that Data!</title>
<link>http://blog.phpdeveloper.org/?p=97</link>
<comments>http://blog.phpdeveloper.org/?p=97#comments</comments>
<pubDate>Fri, 25 Apr 2008 17:38:06 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[PHP]]></category>
<category><![CDATA[Solar]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=97</guid>
<description><![CDATA[One of the things that I've noticed in running PHPDeveloper.org is that the highest traffic (most of the traffic for the site, actually) is going to the RSS feed giving the latest news I've posted. When I first relaunched the site with Solar, things were fine - but only for about ten minutes. As soon [...]]]></description>
<content:encoded><![CDATA[<p>One of the things that I've noticed in running PHPDeveloper.org is that the highest traffic (most of the traffic for the site, actually) is going to the RSS feed giving the latest news I've posted. When I first relaunched the site with <a href="http://www.solarphp.com">Solar</a>, things were fine - but only for about ten minutes. As soon as everyone's aggregators came back on and started pulling the feed, the load on my server shot straight up. Thankfully I was able to get it back down to a more manageable level with a static version before the box took a nosedive. I had to do something about it and I figured that caching the feed's information was definitely a start. </p>
<p>I'd never really used the <a href="http://solarphp.com/class/Solar_Cache">Solar_Cache</a> stuff before, but thankfully - it's super easy. I figured that the biggest bottleneck in making the feed was pulling the data from the database each time. I opened up the controller for my feed (Feed.php - I know, very creative) and added a Solar_Cache object.</p>
<p>You can set this stuff up in your <a href="http://solarphp.org/manual:solar:config_file?s=config">configuration file</a> too, but I dropped it into my controller as a quick solution.</p>
<p>In my _setup() call:
<div class="igBar"><span id="lcode-5"><a href="#" onclick="javascript:showPlainTxt('code-5'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-5">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$config=array<span style="color:#006600; font-weight:bold;">(</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> <span style="color:#CC0000;">'adapter'</span>=> <span style="color:#CC0000;">'Solar_Cache_Adapter_File'</span>,</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> <span style="color:#CC0000;">'path'</span>=> <span style="color:#CC0000;">'/tmp'</span>,</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> <span style="color:#CC0000;">'life'</span>=> <span style="color:#800000;color:#800000;">200</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">)</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$this-><span style="">cache</span> = Solar::<span style="">factory</span><span style="color:#006600; font-weight:bold;">(</span><span style="color:#CC0000;">'Solar_Cache'</span>, $config<span style="color:#006600; font-weight:bold;">)</span>; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>This creates a cache object in $this->cache that I can use for whatever I want. It's file caching and the results will get put in /tmp. That "200" for the life is in seconds, so it's at about three minutes right now. There's lots more options for caching besides files already built into the framework too like <a href="http://solarphp.com/class/Solar_Cache_Adapter_Apc">APC</a>, <a href="http://solarphp.com/class/Solar_Cache_Adapter_Eaccelerator">eAccelerator</a>, <a href="http://solarphp.com/class/Solar_Cache_Adapter_Var">variables</a> and <a href="http://solarphp.com/class/Solar_Cache_Adapter_Xcache">XCache</a>.</p>
<p>With our object made, we apply it down in our default actionIndex() wrapped around our database fetch:
<div class="igBar"><span id="lcode-6"><a href="#" onclick="javascript:showPlainTxt('code-6'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-6">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$ret=$this-><span style="">cache</span>-><span style="">fetch</span><span style="color:#006600; font-weight:bold;">(</span><span style="color:#CC0000;">'feed_data'</span><span style="color:#006600; font-weight:bold;">)</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">if<span style="color:#006600; font-weight:bold;">(</span>!$ret<span style="color:#006600; font-weight:bold;">)</span><span style="color:#006600; font-weight:bold;">{</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> $news=$this-><span style="">news</span>-><span style="">fetchNews</span><span style="color:#006600; font-weight:bold;">(</span><span style="color:#006600; font-weight:bold;">)</span>;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> $this-><span style="">cache</span>-><span style="">save</span><span style="color:#006600; font-weight:bold;">(</span><span style="color:#CC0000;">'feed_data'</span>,$news<span style="color:#006600; font-weight:bold;">)</span>;</div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"> $ret=$news;</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;"><span style="color:#006600; font-weight:bold;">}</span></div>
</li>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">$this-><span style="">news_items</span>=$ret; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>Pretty simple, really - the cache object checks to see if the data already exists and, if it does, just passes it on through to our view. If it doesn't (either that it's the first time it's being made or it has expired) it will pull the new news and push it out to the cache. The view then takes this array of values and makes a basic RSS feed out of it for all the world to see.</p>
<p>You wouldn't believe how much something simple like caching your feed can help on even a moderately popular site. Check out <a href="http://solarphp.com/class">the class list</a> for details on the other caching options.</p>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=97</wfw:commentRss>
</item>
<item>
<title>Twitter Updates for 2008-04-23</title>
<link>http://blog.phpdeveloper.org/?p=96</link>
<comments>http://blog.phpdeveloper.org/?p=96#comments</comments>
<pubDate>Thu, 24 Apr 2008 03:59:59 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Personal]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=96</guid>
<description><![CDATA[
@ramsey: did you ever get that "too many requests" issue solved with spaz? #
work you damn jquery selector! i command thee! #
@funkatron on spaz? every time I fire it up I get that "too many API requests" message after a few seconds #
@funkatron @ElizabethN trying the passowrd thing first... #
hmm, interesting - an onclick on [...]]]></description>
<content:encoded><![CDATA[<ul class="aktt_tweet_digest">
<li>@ramsey: did you ever get that "too many requests" issue solved with spaz? <a href="http://twitter.com/enygma/statuses/795085814">#</a></li>
<li>work you damn jquery selector! i command thee! <a href="http://twitter.com/enygma/statuses/795115226">#</a></li>
<li>@funkatron on spaz? every time I fire it up I get that "too many API requests" message after a few seconds <a href="http://twitter.com/enygma/statuses/795154646">#</a></li>
<li>@funkatron @ElizabethN trying the passowrd thing first... <a href="http://twitter.com/enygma/statuses/795174486">#</a></li>
<li>hmm, interesting - an onclick on an anchor and an onclick on a div firing at the same time <a href="http://twitter.com/enygma/statuses/795188071">#</a></li>
<li>@jeichorn nice! <a href="http://twitter.com/enygma/statuses/795220459">#</a></li>
<li>@ElizabethN heh...me too...wonder what it was <a href="http://twitter.com/enygma/statuses/795227104">#</a></li>
<li>okay, this cough is officially getting old <a href="http://twitter.com/enygma/statuses/795238528">#</a></li>
<li>grr....slow people-- <a href="http://twitter.com/enygma/statuses/795327110">#</a></li>
<li>how many dbas does it take to check permissions on a sequence...(apparently 3) <a href="http://twitter.com/enygma/statuses/795342090">#</a></li>
<li>@elazar heheh <a href="http://twitter.com/enygma/statuses/795351386">#</a></li>
<li>i <3 last.fm <a href="http://twitter.com/enygma/statuses/795419069">#</a></li>
</ul>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=96</wfw:commentRss>
</item>
<item>
<title>Twitter Updates for 2008-04-22</title>
<link>http://blog.phpdeveloper.org/?p=95</link>
<comments>http://blog.phpdeveloper.org/?p=95#comments</comments>
<pubDate>Wed, 23 Apr 2008 03:59:59 +0000</pubDate>
<dc:creator>enygma</dc:creator>
<category><![CDATA[Personal]]></category>
<guid isPermaLink="false">http://blog.phpdeveloper.org/?p=95</guid>
<description><![CDATA[
Happy Earth Day all (or for me and my wife, our anniversary - woo!) #
we now return to "damn nature, you're scary!" #
]]></description>
<content:encoded><![CDATA[<ul class="aktt_tweet_digest">
<li>Happy Earth Day all (or for me and my wife, our anniversary - woo!) <a href="http://twitter.com/enygma/statuses/794234369">#</a></li>
<li>we now return to "damn nature, you're scary!" <a href="http://twitter.com/enygma/statuses/794455593">#</a></li>
</ul>
]]></content:encoded>
<wfw:commentRss>http://blog.phpdeveloper.org/?feed=rss2&p=95</wfw:commentRss>
</item>
</channel>
</rss>
|