<?xml version="1.0" encoding="UTF-8"?> <rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" ><channel><title>x-pose.org &#187; php</title> <atom:link href="http://x-pose.org/category/php/feed/" rel="self" type="application/rss+xml" /><link>http://x-pose.org</link> <description>Tech Geek and Web Developer</description> <lastBuildDate>Tue, 31 Jan 2012 06:17:27 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>APC Uptime Restarts Every 2 Hours</title><link>http://x-pose.org/2012/01/apc-uptime-restarts-every-2-hours/</link> <comments>http://x-pose.org/2012/01/apc-uptime-restarts-every-2-hours/#comments</comments> <pubDate>Tue, 31 Jan 2012 01:17:27 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[apache]]></category> <category><![CDATA[cpanel]]></category> <category><![CDATA[how-to]]></category> <category><![CDATA[php]]></category><guid isPermaLink="false">http://x-pose.org/?p=423</guid> <description><![CDATA[Do you happen to have a really bad uptime for PHP&#8217;s APC, and it seems to randomly restart after 2 hours or so?  Well, chances are that you are running cPanel/WHM on this server as well? The problem is that you need to enable Piped Loggin for Apache.   This can be found under Apache [...] No related posts.]]></description> <content:encoded><![CDATA[<p>Do you happen to have a really bad uptime for PHP&#8217;s APC, and it seems to randomly restart after 2 hours or so?  Well, chances are that you are running cPanel/WHM on this server as well?</p><p>The problem is that you need to <strong>enable Piped Loggin for Apache</strong>.   This can be found under <strong>Apache Configuration</strong> in WHM.</p><p>It says:</p><blockquote><p>Configure Apache to use a single log target for all virtual host access and bandwidth logs. The combined logs will be piped to a helper application where they can be split based upon domain. This option will reduce the number of log files Apache manages freeing up system resources. Piped logging is recommended for systems with a large number of domains. By default this feature is disabled, and Apache will create distinct log files for each virtual host entry.</p></blockquote><p>Once you do this, your log files will be processed (it defaults to every 2 hours), without APC restarting.  For even more information, head over to <a href="http://forums.cpanel.net/f5/why-apache-restarting-every-two-hours-254022.html">this post on the cPanel forums</a>.</p><p>This problem is obviously very frustrating and it took me quite a while to dig up the solution.  Hopefully this helps others out there.</p><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2012/01/apc-uptime-restarts-every-2-hours/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>FantasySP, Building a Better Upgrade Flow</title><link>http://x-pose.org/2011/12/fantasysp-building-a-better-upgrade-flow/</link> <comments>http://x-pose.org/2011/12/fantasysp-building-a-better-upgrade-flow/#comments</comments> <pubDate>Wed, 28 Dec 2011 21:11:19 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[guide]]></category> <category><![CDATA[how-to]]></category> <category><![CDATA[php]]></category><guid isPermaLink="false">http://x-pose.org/?p=390</guid> <description><![CDATA[A few weeks ago I came to the realization that my current implementation of upgrading and billing users on FantasySP using Paypal was pretty terrible. It was a clunky process where the user left my site to go to paypal, then they could sign in and/or input their credit card information.  After that, they get [...] No related posts.]]></description> <content:encoded><![CDATA[<p>A few weeks ago I came to the realization that my current implementation of upgrading and billing users on <a href="http://www.fantasysp.com/">FantasySP</a> using Paypal was pretty terrible.</p><p>It was a clunky process where the user left my site to go to paypal, then they could sign in and/or input their credit card information.  After that, they get directed back to my site to a &#8220;success&#8221; page.</p><p>The user was unable to upgrade from a monthly subscription to a yearly subscription, if he so chose.  I never implemented automatic membership downgrades/upgrades because I thought I would be leaving paypal sooner rather than later.  To top it off, the design of the page was just plain bad.</p><p>Talk about a mess.  This is what my upgrade/billing page used to look like:</p><p>&nbsp;</p><div id="attachment_391" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/oldbilling-page.png"><img class="size-medium wp-image-391" title="oldbilling-page" src="http://x-pose.org/wp-content/uploads/2011/12/oldbilling-page-300x151.png" alt="" width="300" height="151" /></a><p class="wp-caption-text">Old Billing Page</p></div><h2>Simplicity is Key</h2><p>When it comes to designing and implementing the new upgrade flow, I knew I wanted something <strong>extremely simple and easy to use:</strong></p><ol><li>User should stay on the fantasysp.com domain during the process (SSL would have to be installed)</li><li>Only 2 subscription choices to pick from with a suggested audience.</li><li>Able to upgrade from monthly to yearly with a prorated cost.</li><li>Able to apply a coupon code during selection BEFORE he checks out.</li><li>Easily see the breakdown of features.</li></ol><p><strong></strong>For me, <a href="https://stripe.com/">Stripe</a> seemed like the best option.  There are countless posts out there detailing what Stripe is all about and why its cool.  During the checkout process, stripe uses a javascript library that handles the form submission and processing of credit card information.  If it all checks out, then the form is submitted to my server with an authenticated token that stripe recognizes to perform the transaction, create a new customer, or subscribe them to a plan.  Therefore <strong>no credit card information is actually handled by my server</strong>.</p><h2>Design the Page</h2><p>Instead of hiring a professional designer, I decided to take a crack at this one myself.  If what I made looked like shit then I would bite the bullet and hire a pro.  I would never say that I am a designer, but I can pretend to be one.   I looked at quite a few checkout pages ranging from 37signals to Old Navy.  I skipped the Photoshop process of a mockup and went straight to designing in HTML/CSS because I knew what I wanted in my head:</p><div id="attachment_392" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page.png"><img class="size-medium wp-image-392" title="newbilling-page" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-300x144.png" alt="" width="300" height="144" /></a><p class="wp-caption-text">User Upgrade Options</p></div><p>The boxes look pretty much like Monopoly cards, right? Instead of smashing everything together, I wanted to make sure I utilized the entire width of the website.  The user is presented with a CLEAR option of free, monthly, or yearly plus.   Underneath the price suggests who would benefit best from the plan.  Monthly is for the seasonal fantasy player, whereas Yearly is for hardcore players, and Standard is for the casual player.  When mousing over each box, the background turns yellow.</p><p>You may notice that I decided to use different fonts (via Google Fonts) because I think it makes it appear and feel more unique.  Arial gets boring real quick.  I also wanted to make sure that the page relied solely on CSS for styling.  Everything you see there are some fairly simple and common CSS techniques to add a bit of flare to each box.</p><p>The coupon code is shown just below the choices WITHOUT a button.  My site will analyze the text as the user types or pastes the coupon into the box.  In order to proceed to the next page, the user must click a box.  If a valid/expired coupon code is detected then it gives a message like so:</p><div id="attachment_393" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-coupon.png"><img class="size-medium wp-image-393" title="newbilling-page-coupon" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-coupon-300x141.png" alt="" width="300" height="141" /></a><p class="wp-caption-text">Coupon Code Entered</p></div><p>But of course, the user needs to see the full breakdown of the features.  The user also needs to see what the site would look like as a Yearly Plus subscriber, which means the top banner of the site will show Player Trends instead of banner ads:</p><div id="attachment_394" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-fullpage.png"><img class="size-medium wp-image-394" title="newbilling-fullpage" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-fullpage-300x218.png" alt="" width="300" height="218" /></a><p class="wp-caption-text">More of the Page</p></div><p>The user can mouse over the bottom 4 choices and see more information about each via tooltips powered by qTips.  Now lets move onto the actual form to submit the subscription order:</p><p>&nbsp;</p><div id="attachment_395" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-checkout.png"><img class="size-medium wp-image-395" title="newbilling-page-checkout" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-checkout-300x171.png" alt="" width="300" height="171" /></a><p class="wp-caption-text">Checkout Form</p></div><p>Thanks to Stripe, I don&#8217;t need their billing address or even full name to process an order.  <strong>We want the bare minimum here so the user can quickly move on</strong>.  Next to the plan is an option to change their plan.  There is also an option to &#8220;Go Back&#8221; incase the user changes their mind. The &#8220;Submit Payment&#8221; button is BIG and BOLD because the user should be able to quickly find the &#8220;Submit&#8221; button.</p><p>Again, clicking the &#8220;Submit Payment&#8221; button sends the information to Stripe and then responds back with a token if valid.  Once that happens, then communication between Stripe occurs and the user is upgraded to their selected plan.  If all goes well, the form is finally submitted and the user is presented with a Success page.</p><h2>But Wait, There&#8217;s More</h2><p>You thought that was it, huh?  That is the basic checkout process, but the user needs to see an email invoice to ensure they have something for their records.  Sounds like something else I have to design that also needs to look just as good and be just as simple.  Luckily I recently redesigned the email newsletter that goes out, so I used that template for the invoice:</p><div id="attachment_396" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/email-invoice.png"><img class="size-medium wp-image-396" title="email-invoice" src="http://x-pose.org/wp-content/uploads/2011/12/email-invoice-300x194.png" alt="" width="300" height="194" /></a><p class="wp-caption-text">Email Invoice</p></div><p>Looks like I should be nearly done with the design of the billing process, but there are a few more possibilites to take into account.  What about Cancelling memberships?  What about Upgrading from a Monthly subscription to a Yearly Plus?</p><div id="attachment_398" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-enrolledmonthly.png"><img class="size-medium wp-image-398" title="newbilling-page-enrolledmonthly" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-enrolledmonthly-300x141.png" alt="" width="300" height="141" /></a><p class="wp-caption-text">Enrolled in Monthly</p></div><div id="attachment_397" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-enrolledmonthly-upgrade.png"><img class="size-medium wp-image-397" title="newbilling-page-enrolledmonthly-upgrade" src="http://x-pose.org/wp-content/uploads/2011/12/newbilling-page-enrolledmonthly-upgrade-300x142.png" alt="" width="300" height="142" /></a><p class="wp-caption-text">Clicked to Upgrade</p></div><p>As you can see, choosing to upgrade a subscription prompts the user with a new box via jQuery UI.  After clicking yes, the user is shown the price and is sent a new prorated invoice. Similarly, if the user wishes to cancel, then a similar box would pop up.</p><h2><strong>Wrap Up</strong></h2><p>Revamping a billing page takes a lot of planning, testing, and fine tuning.  Just the design implementation alone took about 2 weeks with lots of tweaking.  Lots of frontend technologies are used including jQuery, jQuery UI, Google Fonts, Stripe, and qTip.  There are still a few things that need to be tweaked on the frontend and backend, but overall the new billing is exactly what I envisioned and is light-years better than what I had.</p><p>Hopefully this post will help others who are thinking about revamping their upgrade flow. Nearly 3 weeks of hard-work launched a few days ago and it was great to see a few users already go through the process with no problems.  Merry Christmas to me.</p><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2011/12/fantasysp-building-a-better-upgrade-flow/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Fix the WordPress SQL_CALC_FOUND_ROWS Bug</title><link>http://x-pose.org/2011/08/fix-the-wordpress-sql_calc_found_rows-bug/</link> <comments>http://x-pose.org/2011/08/fix-the-wordpress-sql_calc_found_rows-bug/#comments</comments> <pubDate>Wed, 17 Aug 2011 22:58:57 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[optimization]]></category> <category><![CDATA[php]]></category> <category><![CDATA[wordpress]]></category><guid isPermaLink="false">http://x-pose.org/?p=329</guid> <description><![CDATA[Anyone who has a WordPress blog with a lot of posts will eventually encounter an extremely slow query. I refer to this as the SQL_CALC_FOUND_ROWS Bug. If you have slow-query-log enabled then a query similar to this might have shown up before: SELECT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID NOT IN (44682, 44657, [...] No related posts.]]></description> <content:encoded><![CDATA[<p>Anyone who has a WordPress blog with a lot of posts will eventually encounter an extremely slow query. I refer to this as the <strong>SQL_CALC_FOUND_ROWS Bug</strong>. If you have slow-query-log enabled then a query similar to this might have shown up before:</p><p><code>SELECT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts WHERE 1=1 AND wp_posts.ID NOT IN (44682, 44657, 44630) AND wp_posts.post_type = 'post' AND (wp_posts.post_status = 'publish') GROUP BY wp_posts.ID ORDER BY wp_posts.post_date DESC LIMIT 24580, 5</code></p><p>Just how detremential is this to your blogs performance?  Well thanks to newrelic, I can show you:</p><div id="attachment_330" class="wp-caption aligncenter" style="width: 310px"><a href="http://x-pose.org/wp-content/uploads/2011/08/wordpress-sql-bug.png"><img class="size-medium wp-image-330" title="wordpress-sql-bug" src="http://x-pose.org/wp-content/uploads/2011/08/wordpress-sql-bug-300x46.png" alt="" width="300" height="46" /></a><p class="wp-caption-text">SQL_CALC_FOUND_ROWS Bug</p></div><p>Unfortunately I don&#8217;t know why WordPress runs this query.  What I do know is that it apparently only shows up on index.php.  What you probably care about is how to fix this problem.   I&#8217;ve located a possible workaround thanks to <a href="http://core.trac.wordpress.org/ticket/10964">this open ticket at wordpress.org</a>.  The <a href="http://core.trac.wordpress.org/attachment/ticket/10964/simple_groupby_modified.10964.diff">diff log on the changes are listed as well</a>.  I went ahead and applied these code changes to wp-includes/query.php.  <strong>The fixed query.php can be <a href="http://snipt.org/xmmgn">found here</a></strong>.</p><p>How are the results so far?  Inconclusive.  I just applied this patch and nothing broke so far, which is always a plus.  I suggest you give it a try and see how your blog responds in a development environment.  If I STILL spot slowdowns in the revised query, then I will update this post and let you know.</p><p>Some of you might be asking, does this affect your version of WordPress? The answer is yes.  I am running WordPress 3.2.1.</p><p>Please do post your thoughts, concerns, or comments to help others out.</p><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2011/08/fix-the-wordpress-sql_calc_found_rows-bug/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> <item><title>My Review of New Relic, with some Performance Numbers</title><link>http://x-pose.org/2011/05/my-review-of-new-relic-with-some-performance-numbers/</link> <comments>http://x-pose.org/2011/05/my-review-of-new-relic-with-some-performance-numbers/#comments</comments> <pubDate>Sat, 21 May 2011 01:41:29 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[optimization]]></category> <category><![CDATA[php]]></category><guid isPermaLink="false">http://x-pose.org/?p=257</guid> <description><![CDATA[When optimizing your web application or server, the process can be a bit daunting.  In fact, its usually something that is never fully checked off your to-do-list.  The reason being is that you&#8217;ll never really know how your application will scale until it starts to show its growing pains.  Just when you thought that you&#8217;ve [...] No related posts.]]></description> <content:encoded><![CDATA[<p>When optimizing your web application or server, the process can be a bit daunting.  In fact, its usually something that is never fully checked off your to-do-list.  The reason being is that you&#8217;ll never really know how your application will scale until it starts to show its growing pains.  Just when you thought that you&#8217;ve addressed the performance issues, a few weeks or months go by and new ones will crop up.</p><p>Before New Relic came along, I used to cat the slow-query-log.  I would address any queries that I saw took a while to execute.   Then there is the <a href="http://www.day32.com/MySQL/">MySQL Performance Tuning Primer Script</a>.  Also a great tool and will give you a good idea on how MySQL is performing as a whole.  I would continue to look at these things, but the load averages kept climbing and I could not figure out what the problem was.  I also couldn&#8217;t figure out which pages took the longest to load.</p><h1>Enter New Relic</h1><p>I actually considered throwing more hardware at the problem, since I could not figure it out through the usual means.  Then New Relic came along and I decided to give it a try.  Here is my site performance graph since I first started using New Relic:</p><div id="attachment_263" class="wp-caption aligncenter" style="width: 444px"><a href="http://x-pose.org/wp-content/uploads/2011/05/relic.png"><img class="size-full wp-image-263 " title="relic" src="http://x-pose.org/wp-content/uploads/2011/05/relic.png" alt="" width="434" height="275" /></a><p class="wp-caption-text">Performance</p></div><p>You&#8217;ll notice that when it was first turned on, the database was clearly the issue.  The problem was UPDATING a table that has almost 2 million rows. (Duh.  Apparently, it was way more costly than I ever imagined)  Incrementing the view count on one of the main tables was the root cause to 90% of my problems.  I went ahead and created dedicated tables to hold these stats  and <strong>load averages eventually settled to around .20 across the board</strong>.  MySQL was no longer an issue.  <a href="http://www.fantasysp.com">FantasySP</a> was silky smooth, once again!</p><p>The best part about New Relic is that once you set it up, you don&#8217;t have to spend time SSH&#8217;ing your box to find performance issues.  Everything you need is much easier to read, not to mention there is a performance breakdown based on each page/script.  Now I can easily see the pages, ajax requests, and background tasks that take the longest to complete.  All of these can be easily optimized now.  Their interface isn&#8217;t perfect, but it&#8217;s improving every day.</p><h1>Impact on Google Bot &amp; Organic Search</h1><p>Of course when you optimize your website you do so for the end user experience.  The added plus to this is that Google Bot gets a huge benefit from it too.  I&#8217;ve been reading over and over about how <a href="http://www.seo.com/blog/website-loading-time-ranking-factor-google/">load time is now a ranking factor</a>.  Sure, but it&#8217;s not that big of a deal, right?  Well, lets take a look at how Google Bot responded to these tweaks:</p><div class="wp-caption aligncenter" style="width: 510px"><img title="Pages Crawled Per Day" src="https://chart.googleapis.com/chart?cht=lc&amp;chc=wmc&amp;chd=s:_________________gomhdYRgvst06vhoigpllgfYVZwjfaneouomdkkmkiouqepopqojz4tgh5rRs1zinovedGGIPQHIMUQJMPX7ic44um_____________&amp;chds=0.0,61.0&amp;chs=500x150&amp;chma=70,0,0,0&amp;chco=000080&amp;chm=R,666666,0,0.25,0.251%7CR,666666,0,0.5,0.501%7CR,666666,0,0.75,0.751%7CB,eeeeee,0,0.0,0.0&amp;chxt=y,x&amp;chxr=0,0.0,100.0%7C1,0.0,100.0&amp;chxl=0:%7C0%7C75,000%7C150,000%7C1:%7CFeb%7CMar%7CApr%7CMay&amp;chxp=0,0.0,50.0,100.0%7C1,12.5,37.5,62.5,87.5&amp;chxs=0,666666,11.0,1.0%7C1,666666,11.0,0.0&amp;sig=RYPfN6klRpvMN4R1euYRQpPwVW0" alt="" width="500" height="150" /><p class="wp-caption-text">FantasySP.com | Pages Crawled Per Day</p></div><div class="wp-caption aligncenter" style="width: 510px"><img title="Time Spend Downloading" src="https://chart.googleapis.com/chart?cht=lc&amp;chc=wmc&amp;chd=s:_________________ZfTVVRSRVYQQXcTSPPPPRRWWRSTQRUXRQQRUSVSQRRTTXSOOPPSUOMMOSORRZSUTVcZTYcZwhbWbdaYTVlWjix1KKL_____________&amp;chds=0.0,61.0&amp;chs=500x150&amp;chma=70,0,0,0&amp;chco=800000&amp;chm=R,666666,0,0.25,0.251%7CR,666666,0,0.5,0.501%7CR,666666,0,0.75,0.751%7CB,eeeeee,0,0.0,0.0&amp;chxt=y,x&amp;chxr=0,0.0,100.0%7C1,0.0,100.0&amp;chxl=0:%7C0%7C300%7C600%7C1:%7CFeb%7CMar%7CApr%7CMay&amp;chxp=0,0.0,50.0,100.0%7C1,12.5,37.5,62.5,87.5&amp;chxs=0,666666,11.0,1.0%7C1,666666,11.0,0.0&amp;sig=v1-ayd1tMXWJuZFFla_q4sXL-h0" alt="" width="500" height="150" /><p class="wp-caption-text">FantasySP.com | Time Spend Downloading</p></div><div class="wp-caption aligncenter" style="width: 510px"><img title="Mobile FantasySP.com | Pages Crawled Per Day" src="https://chart.googleapis.com/chart?cht=lc&amp;chc=wmc&amp;chd=s:_________________dbccZdccaegiecddcfeecZUVYWdaeabkcbabfjffYSVRRVRRQQQRVTRQPOTcaYXdWUcbYYYWWVVWVUSUWVXWUcdxvv_____________&amp;chds=0.0,61.0&amp;chs=500x150&amp;chma=70,0,0,0&amp;chco=000080&amp;chm=R,666666,0,0.25,0.251%7CR,666666,0,0.5,0.501%7CR,666666,0,0.75,0.751%7CB,eeeeee,0,0.0,0.0&amp;chxt=y,x&amp;chxr=0,0.0,100.0%7C1,0.0,100.0&amp;chxl=0:%7C0%7C5,000%7C10,000%7C1:%7CFeb%7CMar%7CApr%7CMay&amp;chxp=0,0.0,50.0,100.0%7C1,12.5,37.5,62.5,87.5&amp;chxs=0,666666,11.0,1.0%7C1,666666,11.0,0.0&amp;sig=S-GOZdYAY45HhThDul7cxE_ZFgw" alt="" width="500" height="150" /><p class="wp-caption-text">m.FantasySP.com | Pages Crawled Per Day</p></div><div class="wp-caption aligncenter" style="width: 510px"><img title="Mobile FantasySP | Time Spend Downloading" src="https://chart.googleapis.com/chart?cht=lc&amp;chc=wmc&amp;chd=s:_________________QSQQOPONONMPRSdRMNPNOQPOPQPOQQOOOONQQOPQPRPSMMMNOOOMMNNONOLLVSVRVVXVVZWTUXVduXVSTbUUZaSKLK_____________&amp;chds=0.0,61.0&amp;chs=500x150&amp;chma=70,0,0,0&amp;chco=800000&amp;chm=R,666666,0,0.25,0.251%7CR,666666,0,0.5,0.501%7CR,666666,0,0.75,0.751%7CB,eeeeee,0,0.0,0.0&amp;chxt=y,x&amp;chxr=0,0.0,100.0%7C1,0.0,100.0&amp;chxl=0:%7C0%7C200%7C400%7C1:%7CFeb%7CMar%7CApr%7CMay&amp;chxp=0,0.0,50.0,100.0%7C1,12.5,37.5,62.5,87.5&amp;chxs=0,666666,11.0,1.0%7C1,666666,11.0,0.0&amp;sig=B637urFv5rqswGZTcDoQAUgRN4M" alt="" width="500" height="150" /><p class="wp-caption-text">m.FantasySP | Time Spend Downloading</p></div><p style="text-align: left;">Clearly, the faster the response time, the more pages that can be crawled in a given day.  The average response time for FantasySP.com is now at <strong>around 100ms</strong>.  The average response time for Mobile FantasySP is at<strong> 72ms</strong>.  Google Bot quickly realized that the site is performing faster and ramped up its crawl rate.</p><p style="text-align: left;">So you might be wondering, has the faster and more responsive site resulted in more search engine traffic from Google?  So far, the answer is yes.  By about <strong>5 &#8211; 10%</strong> the past 7 straight days. Coincidence?  I doubt it.  <strong>Getting a bump in SERPs for being a considerably faster site is very real</strong>.  There is no question that the easier it is for Google Bot to crawl, the better off I&#8217;ll be in the long run.</p><h1 style="text-align: left;">Conclusion</h1><p>New Relic has just released a whole bunch of new changes such as <a href="http://blog.newrelic.com/2011/05/17/how-rum-works/">Real User Monitoring</a> , an <a href="http://support.newrelic.com/kb/php/php-agent-installation-redhat-and-centos">improved install process</a>, and a much more <a href="http://newrelic.com/pricing">affordable pricing structure</a>.  It doesn&#8217;t matter if your a company of 15 developers or just one developer working on a side project. . . New Relic will be worth it.  In fact, for smaller sites you should be able to take advantage of New Relic&#8217;s 14 day professional trial and be done optimizing by the time your trial is finished.  However, I&#8217;ve been addicted to the stats and will eventually subscribe to their &#8220;Standard Package&#8221;.</p><p>New Relic essentially takes the guesswork out of optimization.  Now you can easily track down costly plugins in WordPress and even compare performance numbers from week to week.  This is by far the best tool you can use to make your site or app run faster.  Spend the time and install it, or submit a support ticket and have your host do it.</p><p>I can go on and on about New Relic and you will probably get a bit lost in the data for a few days.  So go ahead and give it a try.</p><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2011/05/my-review-of-new-relic-with-some-performance-numbers/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Web Developers, You&#8217;re Not Alone</title><link>http://x-pose.org/2010/06/web-developers-youre-not-alone/</link> <comments>http://x-pose.org/2010/06/web-developers-youre-not-alone/#comments</comments> <pubDate>Sun, 27 Jun 2010 18:13:51 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[guide]]></category> <category><![CDATA[how-to]]></category> <category><![CDATA[php]]></category> <category><![CDATA[developers]]></category> <category><![CDATA[feedback]]></category> <category><![CDATA[help]]></category><guid isPermaLink="false">http://x-pose.org/?p=193</guid> <description><![CDATA[Web developers who plan to work alone, or are already doing so have a lot of obstacles to overcome.  One of which is being isolated and having no like-minded professionals to turn to for advice and feedback.   I know this one all too well and have been working alone  for the past 5+ years on various [...] No related posts.]]></description> <content:encoded><![CDATA[<p>Web developers who plan to work alone, or are already doing so have a lot of obstacles to overcome.  One of which is being isolated and having no like-minded professionals to turn to for advice and feedback.   I know this one all too well and have been working alone  for the past 5+ years on various projects.  My current project, <a href="http://www.fantasysp.com/" target="_blank">FantasySP</a>, has been extremely challenging and rewarding at the same time.  Reinventing how people manage their fantasy sports teams can be quite a challenge.</p><p>Smashing magazine wrote a great article <a href="http://www.smashingmagazine.com/2010/06/27/dont-do-it-alone" target="_blank">detailing why you should not be working alone</a>.  However, some of us have no choice but to work alone. It could be that you are doing a solo project that no one believes in, or you simply do not have enough funding to get anyone else on board.  Fear not, this article will show you where to go to get some helpful feedback.</p><ol><li><a href="http://stackoverflow.com/" target="_blank">Stack Overflow</a><br /> This is my personal favorite for websites to turn to when you are stuck in a bind.  As a developer on your own you will eventually run into programming problems that you need to get some outside advice on.  Whether it be a MySQL scalability issue or how to parse JSON in PHP.  You are free to post about whatever problem you are having, even newbie questions are often given great responses.  Questions are mostly geared towards programing, but can occasionally touch on server configuration or just plain old HTML questions.</p><p>Best part about the site?  The community is friendly, extremely knowledgeable, and eager to help.  I&#8217;ve asked questions on that site that directly and indirectly led to answers.  I can&#8217;t say enough good things about this site and suggest anyone who is involved in coding to sign up and participate.   You&#8217;ll feel compelled to help others and try to be the first one to get selected as &#8220;Best Answer&#8221; to rack up points.</li><li><a href="http://forrst.com" target="_blank">Forrst</a><br /> Forrst is a site that can be used for networking with like-minded individuals and provide a spot to ask a wide range of questions that usually don&#8217;t pop up on Stack Overflow.  This site isn&#8217;t specifically limited to questions.  You have the option to post code snippets, screenshots of projects, to gain feedback.  You can even post useful links that you think can be beneficial to others.  Your posts can be private or made public, it&#8217;s completely up to you.</p><p>If you are looking for feedback on a blog layout, design mockups, or coding then Forrst can be a great spot to check out.  I do not have much experience here, but from what I&#8217;ve seen thus far the community seems helpful and eager to help.  Getting started on Forrst you may feel a bit isolated, since it has a social aspect to it.  The site requires you to apply for it, but after waiting a week or so then you will recieve your invite code in your mail.  However, if you are helpful and engaged in the site then you should gain quite a few followers and get the feedback your looking for.</li><li><a href="http://www.dribbble.com" target="_blank">Dribbble</a><br /> Dribbble&#8217;s sole focus is to post your designs and try to gain feedback from it&#8217;s userbase.  The site is invite only and is fairly difficult to become a member of without getting lucky or knowing someone already on the site.  I am not a member of Dribbble, but a designer friend is and told me the site is less about feedback and more about showing off your awesomeness.  Egos abound.</p><p>So should Dribbble be on this list of helpful sites?  Yes and no. It&#8217;s still a great spot to post your designs and get feedback, but if you aren&#8217;t up to par then expect to hear about it.  That isn&#8217;t necessarily a bad thing if you are a pro, but amateurs beware.</li><li><a href="http://www.webhostingtalk.com/" target="_blank">Web Hosting Talk</a><br /> Here we have a throwback site that you probably heard of.  Unlike the other sites mention, this is a forum and is geared towards web hosting questions.  Being a developer on your own means making web hosting decisions as well, so this site is a must to learn which places to avoid.</p><p>It may not look the best, but the forum is loaded with people who have lots of experience with multiple web hosts and it even has employees from dozens of hosting companies.  Ask your questions about domain registrars, VPS&#8217;s, cPanel, or Plesk and you&#8217;ll get lots of great feedback</li><li><a href="http://www.webmasterworld.com/" target="_blank">Webmasterworld</a><p style="text-align: left;">Another blast from the past, webmasterworld is the place to go for questions related to your server and SEO.  This is a fantastic place to go to learn about harmful webbots that should be blocked and the latest rumors/news about search engines.  Users on this site are anonymous, and for good reason.</p><p style="text-align: left;">This site is about  asking questions that you probably wouldn&#8217;t ask elsewhere.  For example, if you plan to partake in questionable practices such as <a href="http://en.wikipedia.org/wiki/Cloaking" target="_blank">cloaking content for Googlebot</a>.  The community is helpful and there is a large mix of newbies and experts on the topic of SEO.</p><p>This list is far from perfect and I have a feeling I&#8217;ve missed quite a few useful sites.  Be sure and leave comments to other helpful websites to go to for feedback.</li></ol><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2010/06/web-developers-youre-not-alone/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>jQuery vs Prototype, a newbies perspective</title><link>http://x-pose.org/2010/04/jquery-vs-prototype-a-newbies-perspective/</link> <comments>http://x-pose.org/2010/04/jquery-vs-prototype-a-newbies-perspective/#comments</comments> <pubDate>Tue, 13 Apr 2010 19:43:27 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[jquery]]></category> <category><![CDATA[php]]></category> <category><![CDATA[prototype]]></category><guid isPermaLink="false">http://x-pose.org/?p=154</guid> <description><![CDATA[When I first started to dabble with javascript and ajax, Prototype was the only game in town that was making any headlines. So of course I used prototype with script.aculo.us .  I was able to make some simple stuff, but my coding with Prototype wasn&#8217;t very elegant and it certainly wasn&#8217;t the best way to code things. [...] No related posts.]]></description> <content:encoded><![CDATA[<p>When I first started to dabble with javascript and ajax, <a href="http://www.prototypejs.org/" target="_blank">Prototype</a> was the only game in town that was making any headlines.  So of course I used prototype with <a href="http://script.aculo.us/" target="_blank">script.aculo.us</a> .  I was able to make some simple stuff, but my coding with Prototype wasn&#8217;t very elegant and it certainly wasn&#8217;t the best way to code things.  But you know what, I&#8217;m a javascript newbie and  it worked!</p><p>Over the last few years it seems like Prototype development has slowed down a lot, while <a href="http://www.jquery.com" target="_blank">jQuery </a>is making huge headway.  Every tutorial I see is using jQuery.  So I FINALLY decided to buy a book and learn it.  They are vastly different to say the least.  My prototype code had an awful lot of onclick=&#8221;" kinda stuff inside the HTML, while jQuery let&#8217;s your code appear more transparent and natural.  I love being able to pass my own variables using html attributes.</p><p>I went through a lot of WTF, why isn&#8217;t this working moments during my first attempts at coding using jQuery techniques.  However, overall I love jQuery.  Now my code is optimized, cleaner, and I feel as though I am not limited in what I want to do.  If I can dream it, I can code it with jQuery.  Not a small feat for someone like myself.</p><p>For example, with Prototype I simply didn&#8217;t know how to show a loading gif when an ajax command was in use.  It sounds simple and a lot of you are probably thinking what an idiot.  I turn to jQuery and my first attempt I find that it&#8217;s so simple to achieve.  Not only that but I can easily manipulate form values, check their validity,and pass them along with no problem at all.</p><p>To learn jQuery I completely rewrote all of my javascript code for <a href="http://www.fantasysp.com" target="_blank">FantasySP</a>.  It took me about 2 LONG weeks, but now I feel as though I can code just about anything I want.  My code is a mere 7kb in size now, compared to 49kb in Prototype.  I am actually making reusable functions now and you can too.</p><p>My only quibble with jQuery is that coding an advanced autocomplete function is a huge pain in the ass.  Prototype let me customize it from the backend (PHP), whereas jQuery forced me to use JSON and adding extra javascript code.</p><p>So for those of you who haven&#8217;t used a framework before, or are still using Prototype, give jQuery a try.  You won&#8217;t be disappointed.</p><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2010/04/jquery-vs-prototype-a-newbies-perspective/feed/</wfw:commentRss> <slash:comments>8</slash:comments> </item> <item><title>How to restart Apache with PHP</title><link>http://x-pose.org/2010/01/how-to-restart-apache-with-php/</link> <comments>http://x-pose.org/2010/01/how-to-restart-apache-with-php/#comments</comments> <pubDate>Wed, 13 Jan 2010 16:21:43 +0000</pubDate> <dc:creator>brant</dc:creator> <category><![CDATA[apache]]></category> <category><![CDATA[php]]></category> <category><![CDATA[tricks]]></category><guid isPermaLink="false">http://x-pose.org/?p=10</guid> <description><![CDATA[If you ever need to restart Apache via PHP, you&#8217;ll notice that the &#8220;passthru&#8221; command doesn&#8217;t quite work out like you thought it would. For those of you who have cpanel and WHM installed, this will be an easy solution.  cpanelmatt at the cpanel forums created an XML-API PHP class to be able to handle [...] No related posts.]]></description> <content:encoded><![CDATA[<p>If you ever need to restart Apache via PHP, you&#8217;ll notice that the &#8220;passthru&#8221; command doesn&#8217;t quite work out like you thought it would.  For those of you who have cpanel and WHM installed, this will be an easy solution.  <a href="http://forums.cpanel.net/f42/xml-api-php-class-version-1-0-a-136449.html" target="_blank">cpanelmatt at the cpanel forums</a> created an XML-API PHP class to be able to handle situations like this.</p><p>First download the <a href="http://sdk.cpanel.net/utils/xmlapi_php_v1.0.tar.gz" target="_blank">XML-API PHP class</a>.</p><p>Next, follow the code example below:</p><pre name="code" class="php">include("xmlapi.php");

$ip = "127.0.0.1";
$root_pass = "somepass";

$xmlapi = new xmlapi($ip);
$xmlapi-&gt;password_auth("root",$root_pass);

$xmlapi-&gt;set_debug(1);

print $xmlapi-&gt;restartsrv('httpd');</pre><p>No related posts.</p>]]></content:encoded> <wfw:commentRss>http://x-pose.org/2010/01/how-to-restart-apache-with-php/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced
Database Caching 1/41 queries in 0.024 seconds using disk: basic
Object Caching 1375/1455 objects using disk: basic

Served from: x-pose.org @ 2012-02-05 01:30:13 -->
