<?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>thePENTHOUSEPROJECT</title>
	<atom:link href="http://thepenthouseproject.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://thepenthouseproject.com</link>
	<description>Home of Karin van Soest and Adrian le Bas, and a bunch of cool graphic and code things</description>
	<lastBuildDate>Wed, 18 Apr 2012 11:41:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Celebrating 200 facebook fans</title>
		<link>http://thepenthouseproject.com/gossip/celebrating-200-facebook-fans/</link>
		<comments>http://thepenthouseproject.com/gossip/celebrating-200-facebook-fans/#comments</comments>
		<pubDate>Wed, 18 Apr 2012 11:38:39 +0000</pubDate>
		<dc:creator>karin</dc:creator>
				<category><![CDATA[Gossip]]></category>

		<guid isPermaLink="false">http://thepenthouseproject.com/?p=258</guid>
		<description><![CDATA[Facebook love I felt so honored by huge support on facebook since we launched, I wanted to give something back. So in true PENTHOUSE style I give you all a big thumbs up!]]></description>
			<content:encoded><![CDATA[<img src="http://thepenthouseproject.com/assets/200Likes_transparent_ps1.png" alt="" title="200 Facebook Fans thePENTHOUSEPROJECT" class="alignnone size-full wp-image-261" />
<h2>Facebook love</h2>
<p>I felt so honored by huge support on facebook since we launched, I wanted to give something back. So in true PENTHOUSE style I give you all a big thumbs up!</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=258&amp;md5=dc23deb38121ed5fc301373c3f279463" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/gossip/celebrating-200-facebook-fans/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fgossip%2Fcelebrating-200-facebook-fans%2F&amp;language=en_GB&amp;category=text&amp;title=Celebrating+200+facebook+fans&amp;description=Facebook+love+I+felt+so+honored+by+huge+support+on+facebook+since+we+launched%2C+I+wanted+to+give+something+back.+So+in+true+PENTHOUSE+style+I+give+you+all+a...&amp;tags=blog" type="text/html" />
	</item>
		<item>
		<title>Cinemagraph tutorial&#8230; the animated gif renaissance of 2012</title>
		<link>http://thepenthouseproject.com/design/cinemagraph-tutorial/</link>
		<comments>http://thepenthouseproject.com/design/cinemagraph-tutorial/#comments</comments>
		<pubDate>Tue, 27 Mar 2012 13:20:45 +0000</pubDate>
		<dc:creator>karin</dc:creator>
				<category><![CDATA[Design]]></category>

		<guid isPermaLink="false">http://thepenthouseproject.com/?p=215</guid>
		<description><![CDATA[The birth of the animated gif Gifs have been around since the 1980&#8242;s and have seen many evolutions. And with the surge of the social content, the animated gif is serving a very viral position. Animated gifs are the new youtube video&#8230; on Tumblr. Its the jazz of the internet, everyone is talking, sharing, posting&#8230;...  <a href="http://thepenthouseproject.com/design/cinemagraph-tutorial/" title="Read Cinemagraph tutorial&#8230; the animated gif renaissance of 2012">Read more &#187;</a>]]></description>
			<content:encoded><![CDATA[<img src="http://thepenthouseproject.com/assets/cinomagraph_04_c.gif" alt="" title="cinomagraph_04_c" class="alignnone size-full wp-image-242" />
<h2>The birth of the animated gif</h2>
<p>Gifs have been around since the 1980&#8242;s and have seen many evolutions. And with the surge of the social content, the animated gif is serving a very viral position. Animated gifs are the new youtube video&#8230; on Tumblr. Its the jazz of the internet, everyone is talking, sharing, posting&#8230; And with every faze comes a fashion, today it is the cinemagraph. </p>
<h2>&#8216;Cinemagraphs&#8217;</h2>
<img src="http://thepenthouseproject.com/assets/taxi.gif" alt="" title="taxi" />
<p class="center_span">  &#8220;something more than a photo but less than a video.&#8221; </p>
<p>These &#8216;cinemagraphs&#8217; have been coined by Jamie Beck and Kevin Burg as the in between photography and cinema. It is yet another use of animated gifs, there are many more, but it is the one I will be explaining how to make here.
<div><iframe width="560" height="315" src="http://www.youtube.com/embed/vuxKb5mxM8g" frameborder="0" allowfullscreen></iframe></div>
<h2>So how do I make my own &#8216;cinemagraph&#8217;?</h2>
<p>Well, there are a number of steps to making a &#8216;cinemagraph&#8217;, in this cinemagraph tutorial I will walk through it in simple steps.<br />
<h3>STEP 1 (camera, lights, action)</h3>
<p>The best result comes from the best footage, you can use your favorite scene in a movie, or you can take your own. Use the highest quality camera you can get your hands on, many of the small compact cameras have HD video options. Use a tripod, or the nearest table, your aim is have to get everything still except the one detail that will be the focus of the image. Keeping it away from the edge, and just a very small area will help when making the gif. The file size only increases with pixels that change per frame. </p>
<h3>STEP 2 &#8211; import the footage</h3>
<p>You can use a number of ways to import your footage and prepare it for photoshop. Formats such as .mov you can actually import it straight into into photoshop, open the animation tab in windows>motion (or if you are trying out the <a href="http://thepenthouseproject.com/gossip/photoshop-cs6-beta-im-converted/" title="photoshop CS6 review" target="_blank">Photoshop CS6 beta</a>, it will automatically open it in timeline) and select the part you want. Then there is after effects or final cut pro, so wichever way you find is best, just make sure you select as few frames as possible with the least loss of quality. Edit to your hearts content and export or render your selection.</p>
<p>Take a look at <a href="http://www.creativeconfab.co.uk/inspiration/the-animated-photos-of-jamie-beck-kevin-burg/" title="Jamie Beck and Kevin Burg's cinemagraphs" target="_blank">Jamie Beck and Kevin Burg&#8217;s images</a>, in each one there is mostly one small looping movement. Hair blowing in the wind, just eyes moving. The beauty is in the mood they create with something so simple.</p>
<h3>STEP 3 &#8211; Import frames as layers in Photoshop</h3>
<p>Use the import frames as layers option in file>import, in PS CS6 it automatically loads your footage as separate frames in the timeline. Now you can really fine tune your selection, delete all the unnecessary frames. You can duplicate your frames and then reverse the order to get an infinite loop, in the pop up menu in the right corner of the timeline tab.</p>
<img src="http://thepenthouseproject.com/assets/screenshot_copyframes.png" alt="" title="screenshot_copyframes" class="alignnone size-full wp-image-221" />
<p>You can set the pause between each frame, you may want to do this to create expectation in the images, to get people guessing what will move in the image.</p>
<h3>STEP 4 &#8211; The still</h3>
<p>The trick behind the success of the cinemagraphs is that most of the image is usually a still. The still image you can edit, adjust, basically do what you like with it, and then mask the parts that move away. So copy and paste the frame you want to use as the still at the top of your layers. Create an adjustment mask, use the brush to erase (in black) using the brush tool the parts of your footage that move (use white to un-erase). Play the animation often to see if there are parts you need to erase further, or less. Make sure that it blends well with the bits that don&#8217;t move.</p>
<img src="http://thepenthouseproject.com/assets/screenshot_masking.png" alt="" title="screenshot_masking" class="alignnone size-full wp-image-224" />
<h3>STEP 5 &#8211; Optimisation</h3>
<p>You can desaturate the whole, or parts, of the image to reduce the amount of colors. Basically a gif can have a max of 256 colors per frame of the animation, so reducing the saturation will create less color information and a better result.</p>
<p>I decided to desaturate the whole image, and mask back just the beam of light and the reflection in the window. </p>
<img src="http://thepenthouseproject.com/assets/screenshot_desaturate.png" alt="" title="screenshot_desaturate" class="alignnone size-full wp-image-230" />
<p>You can also crop and resize your image to reduce the file size. PS CS6 has a great feature that from Lightroom, pretty neat!</p>
<h3>STEP 6 &#8211; Save for Web (the gif)</h3>
<p>The final step is to save your sequence as an animated gif image. Select file>save for web and select gif as the format. I have circled some of the important parts you need to be aware of, I brought the file size below 1mb by reducing the size of my image to 360px wide. That is the limit file size that Tumblr will allow you upload, so it is a good allround standard depending on what the use of your masterpiece is&#8230; The final setting I set was to loop my gif indefinitely by selecting forever from the selection. You can set it to play once or set a custom number.</p>
<img src="http://thepenthouseproject.com/assets/screenshot_savinggif.png" alt="" title="screenshot_savinggif" class="alignnone size-full wp-image-232" />
<p>And there it is, your very own animated gif you can share with the world&#8230; <img src='http://thepenthouseproject.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>p.s. don&#8217;t forget to #tag it</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=215&amp;md5=93adb64d8253b9224a49280c8246d2cc" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/design/cinemagraph-tutorial/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fdesign%2Fcinemagraph-tutorial%2F&amp;language=en_GB&amp;category=text&amp;title=Cinemagraph+tutorial%26%238230%3B+the+animated+gif+renaissance+of+2012&amp;description=The+birth+of+the+animated+gif+Gifs+have+been+around+since+the+1980%26%238242%3Bs+and+have+seen+many+evolutions.+And+with+the+surge+of+the+social+content%2C+the+animated+gif+is...&amp;tags=blog" type="text/html" />
	</item>
		<item>
		<title>Photoshop CS6 (beta) I&#8217;m converted!</title>
		<link>http://thepenthouseproject.com/gossip/photoshop-cs6-beta-im-converted/</link>
		<comments>http://thepenthouseproject.com/gossip/photoshop-cs6-beta-im-converted/#comments</comments>
		<pubDate>Fri, 23 Mar 2012 04:28:29 +0000</pubDate>
		<dc:creator>karin</dc:creator>
				<category><![CDATA[Gossip]]></category>
		<category><![CDATA[photoshop]]></category>
		<category><![CDATA[review]]></category>

		<guid isPermaLink="false">http://thepenthouseproject.com/?p=201</guid>
		<description><![CDATA[&#160;&#160;&#160;&#160;&#160;So anyone who hasn&#8217;t done so already, download the new Photoshop CS6 beta version, FOR FREE! http://labs.adobe.com/technologies/photoshopcs6/ &#160;&#160;&#160;&#160;&#160;OK so with that done let me introduce you to the first photoshop I am extremely excited about using! I am by nature an Illustrator user. The clean solid style with the relative ease of creating intricate and...  <a href="http://thepenthouseproject.com/gossip/photoshop-cs6-beta-im-converted/" title="Read Photoshop CS6 (beta) I&#8217;m converted!">Read more &#187;</a>]]></description>
			<content:encoded><![CDATA[<a href="http://thepenthouseproject.com/assets/PhotoshopCS6.png"><img src="http://thepenthouseproject.com/assets/PhotoshopCS6.png" alt="" title="PhotoshopCS6" class="center_span" /></a>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;So anyone who hasn&#8217;t done so already, download the new Photoshop CS6 beta version, FOR FREE! <a href="http://labs.adobe.com/technologies/photoshopcs6/" title="Photoshop CS6 beta download" target="_blank">http://labs.adobe.com/technologies/photoshopcs6/</a></p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;OK so with that done let me introduce you to the first photoshop I am extremely excited about using! I am by nature an Illustrator user. The clean solid style with the relative ease of creating intricate and simple shapes by just cutting adding and editing vector shapes has always appealed to me&#8230; I make everything from logos to websites using it, and I have been happy doing so&#8230; until now that is&#8230; </p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I just downloaded the beta, and knowing very little of 3D made an extrusion of thePENTHOUSEPROJECT logo, with a click of a button! Whoa&#8230; this is pretty epic&#8230; along the way I noticed (along the super clean and dark interface) some very illustrator looking buttons. Align, pathfinder, character styles&#8230; Whoa, this is getting too much. Yes I am rambling. But if you are skeptical, just try it!</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;As I was reading a review about it by <a href="http://gizmodo.com/5895424/photoshop-cs6-is-the-best-photoshop-release-in-recent-memory" title="Gizmodo - Photoshop CS6 review" target="_blank">Gizmodo</a>. I became more and more enthusiastic. Its all about improving the basics he says: &#8216;concentrate on the basics, that 10 per cent that does the 90 per cent of the work&#8217;. Not just another add-it-on-because-someone-someday-will-use-it-sometime&#8230; no! this is improving stuff we&#8217;re all gonna use, everyday! Stuff we use from other programs, like the non-destructive crop feature in Lightroom, and an epic new RAW algorithm&#8230; Booyeah! Bring on the goodness!</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Well I only just opened the program and now I&#8217;m spilling my guts about it, so just try it out and see the awesomeness for yourselves&#8230; happy Photoshoping!</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=201&amp;md5=aeb529a6d22cb74865157d39f3bbc9b9" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/gossip/photoshop-cs6-beta-im-converted/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fgossip%2Fphotoshop-cs6-beta-im-converted%2F&amp;language=en_GB&amp;category=text&amp;title=Photoshop+CS6+%28beta%29+I%26%238217%3Bm+converted%21&amp;description=%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3BSo+anyone+who+hasn%26%238217%3Bt+done+so+already%2C+download+the+new+Photoshop+CS6+beta+version%2C+FOR+FREE%21+http%3A%2F%2Flabs.adobe.com%2Ftechnologies%2Fphotoshopcs6%2F+%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3BOK+so+with+that+done+let+me+introduce+you+to+the+first+photoshop...&amp;tags=photoshop%2Creview%2Cblog" type="text/html" />
	</item>
		<item>
		<title>Cause and effect &#8211; responsive web design</title>
		<link>http://thepenthouseproject.com/gossip/cause-and-effect-responsive-web-design/</link>
		<comments>http://thepenthouseproject.com/gossip/cause-and-effect-responsive-web-design/#comments</comments>
		<pubDate>Tue, 20 Mar 2012 02:34:47 +0000</pubDate>
		<dc:creator>karin</dc:creator>
				<category><![CDATA[Gossip]]></category>
		<category><![CDATA[devices]]></category>
		<category><![CDATA[flexible design]]></category>
		<category><![CDATA[media queries]]></category>
		<category><![CDATA[multiple devices]]></category>
		<category><![CDATA[responsive]]></category>
		<category><![CDATA[responsive design]]></category>
		<category><![CDATA[responsive grids]]></category>
		<category><![CDATA[responsive web design]]></category>

		<guid isPermaLink="false">http://thepenthouseproject.com/?p=167</guid>
		<description><![CDATA[Responsive web design&#8230; Well its a hot topic now that there are new devices coming out every day. And with each new device comes a different resolution, a different dimension. That beautiful website you just designed looks great on your desktop, but on your iPhone&#8230; well its all scrambled! &#8216;What can I do!? I hear...  <a href="http://thepenthouseproject.com/gossip/cause-and-effect-responsive-web-design/" title="Read Cause and effect &#8211; responsive web design">Read more &#187;</a>]]></description>
			<content:encoded><![CDATA[<img src="http://thepenthouseproject.com/assets/responsive_webdesign1.png" alt="responsive web design" title="responsive web design by thePHP"class="alignnone size-full wp-image-187" />
<p class="center_span">Responsive web design&#8230; Well its a hot topic now that there are new devices coming out every day. And with each new device comes a different resolution, a different dimension. That beautiful website you just designed looks great on your desktop, but on your iPhone&#8230; well its all scrambled! &#8216;What can I do!? I hear you saying&#8230;. Respond says I!</p>
<h2>Media Queries</h2>
<p>The first response to multiple devices was <a href="http://mediaqueri.es/" title="Media Queries" target="_blank">Media Queries</a>, it checks the specifications you give it and allows you to add CSS styling for that specific instance. First brought in as media types in CSS2, it wasn&#8217;t really adopted on a wide scale, but CSS3 took it to a whole new level with Media Queries, rather than just looking for a type of device they look at the capability of the device. And this lets you do all kinds of things.</p>
<p>For example you can check if someone is holding their phone upright, or landscape&#8230; </p>
<p>Or what size the browser window is and do stuff like <a href="http://www.orangecoat.com/rip-ie/" title="Responsive website - browser size " target="_blank">http://orangecoat.com/rip-ie/</a></p>
<p>We can change the layout, change what content someone gets to see if they are on a smart phone for example, we could even go so far as to show a unique heading for 165 different instances of our site&#8230;. <a href="http://arleym.com/" title="Arley McBlain's personal site" target="_blank">http://arleym.com/</a></p>
<p><a href="http://responsive.is/niarchive.org/trails/maritime-belfast" title="Responsive Web Site Examples - responsive.is" target="_blank">Responsive.is</a> sports some pretty amazing examples of responsive websites. Look closely at the Maritime Belfast site, it doesn&#8217;t just respond its layout and content&#8230; the map comes to life on a desktop showing you the exact location to each piece of history.
<p>So we can change our site for each device individually.. but what happens when they bring out a new device? Which is like almost every day! We would have to figure out what&#8217;s different on this new device, and then add a new Media Query to each one of our sites?! No way Jose! Thats just ridiculous! Hence the birth of the fluid website&#8230;</p>
<h2>Fully Responsive &#038; Fluid</h2>
<p>A fluid page will flow to the confines of the browser window. This means paragraphs will rewrap as the browser window is resized. In other words, the website now has the technology to automatically respond to whatever is thrown at it&#8230; not always true of coarse, we the designers and developers are still human after all. But I&#8217;m happy keeping some human errors alive and kicking. Or we may end up like <a href="http://niblett.files.wordpress.com/2011/07/picard_as_locutus.jpg" title="Resistance is Futile" target="_blank">this</a>. Many people believe fluid pages look better on a wider variety of browsers because they are more &#8216;accommodating.&#8217; However, these truly fluid sites give up almost all control over design and layout due to their nature.</p>
<p>Great, so I can use % to place my content. Does that mean I should just forget all I have learned about grids and let the content flow however it likes? Sure you can, if you want to. But it doesn&#8217;t mean you have to! Welcome to responsive grids. There are a few I know of, the <a href="http://cssgrid.net/" title="The 1140 Responsive grid" target="_blank">1140</a> for example, or <a href="http://www.getskeleton.com/" title="Skeleton a responsive boilerplate grid system" target="_blank">skeleton</a>. But one that I would like to go into a little more detail about is the <a href="http://goldengridsystem.com/" title="The Golden Grid for responsive web design" target="_blank">golden grid</a></p>
<h2>The Golden Grid System</h2>
<p>The Golden Grid System by <a href="http://jonikorpi.com/" title="Joni Korpi" target="_blank">Joni Korpi</a> is something I will probably make a whole post about in the future. It is what thePENTHOUSEPROJECT LAB 1.0 is based on. The code is pretty radicle at first glance, but once you get your head around it, it really is quite epic. It is based on a combination of the <a href="http://en.wikipedia.org/wiki/ISO_216" title="European Paper System ISO 216 DIN" target="_blank">European (DIN) paper system</a> and the <a href="http://www.aisleone.net/2010/design/massimo-vignellis-unigrid-system/" title="Massimo Vignelli’s Unigrid System" target="_blank">Unigrid</a>. So it literally folds the content of your site from 16 columns on large desktops, to 8, to 4 for mobile resolutions leaving one column on each side for the margin.</p>
<p>It has this handy gridlet which shows you the grid in action. And best of all it has a zoomable baseline grid&#8230; WTF?!&#8230; Yes the baseline adapts to the font-sizes, vertical paddings, margins and borders etc, they&#8217;ll all scale in proportion as the font-size is changed using media queries, always keeping the baseline grid intact.</P></p>
<p>All pretty awesome stuff this responsive design, and it is only the beginning. <a href="http://bostonglobe.com/" title="The Boston Globe Responsive Website" target="_blank">The Boston Globe</a> started a real buz around the web design community as one of the first big commercial websites to be fully responsive. It was created with the help of Ethan Marcotte who also wrote <a href="http://www.abookapart.com/products/responsive-web-design" title="A Book Apart by Ethan Marcotte" target="_blank">a book apart on responsive web design</a>. If you are interested to learn about responsive design I couldn&#8217;t recommend it more. And don&#8217;t worry, its actually really skinny&#8230; </p>
<p>I hope this inspires you to create your own responsive design&#8230; and I am excited to find out whats next in the future of the intranets</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=167&amp;md5=76a49ac760b9bee7c6aaa1407f2be75b" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/gossip/cause-and-effect-responsive-web-design/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fgossip%2Fcause-and-effect-responsive-web-design%2F&amp;language=en_GB&amp;category=text&amp;title=Cause+and+effect+%26%238211%3B+responsive+web+design&amp;description=Responsive+web+design%26%238230%3B+Well+its+a+hot+topic+now+that+there+are+new+devices+coming+out+every+day.+And+with+each+new+device+comes+a+different+resolution%2C+a+different+dimension....&amp;tags=devices%2Cflexible+design%2Cmedia+queries%2Cmultiple+devices%2Cresponsive%2Cresponsive+design%2Cresponsive+grids%2Cresponsive+web+design%2Cblog" type="text/html" />
	</item>
		<item>
		<title>Change css class with jQuery</title>
		<link>http://thepenthouseproject.com/code/add-remove-css-with-toggleclass-a-jquery-experiment/</link>
		<comments>http://thepenthouseproject.com/code/add-remove-css-with-toggleclass-a-jquery-experiment/#comments</comments>
		<pubDate>Mon, 19 Mar 2012 17:16:34 +0000</pubDate>
		<dc:creator>karin</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[add]]></category>
		<category><![CDATA[change]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[how to]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[remove]]></category>
		<category><![CDATA[toggle]]></category>

		<guid isPermaLink="false">http://thepenthouseproject.com/?p=83</guid>
		<description><![CDATA[DEMO Hi everyone, well here goes. This is my first laboratorium experimentum, a little how to change css class with jQuery. Short Intro I am mostly the visual designer here at thePHP so my developer skills are still very basic. That doesn&#8217;t mean to say I have not done any, I have managed to put...  <a href="http://thepenthouseproject.com/code/add-remove-css-with-toggleclass-a-jquery-experiment/" title="Read Change css class with jQuery">Read more &#187;</a>]]></description>
			<content:encoded><![CDATA[<p class="full_span"><img title="CSS class toggle with jQuery image" src="http://thepenthouseproject.com/assets/Screen-Shot-2012-03-19-at-3.51.40-AM1.png" alt="CSS class toggle with jQuery image" /> <a class="big_button" title="toggle css with jQuery" href="http://dl.dropbox.com/u/66101673/toggleclass/index.html" target="_blank"> DEMO </a></p>
<p class="center_span"><strong> Hi everyone, well here goes. This is my first laboratorium experimentum, a little how to change css class with jQuery. </strong></p>
<h2>Short Intro</h2>
<p>I am mostly the visual designer here at thePHP so my developer skills are still very basic. That doesn&#8217;t mean to say I have not done any, I have managed to put some sites together all on my onesies&#8230; but ehem&#8230; its basic html and css. And that is what I want to improve. Nowadays there is so much styling you can apply in code, that is almost impossible to conceptualize in Illustrator or Photoshop when you don&#8217;t know what is actually possible!</p>
<p>So that is what I am busy learning amongst other things&#8230; Oh if you have no clue about jQuery check out this little game  <a title="Code Academy Java Script" href="http://www.codecademy.com/#!/exercises/0" target="_blank"> http://codecademy.com </a>  I learned more JavaScript in 10 minutes than I have in the last 6 months, and jQuery is basically a JavaScript library to make it easy, so you gotta start there.</p>
<p>I started with my idea, to make a funky color flip of the background and thePHP LAB logo, and decided I would use jQuery to make it work&#8230; now all I had to do was learn how to do it!</p>
<img class="alignnone size-medium wp-image-122" title="CSS class toggle with jQuery concept" src="http://thepenthouseproject.com/assets/IMG_1554-copy-287x300.jpg" alt="the concept" />
<h2>The HTML Markup</h2>
<p>The markup is very simply a link (the button) inside the &lt;body&gt; tag, containing the background color and image class .day. It is this class that will be toggled on and off to create the effect.</p>
<p>Give the body an id and a class, it can be whatever you want, but make it obvious so you can easily use it in the jQuery function id &#8216;selector&#8217; class &#8216;day&#8217; and the button id &#8216;button&#8217; so we can tell the function that, when the &#8220;button&#8221; is clicked, the id &#8216;selector&#8217; is targeted and class &#8216;day&#8217; is replaced.</p>
<pre class="prettyprint">
&lt;body id="selector" class="day" &gt; 

&lt;a href="#" id="button"&gt;click me&lt;/a&gt; 

&lt;/body&gt;</pre>
<h2>Next the CSS styling</h2>
<p>I made the body full width so the class day and/or night apply the background-color to your whole screen.</p>
<pre class="prettyprint">
html { width:100%; height:100%; } 

body { display: block; text-align: center; height: 100%; width: 100%; margin: 0 auto;
    } 

.day { background: url(img/thelab_logo_black_small.png) center center no-repeat #FDBB30; width: 100%; height: 100%; } 

.night
    { background: url(img/thelab_logo_small.png) center center no-repeat black; width: 100%; height: 100%; } 

#button { font-family:
    sans-serif; font-weight: bold; background-color: white; color: #FDBB30; padding: 1.2em; border-radius: 1em; text-decoration:
    none; line-height: 2em; } 

#button:hover { color: black; }</pre>
<h2>And last but not least&#8230;The jQuery function that makes everything work!</h2>
<p>The function is activated by clicking on the button, anything that has the id &#8216;button&#8217;.</p>
<p>This finds the id=&#8221;selector&#8221; and switches class &#8216;day&#8217; to class &#8216;night&#8217;, or if class &#8216;night&#8217; is already active it switches it to class &#8216;day&#8217;</p>
<pre class="prettyprint">
$(function() {
$( "#button" ).click(function(){
$( "#selector" ).toggleClass( "day", "night", 1000 );
$( "#selector" ).toggleClass(
    "night", "day", 1000 ); return false; });
});</pre>
<p>And thats it.. pretty simple stuff, but very satisfactory when I made my idea work!</p>
<p>I hope you found this useful, please feel free add your own comments and alternatives. It may not be the best way, but if it works, it works. If there is one thing I learned while making this, is that there is always a different/better way of doing it&#8230;</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=83&amp;md5=718aa1bb6be07dfd10d9303e4652d420" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/code/add-remove-css-with-toggleclass-a-jquery-experiment/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fcode%2Fadd-remove-css-with-toggleclass-a-jquery-experiment%2F&amp;language=en_GB&amp;category=text&amp;title=Change+css+class+with+jQuery&amp;description=DEMO+Hi+everyone%2C+well+here+goes.+This+is+my+first+laboratorium+experimentum%2C+a+little+how+to+change+css+class+with+jQuery.+Short+Intro+I+am+mostly+the+visual+designer+here...&amp;tags=add%2Cchange%2Ccss%2Chow+to%2Cjquery%2Cremove%2Ctoggle%2Cblog" type="text/html" />
	</item>
		<item>
		<title>theLAB 1.0 finally released</title>
		<link>http://thepenthouseproject.com/gossip/thelab-1-0-finally-released/</link>
		<comments>http://thepenthouseproject.com/gossip/thelab-1-0-finally-released/#comments</comments>
		<pubDate>Sun, 18 Mar 2012 02:00:51 +0000</pubDate>
		<dc:creator>adrian</dc:creator>
				<category><![CDATA[Gossip]]></category>

		<guid isPermaLink="false">http://localhost:8888/lab/?p=42</guid>
		<description><![CDATA[Well here it is, thePENTHOUSEPROJECT Blog. We have been itching to get it online.. tweaking tweaking &#8230; but here it is, finally! theLAB, our official blog. The place we&#8217;ll be putting some interesting stuff about  Graphic design, Illustration, web design, web development and similars (basically all the stuff we do on a daily basis). We&#8217;re already...  <a href="http://thepenthouseproject.com/gossip/thelab-1-0-finally-released/" title="Read theLAB 1.0 finally released">Read more &#187;</a>]]></description>
			<content:encoded><![CDATA[<img class="alignnone size-full wp-image-62" title="thePENTHOUSEPROJECT blog" src="http://thepenthouseproject.com/assets/01_theLABisOPEN_3.png" alt="thePENTHOUSEPROJECT blog entrace" />
<h3 class="full_span">Well here it is, thePENTHOUSEPROJECT Blog.</h3>
<p>We have been itching to get it online.. tweaking tweaking &#8230; but here it is, finally! theLAB, our official blog. The place we&#8217;ll be putting some interesting stuff about  Graphic design, Illustration, web design, web development and similars (basically all the stuff we do on a daily basis).</p>
<p>We&#8217;re already cooking up some great experiments for you, so get your safety glasses ready and those white coats on! And check out the Karin&#8217;s daily snaps, showing a little bit more of Amsterdam (or wherever we are) every day.</p>
<p>Welcome to our place,</p>
<p>thePENTHOUSEPROJECT</p>
 <p><a href="http://thepenthouseproject.com/?flattrss_redirect&amp;id=42&amp;md5=27426372c3be47a8979ccaba7354ad3e" title="Flattr" target="_blank"><img src="http://thepenthouseproject.com/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p>]]></content:encoded>
			<wfw:commentRss>http://thepenthouseproject.com/gossip/thelab-1-0-finally-released/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<atom:link rel="payment" href="https://flattr.com/submit/auto?user_id=thepenthouseproject&amp;url=http%3A%2F%2Fthepenthouseproject.com%2Fgossip%2Fthelab-1-0-finally-released%2F&amp;language=en_GB&amp;category=text&amp;title=theLAB+1.0+finally+released&amp;description=Well+here+it+is%2C+thePENTHOUSEPROJECT+Blog.+We+have+been+itching+to+get+it+online..+tweaking+tweaking+%26%238230%3B+but+here+it+is%2C+finally%21+theLAB%2C+our+official+blog.%C2%A0The+place+we%26%238217%3Bll+be+putting...&amp;tags=blog" type="text/html" />
	</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Served from: thepenthouseproject.com @ 2013-05-22 23:30:24 -->