<?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>SoftLayer Blog &#187; developer</title>
	<atom:link href="http://blog.softlayer.com/tag/developer/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.softlayer.com</link>
	<description>A Behind the Scenes Look at the Best Hosting Provider in the World</description>
	<lastBuildDate>Wed, 15 May 2013 15:33:34 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4.1</generator>
		<item>
		<title>Plivo: Tech Partner Spotlight</title>
		<link>http://blog.softlayer.com/2013/plivo-tech-partner-spotlight/</link>
		<comments>http://blog.softlayer.com/2013/plivo-tech-partner-spotlight/#comments</comments>
		<pubDate>Wed, 10 Apr 2013 16:00:05 +0000</pubDate>
		<dc:creator>Guest Blog</dc:creator>
				<category><![CDATA[Partner Marketplace]]></category>
		<category><![CDATA[SoftLayer]]></category>
		<category><![CDATA[API]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[functionality]]></category>
		<category><![CDATA[marketplace]]></category>
		<category><![CDATA[partner]]></category>
		<category><![CDATA[SMS]]></category>
		<category><![CDATA[tech partners]]></category>
		<category><![CDATA[telecom]]></category>
		<category><![CDATA[telephony]]></category>
		<category><![CDATA[text]]></category>
		<category><![CDATA[voice]]></category>

		<guid isPermaLink="false">http://blog.softlayer.com/?p=11042</guid>
		<description><![CDATA[We invite each of our featured SoftLayer Tech Marketplace Partners to contribute a guest post to the SoftLayer Blog, and this week, we&#8217;re happy to welcome Mike Lauricella from Plivo. Plivo is an open communications and messaging platform with advanced features, simple APIs, easy management and volume pricing. Company Website: http://www.plivo.com/ Tech Partners Marketplace: http://www.softlayer.com/marketplace/plivo [...]]]></description>
			<content:encoded><![CDATA[<p class="attribution">We invite each of our featured SoftLayer Tech Marketplace Partners to contribute a guest post to the SoftLayer Blog, and this week, we&#8217;re happy to welcome Mike Lauricella from <a href="http://www.plivo.com/">Plivo</a>. Plivo is an open communications and messaging platform with advanced features, simple APIs, easy management and volume pricing.</p>
<div class="yt560"><iframe width="560" height="315" src="http://www.youtube.com/embed/8PAkqRov9mk" frameborder="0" allowfullscreen></iframe></div>
<div class="more-info"><strong>Company Website:</strong> <a href="http://www.plivo.com/">http://www.plivo.com/</a><br />
<strong>Tech Partners Marketplace:</strong> <a href="http://www.softlayer.com/partners/marketplace/plivo">http://www.softlayer.com/marketplace/plivo</a></div>
<h3>Bridging the Gap Between the Web and Telephony</h3>
<p>Businesses face a fundamental challenge in the worlds of telephony and messaging: Those worlds move too slowly, require too much telecom knowledge and take too long to adopt. As a result, developers often forgo phone and SMS functionality in their applications because the learning curves are so steep, and the dated architecture seems like a foreign language. Over the last twenty years, the web has evolved a lot faster than telephony, and that momentum only widens the gap between the &#8220;old&#8221; telecom world and the &#8220;new&#8221; Internet world. <a href="http://www.plivo.com">Plivo</a> was created to bridge that gap and make telephony easy for developers to understand and incorporate into their applications with simple tools and APIs.</p>
<p>I could bore you to tears by describing the ins and outs of what we&#8217;ve learned about telephony and telecom since Plivo was founded, but I&#8217;d rather show off some of the noteworthy ways our customers have incorporated Plivo in their own businesses. After all, seeing those real-world applications is much more revealing about what Plivo does than any description of the nuts and bolts of our platform, right? </p>
<p><strong>Conferencing Solution</strong><br />
The purest use-cases for Plivo are when our customers can simply leverage powerful telephony functionality. A perfect example is a conferencing solution one of our customers created to host large-scale conferences with up to 200 participants. The company integrated the solution into their product and CRM so that sales reps and customers could jump on conference calls quickly. With that integration, the executive management team can keep track of all kinds of information about the calls &#8230; whether they&#8217;re looking to find which calls resulted in closed sales or they just want to see the average duration of a conference call for a given time frame.</p>
<p><strong>Call Tracking</strong><br />
Beyond facilitate conference calls quickly and seamlessly, many businesses have started using Plivo&#8217;s integration to incorporate call tracking statistics in their environments. Call tracking is big business because information about who called what number, when they called, how long they talked and the result of the call (sale, no sale, follow up) can determine whether the appropriate interaction has taken place with prospects or customers.</p>
<p><strong>Two Factor Authentication</strong><br />
With ever-increasing concerns about security online, we&#8217;ve seen a huge uptick in developers that come to Plivo for help with two factor authentication for web services. To ensure that a new site registrant is a real person who has provided a valid phone number (to help cut down on potential fraud), they use Plivo to send text messages with verification codes to those new registrant. </p>
<p><strong>Mass Alert Messaging</strong><br />
Because emergencies can happen at any time, our customers have enlisted Plivo&#8217;s functionality to send out mass alerts via phone calls and SMS messages when their customers are affected by an issue and need to be contacted. These voice and text messages can be sent quickly and easily with our automated tools, and while no one ever wants to deal with an emergency, having a solid communication lifeline provides some peace of mind.  </p>
<p><strong>WebRTC</strong><br />
An emerging new standard for communications is <a href="http://www.webrtc.org/">WebRTC</a> &mdash; open project that enables web browsers with Real-Time Communications (RTC) capabilities. WebRTC make communications a feature of the Web without plugins or complex SIP clients. Plivo already supports WebRTC, and even though the project is relatively young, it&#8217;s already being used in some amazing applications. </p>
<p>These use-cases are only the tip of the iceberg when it comes to how our customers are innovating on our platform, but I hope it helps paint a picture of the kinds of functionality Plivo enables simply and quickly. If you&#8217;ve been itching to incorporate telephony into your application, before you spending hours of your life poring over complex telecom architecture requirements, head over to <a href="http://www.plivo.com">plivo.com</a> to see how easy we can make your life. We offer free developer accounts where you can start to make calls to other Plivo users and other SIP endpoints immediately, and we&#8217;d love to chat with you about how you can leverage Plivo to make your applications communicate.</p>
<p>If you have any questions, feel free to drop us a note at <a href="mailto:hello@plivo.com">hello@plivo.com</a>, and we&#8217;ll get back to you with answers.</p>
<p>-Mike Lauricella, <a href="http://www.plivo.com/">Plivo</a></p>
<div class="tpm-note">This guest blog series highlights companies in SoftLayer&#8217;s <a href="http://www.softlayer.com/partners/marketplace/index">Technology Partners Marketplace</a>. <br/>These <a href="http://blog.softlayer.com/partner-marketplace/">Partners</a> have built their businesses on the SoftLayer Platform, and we&#8217;re excited for them to tell their stories. New Partners will be added to the Marketplace each month, so stay tuned for many more come.</div>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2013/plivo-tech-partner-spotlight/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Tips and Tricks &#8211; Pure CSS Sticky Footers</title>
		<link>http://blog.softlayer.com/2012/tips-and-tricks-pure-css-sticky-footers/</link>
		<comments>http://blog.softlayer.com/2012/tips-and-tricks-pure-css-sticky-footers/#comments</comments>
		<pubDate>Tue, 06 Nov 2012 20:00:17 +0000</pubDate>
		<dc:creator>Cassandra Wolff</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[browser]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[compatibility]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[div]]></category>
		<category><![CDATA[footer]]></category>
		<category><![CDATA[height]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[sticky footer]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://blog.softlayer.com/?p=9491</guid>
		<description><![CDATA[By now, if you&#8217;ve seen my other blog posts, you know that I&#8217;m fascinated with how much JavaScript has evolved and how much you can do with jQuery these days. I&#8217;m an advocate of working smarter, not harder, and that maxim knows no coding language limits. In this post, I want to share a pure [...]]]></description>
			<content:encoded><![CDATA[<p>By now, if you&#8217;ve seen my other blog posts, you know that I&#8217;m fascinated with how much <a href="http://blog.softlayer.com/?s=javascript">JavaScript</a> has evolved and how much you can do with <a href="http://blog.softlayer.com/?s=jquery">jQuery</a> these days. I&#8217;m an advocate of working smarter, not harder, and that maxim knows no coding language limits. In this post, I want to share a pure CSS solution that allows for &#8220;sticky&#8221; footers on a web page. In comparing several different techniques to present this functionality, I found that all of the other routes were overkill when it came to processing time and resource usage.</p>
<p>Our objective is simple: Make the footer of our web page stay at the bottom even if the page&#8217;s content area is shorter than the user&#8217;s browser window.</p>
<p>This, by far, is one of my *favorite* things to do. It makes the web layout so much more appealing and creates a very professional feel. I ended up kicking myself the very first time I tried to add this functionality to a project early in my career (ten years ago &#8230; already!?) when I found out just how easy it was. I take solace in knowing that I&#8217;m not alone, though &#8230; A quick search for &#8220;footer stick bottom&#8221; still yields quite a few results from fellow developers who are wrestling with the same frustrating experience I did. If you&#8217;re in that boat, fear no more! We&#8217;re going to your footers in shape in a snap.</p>
<p>Here&#8217;s a diagram of the problem:</p>
<p><img class="centered" src="http://cdn.softlayer.com/innerlayer/headerfootercss.jpg" alt="CSS Footer"/></p>
<p>Unfortunately, a lot of people try to handle it with setting a fixed height to the content which would push the footer down. This may work when YOU view it, but there are several different browser window heights, resolutions and variables that make this an *extremely* unreliable solution (notice the emphasis on the word &#8220;extremely&#8221; &#8230; this basically means &#8220;don&#8217;t do it&#8221;).</p>
<p>We need a dynamic solution that is able to adapt on the fly to the height of a user&#8217;s browser window regardless if the resize it, have Firebug open, use a unique resolution or just have a really, really weird browser!</p>
<p>Let&#8217;s take a look at what the end results should look like:</p>
<p><img class="centered" src="http://cdn.softlayer.com/innerlayer/headerfootercss2.jpg" alt="CSS Footer"/></p>
<p>To make this happen, let&#8217;s get our HTML structure in place first:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;page&quot;</span>&gt;</span>
&nbsp;
      <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;header&quot;</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
&nbsp;
      <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;main&quot;</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
&nbsp;
      <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;footer&quot;</span>&gt;</span> <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
&nbsp;
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></div></div>

<p>It&#8217;s pretty simple so far &#8230; Just a skeleton of a web page. The <code>page</code> div contains ALL elements and is immediately below the <body> tags in the page code hierarchy. The <code>header</code> div is going to be our top content, the <code>main</code> div will include all of our content, and the <code>footer</code> div is all of our copyrights and footer links.</p>
<p>Let&#8217;s start by coding the CSS for the full page:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;">Html<span style="color: #00AA00;">,</span> body <span style="color: #00AA00;">&#123;</span>
      Padding<span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
      Margin<span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
      Height<span style="color: #00AA00;">:</span> <span style="color: #933;">100%</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div>

<p>Adding a 100% height allows us to set the height of the <code>main</code> div later. The height of a div can only be as tall as the parent element encasing it. Now let&#8217;s see how the rest of our ids are styled:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#page</span> <span style="color: #00AA00;">&#123;</span>
      Min-<span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">100%</span><span style="color: #00AA00;">;</span>
      <span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">relative</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#main</span> <span style="color: #00AA00;">&#123;</span>
      Padding-<span style="color: #000000; font-weight: bold;">bottom</span><span style="color: #00AA00;">:</span> <span style="color: #933;">75px</span><span style="color: #00AA00;">;</span>   <span style="color: #808080; font-style: italic;">/* This value is the height of your footer */</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #cc00cc;">#footer</span> <span style="color: #00AA00;">&#123;</span>
      Position<span style="color: #00AA00;">:</span> <span style="color: #993333;">absolute</span><span style="color: #00AA00;">;</span>
      Width<span style="color: #00AA00;">:</span> <span style="color: #933;">100%</span><span style="color: #00AA00;">;</span>
      Bottom<span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
      Height<span style="color: #00AA00;">:</span> <span style="color: #933;">75px</span><span style="color: #00AA00;">;</span>  <span style="color: #808080; font-style: italic;">/* This value is the height of your footer */</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div>

<p>These rules position the footer &#8220;absolutely&#8221; at the bottom of the page, and because we set <code>#page</code> to <code>min-height: 100%</code>, it ensures that <code>#main</code> is exactly the height of the browser&#8217;s viewing space. One of the best things about this little trick is that it&#8217;s compliant with all major current browsers &mdash; including Firefox, Chrome, Safari *AND* Internet Explorer (after a little tweak). For Internet Explorer to not throw a fit, we need concede that IE doesn&#8217;t recognize <code>min-height</code> as a valid property, so we have to add <code>Height: 100%;</code> to <code>#page</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#page</span> <span style="color: #00AA00;">&#123;</span>
      Min-<span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">100%</span><span style="color: #00AA00;">;</span>  <span style="color: #808080; font-style: italic;">/* for all other browsers */</span>
      <span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">100%</span><span style="color: #00AA00;">;</span>  <span style="color: #808080; font-style: italic;">/* for IE */</span>
      <span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span><span style="color: #993333;">relative</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div>

<p>If the user does not have a modern, popular browser, it&#8217;s still okay! Though their old browser won&#8217;t detect the magic we&#8217;ve done here, it&#8217;ll fail gracefully, and the footer will be positioned directly under the content, as it would have been without our little CSS trick.</p>
<p>I can&#8217;t finish this blog without mentioning my FAVORITE perk of this trick: Should you not have a specially designed mobile version of your site, this trick even works on smart phones!</p>
<p>-Cassandra</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2012/tips-and-tricks-pure-css-sticky-footers/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>Tips and Tricks &#8211; jQuery Lazy Load Plugin</title>
		<link>http://blog.softlayer.com/2012/tips-and-tricks-jquery-lazy-load-plugin/</link>
		<comments>http://blog.softlayer.com/2012/tips-and-tricks-jquery-lazy-load-plugin/#comments</comments>
		<pubDate>Wed, 26 Sep 2012 14:00:25 +0000</pubDate>
		<dc:creator>Cassandra Wolff</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[design]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[HMTL]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[loading]]></category>
		<category><![CDATA[optimize]]></category>
		<category><![CDATA[page load]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[tips]]></category>
		<category><![CDATA[tricks]]></category>
		<category><![CDATA[web development]]></category>

		<guid isPermaLink="false">http://blog.softlayer.com/?p=9346</guid>
		<description><![CDATA[In the late 90&#8242;s, web pages presented their information in a relatively structured fashion, with little concern on how &#8220;pretty&#8221; the content looked. To a certain extent, that was a result of available technology and resources being a little more limited, but much of the reason was probably because we had no idea what was [...]]]></description>
			<content:encoded><![CDATA[<p>In the late 90&#8242;s, web pages presented their information in a relatively structured fashion, with little concern on how &#8220;pretty&#8221; the content looked. To a certain extent, that was a result of available technology and resources being a little more limited, but much of the reason was probably because we had no idea what was possible. We&#8217;ve come a long way, my friend. These days, it&#8217;s tough to spend an hour online without coming across a gorgeous web site with huge animations, a pallet of every color possible, full-width backgrounds and high definition detail.</p>
<p>Those sites may be aesthetically pleasing, but they can be a big pain from a developer&#8217;s perspective. </p>
<p>How much load does all of that stuff put on the server every time that web page is visited? As developers, it&#8217;s our job to think about both what the visitor sees AND the visitor&#8217;s experience in seeing it. Even the most beautiful sites will be ignored if a page takes too long to load. We spend hours optimizing every detail so users can fluidly browse without having to wait. It was in one of these optimization sessions that I discovered &#8220;lazy load.&#8221; </p>
<p>To be honest, I wasn&#8217;t too fond of the word &#8220;lazy&#8221; in the name, and I especially wasn&#8217;t fond of having to explain to my boss that *I* wasn&#8217;t being lazy &#8230; The jQuery plugin  is *named* &#8220;<a href="http://www.appelsiini.net/projects/lazyload">Lazy Load</a>.&#8221; Lazy Load effectively allows large pieces of content to stay in the backlog until they&#8217;re needed. To give you an example of what that looks like, let&#8217;s say you have a website with three humungous images, but they&#8217;re all in different locations. Instead of pushing the entire load onto the user when they first land on your page, we can break them up and have them load only when the user goes to view them. We&#8217;re not reducing the size of the web page; we&#8217;re merely helping it work smarter.</p>
<p>Without Lazy Load, a normal web page loads each item when its page is visited. If a website has videos, music, images and some neat user interactivity applications, each of those items will load at the same time: </p>
<p><img class="centered" src="http://cdn.softlayer.com/innerlayer/lazyload.jpg" alt="Lazy Load Illustration"/></p>
<p>If you take into consideration how large each of those items are, you can sense the problem. The user only has so much bandwidth to load these items, and something&#8217;s gotta give. Usually, it means long loading times. We can&#8217;t control how fast each user&#8217;s ISP is, but we <em>can</em> reorder our items and let Lazy Load help us prioritize items and load the page more efficiently.</p>
<p>After we snag <a href="https://raw.github.com/tuupola/jquery_lazyload/master/jquery.lazyload.js">Lazy Load on Github</a> (jquery.lazyload.js), we put our jQuery scripts in the <code>&lt;head&gt;</code> of our page:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script src<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;jquery.js&quot;</span> type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;&lt;/</span>script<span style="color: #339933;">&gt;</span> 
<span style="color: #339933;">&lt;</span>script src<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;jquery.lazyload.js&quot;</span> type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></div></div>

<p>Now that the plugin is available to us, we need to determine what we want to load lazily. Images are probably one of the most bothersome page elements, so let&#8217;s apply Lazy Load to the images we load in the <code>belazy</code> class. In the <code>&lt;head&gt;</code> of your page (or in the footer if you prefer your JavaScript entries there), you&#8217;ll add:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;img.belazy&quot;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">lazyload</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></div></div>

<p>As a result of that function, all image tags with a class of <code>belazy</code> will have Lazy Load run on them. This helps us ensure that we&#8217;re not loading ALL of our images lazily. Now we need to choose which images we want to apply Lazy Load to.</p>
<p>Let&#8217;s say the image tag of the largest image on one of our page looks like this:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;bighonkingimage.png&quot;</span><span style="color: #66cc66;">/</span>&gt;</span></pre></div></div>

<p>To have the lazyload function apply to it, we just have to make a couple tweaks:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;belazy&quot;</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;bighonkingimage.png&quot;</span> data-original<span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;bighonkingimage.png&quot;</span><span style="color: #66cc66;">/</span>&gt;</span></pre></div></div>

<p>We added <code>class="belazy"</code> to trigger the lazyload function, and we added <code>data-original="bighonkingimage.png"</code> to line up with the formatting required by the newest version of Lazy Load (it&#8217;s simply a repeat of the source).</p>
<p>When a user visits our page, bighonkingimage.png will load only when it&#8217;s needed!</p>
<p>Pretty neat, eh?</p>
<p>-Cassandra</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2012/tips-and-tricks-jquery-lazy-load-plugin/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SOAP API Application Development 101</title>
		<link>http://blog.softlayer.com/2011/softlayer-soap-api-application-development-101/</link>
		<comments>http://blog.softlayer.com/2011/softlayer-soap-api-application-development-101/#comments</comments>
		<pubDate>Tue, 23 Aug 2011 13:30:47 +0000</pubDate>
		<dc:creator>Kevin Trachier</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[SoftLayer]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[API]]></category>
		<category><![CDATA[coder]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[HTTP]]></category>
		<category><![CDATA[interface]]></category>
		<category><![CDATA[learn]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[SLDN]]></category>
		<category><![CDATA[soap]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[walkthrough]]></category>

		<guid isPermaLink="false">http://blog.softlayer.com/2011/</guid>
		<description><![CDATA[Simple Object Access Protocol (SOAP) is built on server-to-server remote procedure calls over HTTP. The data is formatted as XML; this means secure, well formatted data will be sent and received from SoftLayer&#8217;s API. This may take a little more time to set up than the REST API but it can be more scalable as [...]]]></description>
			<content:encoded><![CDATA[<p>Simple Object Access Protocol (SOAP) is built on server-to-server remote procedure calls over HTTP. The data is formatted as XML; this means secure, well formatted data will be sent and received from SoftLayer&#8217;s API. This may take a little more time to set up than the REST API but it can be more scalable as you programmatically interface with it. SOAP&#8217;s ability to tunnel through existing protocols such as HTTP and innate ability to work in an object-oriented structure make it an excellent choice for interaction with the SoftLayer API.</p>
<p>This post gets pretty technical and detailed, so it might not appeal to our entire audience. If you&#8217;ve always wondered how to get started with SOAP API development, this post might be a good jumping-off point.</p>
<p><span id="more-3919"></span></p>
<p><strong>Authentication</strong><br />
Before you start playing with the SoftLayer SOAP API, you will need to find your API authentication token. Go into your portal account, and click the &#8220;Manage API Access&#8221; link from the API page under the Support tab. At the bottom of the page you&#8217;ll see a drop down menu for you to &#8220;Generate a new API access key&#8221; for a user. After you select a user and click the &#8220;Generate API Key&#8221; button, you will see your username and your API key. Copy this API key, as you&#8217;ll need it to send commands to SoftLayer&#8217;s API.</p>
<p><strong>PHP</strong><br />
In PHP 5.0+ there are built in classes to deal with SOAP calls. This allows us to quickly create an object oriented, server side application for handling SOAP requests to SoftLayer&#8217;s API. This tutorial is going to focus on PHP 5.1+ as the server side language for making SOAP function calls. If you haven’t already, you will need to install the soap client for php, <a href="http://www.php.net/manual/en/soap.installation.php">here</a> is a link with directions.</p>
<h3>Model View Controller </h3>
<p>Model-View-Controller or MVC is a software architecture commonly used in web development. This architecture simply provides separation between a data abstraction layer (model), the business logic (controller), and the resulting output and user interface (view). Below, I will describe each part of our MVC &#8220;hello world&#8221; web application and dissect the code so that you can understand each line.</p>
<p>To keep this entry a little smaller, the code snippits I reference will be posted on their own page: <a href="http://blog.softlayer.com/soap-api-code-examples/">SOAP API Code Examples</a>. Protip: Open the code snippit page in another window so you can seamlessly jump between this page and the code it&#8217;s referencing.</p>
<p><strong>Model</strong><br />
The first entry on the API Code Examples page is &#8220;The Call Class,&#8221; a custom class for making basic SOAP calls to SoftLayer&#8217;s API. This class represents our model: The SOAP API Call. When building a model, you need to think about what properties that model has, for instance, a model of a person might have the properties: first name, height, weight, etc. Once you have properties, you need to create methods that use those properties. </p>
<p>Methods are verbs; they describe what a model can do. Our &#8220;person&#8221; model might have the methods: run, walk, stand, etc. Models need to be self-sustaining, that means we need to be able to set and get a property from multiple places without them getting jumbled up, so each model will have a &#8220;set&#8221; and &#8220;get&#8221; method for each of its properties. A model is a template for an object, and when you store a model in a variable you are instantiating an instance of that model, and the variable is the instantiated object. </p>
<ul>
<li><strong>Properties and Permissions</strong><br />
Our model has these properties: username, password (apiKey), service, method, initialization parameters, the service&#8217;s WSDL, SoftLayer&#8217;s type namespace, the SOAP API client object, options for instantiating that client, and a response value. The SOAP API client object is built into php 5.1+ (take a look at the “PHP” section above), as such, our model will instantiate a SOAP API object and use it to communicate to SoftLayer&#8217;s SOAP API. </p>
<p>Each of our methods and properties are declared with certain permissions (protected, private, or public), these set whether or not outside functions or extended classes can have access to these properties or methods. I &#8220;set&#8221; things using the &#8220;<code>$this</code>&#8221; variable, <code>$this</code> represents the immediate class that the method belongs to.  I also use the arrow operator (<code>-></code>), which accesses a property or method (to the right of the arrow) that belongs to <code>$this</code> (or anything to the left of the arrow). I gave as many of the properties default values as I could, this way when we instantiate our model we have a fully fleshed out object without much work, this comes in handy if you are instantiating many different objects at once.</li>
<li><strong>Methods</strong><br />
I like to separate my methods into 4 different groups: Constructors, Actions, Sets, and Gets:</p>
<ul>
<li><strong>Sets and Gets</strong><br />
Sets and Gets simply provide a place within the model to set and get properties of that model. This is a standard of object oriented programing and provides the model with a good bit of scalability. Rather than accessing the property itself, always refer to the function that gets or sets the property. This can prevent you from accidentally changing value of the property when you are trying to access it. Lines 99 to the end of our call are where the sets and gets are located.<br/><br/></li>
<li><strong>Constructors</strong><br />
Constructors are methods dedicated to setting options in the model, lines 23-62 of the call model are our constructors. The beauty of these three functions is that they can be copied into any model to perform the same function, just make sure you keep to the <a href="http://framework.zend.com/manual/en/coding-standard.overview.html">Zend coding standards</a>.</p>
<p>First, let’s take a look at the <code>__construct</code> method on line 24. This is a special <a href="http://php.net/manual/en/language.oop5.magic.php">magic php method</a> that always runs immediately when the model is instantiated. We don’t want to actually process anything in this method because if we want to use the default object we will not be passing any options to it, and unnecessary processing will slow response times. We pass the options in an array called <code>Setup</code>, notice that I am using <a href="http://www.php.net/manual/en/language.oop5.typehinting.php">type hinting</a> and <a href="http://php.net/manual/en/functions.arguments.php">default parameters</a> when declaring the function, this way I don’t have to pass anything to model when instantiating. If values were passed in the <code>$Setup</code> variable (which must be an array), then we will run the “<code>setOptions”</code> method.</p>
<p>Now take a look at the <code>setOptions</code> method on line 31. This method will search the model for a set method which matches the option passed in the <code>$setup</code> variable using the built in <code>get_class_methods</code> <a href="http://us.php.net/manual/en/function.get-class-methods.php">function</a>. It then passes the value and name of that option to another magic method, the <code>__set</code> method.</p>
<p>Finally, let’s take a look at the <code>__set</code> and <code>__get</code> methods on lines 45 and 54. These methods are used to create a kind of shorthand access to properties within the model, this is called overloading. Overloading allows the controller to access properties quicker and more efficiently.<br/></li>
<li><strong>Actions</strong><br />
Actions are the traditional verbs that I mentioned earlier; they are the “run”, “walk”, “jump”, and “climb” of our person model. We have 2 actions in our model, the response action and the createHeaders action.</p>
<p><strong>The createHeaders action</strong> creates the SOAP headers that we will pass to the SoftLayer API; this is the most complicated method in the model. Understanding how SOAP is formed and how to get the correct output from php is the key to access SoftLayer’s API. On line 77, you will see an array called Headers, this will store the headers that we are about to make so that we can easily pass them along to the API Client.</p>
<p>First we will need to create the initial headers to communicate with SoftLayer’s API. This is what they should look like:</p>

<div class="wp_syntax"><div class="code"><pre class="nolang" style="font-family:monospace;">&lt;authenticate xsi:type=&quot;slt:authenticate&quot; xmlns:slt=&quot;http://api.service.softlayer.com/soap/v3/SLTypes/&quot;&gt;
    &lt;username xsi:type=&quot;xsd:string&quot;&gt;MY_USERNAME&lt;/username&gt;
    &lt;apiKey xsi:type=&quot;xsd:string&quot;&gt;MY_API_ACCESS_KEY&lt;/apiKey&gt;
&lt;/authenticate&gt;
&lt;SoftLayer_API_METHODInitParameters xsi:type=&quot;v3:SoftLayer_API_METHODInitParameters&quot; &gt;
    &lt;id xsi:type=&quot;xsd:int&quot;&gt;INIT_PERAMETER&lt;/id&gt;
&lt;/SoftLayer_API_METHODInitParameters&gt;</pre></div></div>

<p>In order to build this we will need a few saved properties from our instantiated object: our api username, api key, the service, initialization parameters, and the SoftLayer API type namespace. The api username and key will need to be set by the controller, or you can add in yours to the model to use as a default. I will store mine in a separate file and include it in the controller, but on a production server you might want to store this info in a database and create a &#8220;user&#8221; model. </p>
<p>First, we instantiate SoapVar objects for each authentication node that we need. Then we store the SoapVar objects in an array and create a new SoapVar object for the &#8220;<code>authenticate</code>&#8221; node. The data for the &#8220;<code>authenticate</code>&#8221; node is the array, and the encoding is type <code>SOAP_ENC_OBJECT</code>. Understanding how to nest SoapVar objects is the key to creating well formed SOAP in PHP. Finally, we instantiate a new SoapHeader object and append that to the Headers array. The second header we create and add to the Headers array is for initialization parameters. These are needed to run certain methods within SoftLayer’s API; they essentially identify objects within your account. The final command in this method (<code>__setSoapHeaders</code>) is the magical PHP method that saves the headers into our SoapClient object. Now take a look at how I access the method; because I have stored the SoapClient object as a property of the current class I can use the arrow operator to access methods of that class through the <code>$_client</code> property of our class, or the <code>getClient()</code> method of our class which returns the client.</p>
<p><strong>The Response method</strong> is the action which actually contacts SoftLayer’s API and sends our SOAP request. Take a look at how I tell PHP that the string stored in our <code>$_method</code> property is actually a method of our $_client property by adding parenthesis to the end of the <code>$Method</code> variable on line 71.</li>
</ul>
</li>
</ul>
<p><strong>View</strong><br />
The view is what the user interprets, this is where we present our information and create a basic layout for the web page. Take a look at &#8220;The View&#8221; section on <a href="http://blog.softlayer.com/soap-api-code-examples/">SOAP API Code Examples</a>. Here I create a basic webpage layout, display output information from the controller, and create a form for sending requests to the controller. Notice that the View is a mixture of HTML and PHP, so make sure to name it view.php that way the server knows to process the php before sending it to the client. </p>
<p><strong>Controller</strong><br />
The controller separates user interaction from business logic. It accepts information from the user and formats it for the model. It also receives information from the model and sends it to the view. Take a look at &#8220;The Controller&#8221; section on <a href="http://blog.softlayer.com/soap-api-code-examples/">SOAP API Code Examples</a>. I accept variables posted from the view and store them in an array to send to the model on lines 6-11. I then instantiate the <code>$Call</code> object with the parameters specified in the <code>$Setup</code> array, and store the response from the Response method as <code>$Result</code> in line 17 for use by the view.</p>
<p><strong>Have Fun!</strong><br />
Although this tutorial seems to cover many different things, this just opens up the basic utilities of SoftLayer&#8217;s API. You should now have a working View to enter information and see what kind of data you will receive. The first service and method you should try is the <code>SoftLayer_Account</code> service and the <code>getObject</code> method. This will return your account information. Then try the <code>SoftLayer_Account</code> service and the <code>getHardware</code> method; it will return all of the information for all of your servers. Take the IDs from those servers and try out the <code>SoftLayer_Hardware_Server</code> service and the <code>getObject</code> method with that <code>id</code> as the <code>Init</code> property. </p>
<p>More examples to try: <a href="http://sldn.softlayer.com/wiki/index.php/SoftLayer_Account">SoftLayer Account</a>, <a href="http://sldn.softlayer.com/wiki/index.php/SoftLayer_Dns_Domain">SoftLayer DNS Domain</a>, <a href="http://sldn.softlayer.com/wiki/index.php/SoftLayer_Hardware_Server">SoftLayer Hardware Server</a>. Once you get the hang of it, try adding <a href="http://sldn.softlayer.com/article/Using-Object-Masks-SoftLayer-API">Object Masks</a> and <a href="http://sldn.softlayer.com/article/Using-Result-Limits-SoftLayer-API">Result Limits</a> to your model.</p>
<p>Have Fun!</p>
<p>-Kevin</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2011/softlayer-soap-api-application-development-101/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Pre-configuration and Upgrades</title>
		<link>http://blog.softlayer.com/2009/pre-configuration-and-upgrades/</link>
		<comments>http://blog.softlayer.com/2009/pre-configuration-and-upgrades/#comments</comments>
		<pubDate>Wed, 01 Jul 2009 19:37:38 +0000</pubDate>
		<dc:creator>Daniel McAloon</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[Infrastructure]]></category>
		<category><![CDATA[SoftLayer]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[assemble]]></category>
		<category><![CDATA[computer]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[hardware]]></category>
		<category><![CDATA[servers]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://theinnerlayer.softlayer.com/?p=792</guid>
		<description><![CDATA[I recently bought a new computer for my wife. Being a developer, and a former hardware engineering student, I opted the buy the parts and assemble the machine ourselves. Actually assembling a computer these days doesn&#8217;t take too long, it&#8217;s the software that really gets you. Windows security updates, driver packs, incompatibilities, inconsistencies, broken websites, [...]]]></description>
			<content:encoded><![CDATA[<p>I recently bought a new computer for my wife.  Being a developer, and a former hardware engineering student, I opted the buy the parts and assemble the machine ourselves.  Actually assembling a computer these days doesn&#8217;t take too long, it&#8217;s the software that really gets you.  Windows security updates, driver packs, incompatibilities, inconsistencies, broken websites, and just plain bad code plagued me for most of the night.  The video card, in particular, has a “known issue” where it just “uh-oh” turns off the monitor when Windows starts.  The issue was first reported in March of 2006, and has yet to be fixed.</p>
<p>This is why SoftLayer always tests and verifies the configurations we offer.  We don&#8217;t make the end user discover on their own that Debian doesn&#8217;t work on Nehalems, we install it first to be sure.  This is also why our order forms prevent customers from ordering pre-installed software that are incompatible with any of the rest of the order.  We want to make sure that customers avoid the frustration of ordering things only to find out later that they don&#8217;t work together.</p>
<p>The problem with desktop computers, especially for people who are particular about their configurations, is that you cannot buy a pre-configured machine where all the parts are exactly what you want.  We attempted to get a computer from Dell, and HP, but neither company would even display all the specifications we were interested in, nevermind actually having the parts we desired.  Usually pre-built systems skimp on important things like the motherboard or the power supply, giving you very little room to upgrade.</p>
<p>At SoftLayer, we don&#8217;t cut corners on our systems, and we ensure that each customer can upgrade as high as they possibly can.   Each machine type can support more RAM and hard drives than the default level, and we normally have spare machines handy at all levels so that once you outgrow the expansion capabilities of your current box, you can move to a new system type.  If you&#8217;re thinking of getting a dedicated server, but you&#8217;re worried about the cost, visit the <a href="”http://outlet.softlayer.com/”">SoftLayer Outlet Store</a> and start small.  We have single-core Pentium Ds in the outlet store, and you can upgrade from there until you&#8217;re running a 24-core Xeon system.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2009/pre-configuration-and-upgrades/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Browser Wars III</title>
		<link>http://blog.softlayer.com/2008/browser-wars-iii/</link>
		<comments>http://blog.softlayer.com/2008/browser-wars-iii/#comments</comments>
		<pubDate>Fri, 26 Sep 2008 13:35:04 +0000</pubDate>
		<dc:creator>Dorian George</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[browsers]]></category>
		<category><![CDATA[Chrome]]></category>
		<category><![CDATA[developer]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[Internet Explorer]]></category>
		<category><![CDATA[Opera]]></category>
		<category><![CDATA[privacy]]></category>
		<category><![CDATA[rendering]]></category>
		<category><![CDATA[Safari]]></category>
		<category><![CDATA[usage]]></category>

		<guid isPermaLink="false">http://theinnerlayer.softlayer.com/?p=245</guid>
		<description><![CDATA[With the recent releases of Google&#8217;s Chrome (Sept 2), Microsoft&#8217;s Internet Explorer 8 Beta 2 (Aug 28), Mozilla&#8217;s Firefox 3 (June 17), not to mention all the legacy browsers many of which are still in use. If you are not a web developer, you are probably thinking why should I care what web browser people [...]]]></description>
			<content:encoded><![CDATA[<p>With the recent releases of <a href="http://www.google.com/chrome">Google&#8217;s Chrome</a> (Sept 2), <a href="http://www.microsoft.com/windows/internet-explorer/beta/default.aspx">Microsoft&#8217;s Internet Explorer 8 Beta 2</a> (Aug 28),  <a href="http://www.mozilla.com/en-US/">Mozilla&#8217;s Firefox 3</a> (June 17), not to mention all the <a href="http://en.wikipedia.org/wiki/List_of_web_browsers">legacy browsers</a> many of which are still in use.  If you are not a web developer, you are probably thinking why should I care what web browser people are using?  Believe me you should, the majority of SoftLayer’s customers run a business and with that have a website which must be displayed on, you guessed it, a web browser.</p>
<p><strong>1. Layout/Rendering Engine</strong><br />
This could be one of the biggest differences between the browsers, a <a href="http://en.wikipedia.org/wiki/Layout_engine">layout/rendering engine</a> is what the browser uses to parse the html and display your web pages. Although there are numerous specifications for various types of content (HTML, XHTML, images, etc..)  each of the engines seem to render it slightly different based on their interpretation of the specification documents.</p>
<p>But don’t take my word for it go check the <a href="http://www.webstandards.org/action/acid2/">ACID website</a> or the <a href="http://acid2.wikispaces.com/">screenshots</a> of the ACID tests in different web browsers.  </p>
<p><strong>2. Your Privacy</strong><br />
Most of the front runners in the browser wars are sending your usage and machine specifications back to the mother ship. What they are doing with the information once they get it, who knows.  But, with Google being the front runner in search and ads, with the addition of Google Chrome, they pretty much can monitor all web usage for anyone using their product.  Please get out <a href="http://en.wikipedia.org/wiki/Tin_foil_hat">the tin foil hats</a> now ☺</p>
<p><strong>3. Usage / Front Runner</strong><br />
Based off most of the <a href="http://www.w3schools.com/browsers/browsers_stats.asp">statistics</a> I have seen IE 6, IE 7, Firefox 2, Firefox 3 are the front runners, with a few stragglers using Safari and Opera.  But I bet things will be changing and Chrome will be coming up in usage ranks over the next few months as well as IE 8 once it is released from Beta.</p>
<p>At SoftLayer we test on all the major front runners in the browser wars for our web presence. I will be grabbing the popcorn and watching the show, things are about to get hectic in this area.  Whether it is good or bad; users are getting more options in the browser market.</p>
<p>-Dorian</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.softlayer.com/2008/browser-wars-iii/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
