<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Netsans</title><link>http://netsans.dk</link><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/netsans" /><description>A Common Sense Approach to Design &amp; Communication for the Web</description><language>en</language><lastBuildDate>Mon, 20 Feb 2012 12:38:29 PST</lastBuildDate><generator>http://wordpress.org/?v=</generator><sy:updatePeriod xmlns:sy="http://purl.org/rss/1.0/modules/syndication/">hourly</sy:updatePeriod><sy:updateFrequency xmlns:sy="http://purl.org/rss/1.0/modules/syndication/">1</sy:updateFrequency><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/netsans" /><feedburner:info uri="netsans" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:feedFlare href="http://add.my.yahoo.com/rss?url=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif">Subscribe with My Yahoo!</feedburner:feedFlare><feedburner:feedFlare href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://www.newsgator.com/images/ngsub1.gif">Subscribe with NewsGator</feedburner:feedFlare><feedburner:feedFlare href="http://feeds.my.aol.com/add.jsp?url=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://o.aolcdn.com/favorites.my.aol.com/webmaster/ffclient/webroot/locale/en-US/images/myAOLButtonSmall.gif">Subscribe with My AOL</feedburner:feedFlare><feedburner:feedFlare href="http://www.bloglines.com/sub/http://feeds.feedburner.com/netsans" src="http://www.bloglines.com/images/sub_modern11.gif">Subscribe with Bloglines</feedburner:feedFlare><feedburner:feedFlare href="http://www.netvibes.com/subscribe.php?url=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://www.netvibes.com/img/add2netvibes.gif">Subscribe with Netvibes</feedburner:feedFlare><feedburner:feedFlare href="http://fusion.google.com/add?feedurl=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://buttons.googlesyndication.com/fusion/add.gif">Subscribe with Google</feedburner:feedFlare><feedburner:feedFlare href="http://www.pageflakes.com/subscribe.aspx?url=http%3A%2F%2Ffeeds.feedburner.com%2Fnetsans" src="http://www.pageflakes.com/ImageFile.ashx?instanceId=Static_4&amp;fileName=ATP_blu_91x17.gif">Subscribe with Pageflakes</feedburner:feedFlare><item><title>Making WordPress image management easier for your editors</title><link>http://feedproxy.google.com/~r/netsans/~3/iN6Isr-qGOM/</link><category>Web Development</category><category>Wordpress</category><category>Code snippets</category><category>PHP</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Fri, 17 Feb 2012 05:44:44 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=349</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>I am managing a WordPress site with a lot of editors and contributors. They are not all equally up to pace with WordPress and how it works, or at least they have different ways of doing things. One thing that has proved to be a challenge is the way WordPress handles thumbnails. My editors and contributors often miss the ‘set as post thumbnail’ link,  leading to the lack of thumbnails on the front page.</p>
<p>In this post I will try to explain, how I have made a fallback, making it sort of OK for my users to forget about the thumbnail.</p>
<h2>A little history</h2>
<p>Once upon a time, before version 2.9, WordPress did not support post thumbnails. But there were work arounds. One of the best, I ever found, was from a website called wp-fun.co.uk. Sadly, the site is gone today, but I managed to dig up the old post ‘<a href="http://web.archive.org/web/20090227070123/http://www.wp-fun.co.uk/2009/01/10/easy-peasy-images-suggestion-roundup/">Easy Peasy Images Suggestion Roundup</a>’ by Andrew Rickmann on Archive.org.</p>
<p>Andrew wrote a nice little PHP class to include in your functions file, which gets the first thumbnail image attachment from WordPress posts. Luckily, I also managed to dig that one up on Archive.org. Go grab it here: <a href="http://web.archive.org/web/20090228174716/http://www.wp-fun.co.uk/wp-content/uploads/2009/01/post_imagephp.txt">post_imagephp.txt</a> (remember to rename <code>.txt</code> to <code>.php</code>, before including it in your <code>functions.php</code> file).</p>
<p>“So why are You telling me about antiques like this?”, You ask. Because we can use it with advantage in our fallback for people, who forget to click the little ‘set as post thumbnail’ link.</p>
<p>That way, a thumbnail will still be displayed with the post, as long as the editor has just attached an image. If there are no images attached at all, we can always display a default thumbnail.</p>
<h2>The fallback</h2>
<p>Let’s take a peek at the code. Put the following where you would normally use <code>the_post_thumbnail()</code>.</p>
<p><code>&lt;?php<br />
// First of all, check if there are any image attachments at all.<br />
$imgargs = array(<br />
'order' =&gt; 'ASC',<br />
'post_type' =&gt; 'attachment',<br />
'post_parent' =&gt; $post-&gt;ID,<br />
'post_mime_type' =&gt; 'image',<br />
'post_status' =&gt; null,<br />
'numberposts' =&gt; -1,<br />
);<br />
$attachments = get_posts($imgargs);<br />
// Next, check if there is a manually chosen thumbnail.<br />
if ( has_post_thumbnail() ) {<br />
the_post_thumbnail('thumbnail');<br />
}<br />
// If there are no manually chosen thumbnails, check if there is an image attachment.<br />
elseif ( $attachments ) {<br />
// If there is an image attachment, call Andrew Rickmanns the_image function to get the thumbnail<br />
the_image('thumbnail','attachment-thumbnail wp-post-image',false,false,true);<br />
} else {<br />
// If there are no attachments at all, display a default thumbnail.<br />
?&gt;&lt;img class="attachment-thumbnail wp-post-image" alt="" src="&lt;?php bloginfo('stylesheet_directory'); ?&gt;/the/path/to/your/image.jpg" /&gt;<br />
&lt;?php }?&gt;</code></p>
<h3>Requirements:</h3>
<p>Remember to include this file, renamed to <code>.php</code>, in your <code>functions.php</code>: <a href="http://web.archive.org/web/20090228174716/http://www.wp-fun.co.uk/wp-content/uploads/2009/01/post_imagephp.txt">post_imagephp.txt</a></p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/iN6Isr-qGOM" height="1" width="1"/>]]></content:encoded><description>I am managing a WordPress site with a lot of editors and contributors. They are not all equally up to pace with WordPress and how it works, or at least they have different ways of doing things. One thing that has proved to be a challenge is the way WordPress handles thumbnails. My editors and [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/02/17/making-wordpress-image-management-easy-for-editors/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/02/17/making-wordpress-image-management-easy-for-editors/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=making-wordpress-image-management-easy-for-editors</feedburner:origLink></item><item><title>Icon Fonts</title><link>http://feedproxy.google.com/~r/netsans/~3/xK8oE5JO1SU/</link><category>CSS</category><category>Icons</category><category>Web Design</category><category>@font-face</category><category>graphics</category><category>icons</category><category>vector</category><category>webfonts</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Tue, 07 Feb 2012 06:59:13 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=341</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p><a href="http://netsans.dk/wp-content/uploads/2012/02/webfonts.jpg" rel="prettyPhoto[341]"><img class="aligncenter size-full wp-image-343" title="webfonts" src="http://netsans.dk/wp-content/uploads/2012/02/webfonts.jpg" alt="Webfont specimen" width="600" height="150" /></a>Responsive Design is the new black for web designers. But with responsive design comes a lot of challenges. One of them is to make ui icons scale with the rest of your layout. However, icon fonts is a promising solution in its infancy.</p>
<p>Icon fonts are vector based graphics and are able to scale indefinitely without losing quality, as opposed to the more well known and common pixel based icons. But icon fonts are also tied to characters and this is where the challenges come in, when we want them displayed correctly without making too much trouble in screen readers or screen scrapers.</p>
<p>I have been collecting a few resources on the topic.</p>
<p><strong><a href="http://pictos.cc/articles/using-icon-fonts/">Using Icon Fonts</a></strong><br />
Besides being a service, that offers a nice collection of scalable icons, Pictos also has a great article on the pros and cons of icon fonts and how to use them.</p>
<p><strong><a href="http://css-tricks.com/examples/IconFont/">Icon Fonts are Awesome</a></strong><br />
Chris Coyier of CSS-tricks.com has put together a nifty example, where he demonstrates how easy it is to scale, colorize and shape the shadow of icon fonts with plain and simple CSS.</p>
<p><strong><a href="http://www.webdesignerdepot.com/2012/01/how-to-make-your-own-icon-webfont/">How to make your own icon webfont</a></strong><br />
Over at Webdesigner Depot, Heydon Pickering has written a tutorial on what makes a good icon and how to turn it into a webfont.</p>
<p><strong><a href="http://www.fontsquirrel.com/fonts/list/keyword/icons">Icon Fonts</a></strong><br />
Finally, if you are not yet ready to make your own icon font, Font Squirrel has a small collection of free icon fonts, also available as @font-face kits. Go grab ‘em and try them out.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/xK8oE5JO1SU" height="1" width="1"/>]]></content:encoded><description>Responsive Design is the new black for web designers. But with responsive design comes a lot of challenges. One of them is to make ui icons scale with the rest of your layout. However, icon fonts is a promising solution in its infancy. Icon fonts are vector based graphics and are able to scale indefinitely [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/02/07/icon-fonts/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/02/07/icon-fonts/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=icon-fonts</feedburner:origLink></item><item><title>Respond.js bug?</title><link>http://feedproxy.google.com/~r/netsans/~3/GVu00Y9dVUQ/</link><category>Web Design</category><category>Bugs</category><category>ie8</category><category>Internet Explorer</category><category>Javascript</category><category>Respond.js</category><category>Responsive Design</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Thu, 02 Feb 2012 12:49:09 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=334</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>I ran into a strange bug today.</p>
<p><a href="http://netsans.dk/2012/01/31/krimimessen-2012/">I recently launched Krimimessen.dk</a> where I have used a small polyfill script written by <a href="http://scottjehl.com/">Scott Jehl</a>, <code>respond.js</code>, to make the site’s responsiveness work in older versions of Internet Explorer.</p>
<p>But then one of my colleagues made me aware of a bug that seemed to trigger when clicking on links in Internet Explorer 8. Not in everybody’s Internet Explorer 8, oh no. Only in Internet Explorer 8 on certain machines. Well, who said it should be easy to test for bugs?</p>
<p>Instead of going to the desired destination, the browser went to a URL with this pattern:<br />
<code>res://ieframe.dll/acr_error.htm#the-url-without-http</code></p>
<p>I have done a little searching on the issue, and generally people say the problem goes away if you delete the browser cache or disable browser extensions. However, that solves no problem, because I can’t ask my users to delete their cache.</p>
<p>Then I stumbled upon someone in the Drupal.org forum who had had the same issue and <a href="http://drupal.org/node/1323608#comment-5211482">one of the proposed fixes</a> was to move <code>respond.js</code> to the footer.</p>
<p>And there you go. It seemed to work. At least the bug disappeared.</p>
<p>But <a href="https://github.com/scottjehl/Respond">according to the Respond usage instructions</a>, the script ought to be loaded as quickly after the CSS file as possible to avoid glimpses of “unresponsiveness” in ie.</p>
<p>So now I wonder if this <del datetime="2012-02-02T22:02:13+00:00">is a bug in</del> <ins datetime="2012-02-02T22:02:13+00:00"> ie8 bug can be fixed within</ins> <code>respond.js</code>? Or is it something else, that triggers the bug? Or am I just using <code>respond.js</code> wrong?</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/GVu00Y9dVUQ" height="1" width="1"/>]]></content:encoded><description>I ran into a strange bug today. I recently launched Krimimessen.dk where I have used a small polyfill script written by Scott Jehl, respond.js, to make the site’s responsiveness work in older versions of Internet Explorer. But then one of my colleagues made me aware of a bug that seemed to trigger when clicking on [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/02/02/respond-js-bug/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/02/02/respond-js-bug/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=respond-js-bug</feedburner:origLink></item><item><title>Styling images with CSS3</title><link>http://feedproxy.google.com/~r/netsans/~3/gPdu__oEmH8/</link><category>CSS</category><category>Links</category><category>Web Design</category><category>Box shadow</category><category>CSS3</category><category>images</category><category>Pseudo-selectors</category><category>Rounded corners</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Wed, 01 Feb 2012 05:43:51 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=329</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Pimping images with rounded corners, box shadow and other CSS3 eye candy can be a pain in that part of the body, you normally sit on, because browser support is really lousy.</p>
<p>Until now. Because Nick La from Web Designer Wall has a nice little trick up his sleeve, which involves wrapping the image in an HTML element and making an overlay for styling with a CSS pseudo-selector.</p>
<p><a href="http://webdesignerwall.com/tutorials/css3-image-styles-part-2">Go check out Nick’s tutorial here</a></p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/gPdu__oEmH8" height="1" width="1"/>]]></content:encoded><description>Pimping images with rounded corners, box shadow and other CSS3 eye candy can be a pain in that part of the body, you normally sit on, because browser support is really lousy. Until now. Because Nick La from Web Designer Wall has a nice little trick up his sleeve, which involves wrapping the image in [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/02/01/styling-images-with-css3/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/02/01/styling-images-with-css3/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=styling-images-with-css3</feedburner:origLink></item><item><title>The 1000px grid</title><link>http://feedproxy.google.com/~r/netsans/~3/EP9EV2aljuk/</link><category>CSS</category><category>Photoshop</category><category>Quick tips</category><category>Web Design</category><category>Grids</category><category>Layout</category><category>tips</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Tue, 31 Jan 2012 13:12:16 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=326</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Elliot Jay Stocks, Bristol based web designer and illustrator, recently proposed on his blog a 1000 pixel grid as the base for layout prototyping in Photoshop, instead of the more common and defacto 960 pixel grid, we have all become so used to.</p>
<p>The reason? The math is so much easier to do, when transforming the grid from pixels to percent in responsive web design.</p>
<p>It is such a simple and obvious approach, I’m almost embarrased, I haven’t thought of it before.</p>
<p><a href="http://elliotjaystocks.com/blog/a-better-photoshop-grid-for-responsive-web-design/">Elliot Jay Stocks: A better Photoshop grid for responsive web design</a></p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/EP9EV2aljuk" height="1" width="1"/>]]></content:encoded><description>Elliot Jay Stocks, Bristol based web designer and illustrator, recently proposed on his blog a 1000 pixel grid as the base for layout prototyping in Photoshop, instead of the more common and defacto 960 pixel grid, we have all become so used to. The reason? The math is so much easier to do, when transforming [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/01/31/the-1000px-grid/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/01/31/the-1000px-grid/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=the-1000px-grid</feedburner:origLink></item><item><title>Krimimessen 2012</title><link>http://feedproxy.google.com/~r/netsans/~3/R_XW2NFkQAE/</link><category>CSS</category><category>Portfolio</category><category>Web Design</category><category>Web Development</category><category>Wordpress</category><category>CSS3</category><category>Media Queries</category><category>Mobile</category><category>Responsive Web Design</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Tue, 31 Jan 2012 08:49:02 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=322</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p style="text-align: center;clear:both;"><a href="http://horsensbibliotek.dk/krimiblog/"><img class="aligncenter  wp-image-323" title="krimimessen-2012" src="http://netsans.dk/wp-content/uploads/2012/01/krimimessen-2012.jpg" alt="Screen dump of Krimimessen 2012" width="520" height="456" style="border:none;" /></a></p>
<p>I have just launched a re-design of <a href="http://horsensbibliotek.dk/krimiblog/">Krimimessen.dk</a>. Krimimessen is the biggest festival about crime literature and criminal fiction in Denmark. A festival which is arranged by Horsens Public Library, where I work. The site is designed so it resizes to fit the screen it is being viewed on, also known as responsive web design.</p>
<p>This is the first responsive site, I have created. It is built in WordPress on a base of the awesome <a href="http://html5boilerplate.com/">HTML5 Boilerplate</a> framework, which makes it easier to build a modern web site from scratch.</p>
<p>I learned a lot from reading Ethan Marcotte’s “<a href="http://www.abookapart.com/products/responsive-web-design">Responsive Web Design</a>” prior to this project. Marcotte’s <a href="http://www.alistapart.com/articles/fluidgrids/">“target ÷ context = result” technique</a>, a way to calculate dimensions from pixels into percent, was an invaluable tool in the process. In fact, and very unusual indeed, it wasn’t even necessary to test a lot in Internet Explorer.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/R_XW2NFkQAE" height="1" width="1"/>]]></content:encoded><description>I have just launched a re-design of Krimimessen.dk. Krimimessen is the biggest festival about crime literature and criminal fiction in Denmark. A festival which is arranged by Horsens Public Library, where I work. The site is designed so it resizes to fit the screen it is being viewed on, also known as responsive web design. [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2012/01/31/krimimessen-2012/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2012/01/31/krimimessen-2012/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=krimimessen-2012</feedburner:origLink></item><item><title>Skitch</title><link>http://feedproxy.google.com/~r/netsans/~3/E79zF7B9al0/</link><category>Apps</category><category>Inspiration</category><category>Drawing</category><category>Screen Grabbing</category><category>Screen Shots</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Wed, 30 Nov 2011 02:47:42 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=306</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p><img class="size-medium wp-image-307 alignright" title="A screen shot of my Skitch blog" src="http://netsans.dk/wp-content/uploads/2011/11/skitch-188x130.jpg" alt="A screen shot of my Skitch blog" width="188" height="130" />I’ve always found it hard to get a grab on where to store and manage my occasional inspirational screen shots. Saving them to the hard drive works, but I really miss an overview and a way to add notes and keywords for findability.</p>
<p>But recently I started using Skitch. It’s a great little app for stuff like taking screen shots, sketching ideas and sharing the whole lot. It easily solves the problem of managing screen shots. Just open Skitch, drag the screen snap tool across the part of the screen, you want to save, upload and tag it. And there you go, a blog with screen shots, easily managed with notes and tags for findability.</p>
<p><a href="https://skitch.com/bechster/">Check out my Skitch blog here</a>.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/E79zF7B9al0" height="1" width="1"/>]]></content:encoded><description>I’ve always found it hard to get a grab on where to store and manage my occasional inspirational screen shots. Saving them to the hard drive works, but I really miss an overview and a way to add notes and keywords for findability. But recently I started using Skitch. It’s a great little app for [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2011/11/30/skitch/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2011/11/30/skitch/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=skitch</feedburner:origLink></item><item><title>Flexible Widgets for WordPress</title><link>http://feedproxy.google.com/~r/netsans/~3/fkddlYQZJIA/</link><category>Web Development</category><category>Wordpress</category><category>CMS</category><category>Content Management</category><category>Widgets</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Fri, 12 Aug 2011 04:17:25 PDT</pubDate><guid isPermaLink="false">http://netsans.dk/?p=266</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p><strong>Flexible Widgets is a plugin for WordPress that makes it possible to display a widget on selected categories and/or pages.</strong></p>
<p><img class="aligncenter size-full wp-image-283" title="Widgets 600px wide" src="http://netsans.dk/wp-content/uploads/2011/08/widgets-600px.jpg" alt="" width="600" height="150" /><br />
The Flexible Widgets plugin lets you display a widget on any category or page you wish. When setting up the widget, you are able to select the categories and/or pages where you want to display the widget. If none are selected, the widget will be displayed globally on your site, exactly like a default WordPress widget.</p>
<p>The plugin comes in handy if you need your sidebar content to change contextually from page to page in relation to your main content. It is especially useful if you want to use WordPress as a CMS.</p>
<p>Flexible Widgets will replace the default WordPress widgets.</p>
<div style="overflow: hidden; background: #ddd; padding: 1em .5em; border-radius: 1em; -moz-border-radius: 1em; -webkit-border-radius: 1em;">
<div style="width: 50%; float: left;"><a href="http://wordpress.org/extend/plugins/flexible-widgets/">Find it in the WordPress Plugin Directory or</a> …</div>
<div style="width: 45%; float: left;"><a class="button" style="width: 100%; text-align: center;" href="http://downloads.wordpress.org/plugin/flexible-widgets.zip">Download version 0.3</a></div>
</div>
<h3 style="padding: .5em 0 0;">Sreenshot</h3>
<div id="attachment_268" class="wp-caption aligncenter" style="width: 530px"><a href="http://netsans.dk/wp-content/uploads/2011/08/screenshot-1.png" rel="prettyPhoto[266]"><img class="size-full wp-image-268" title="screenshot-1" src="http://netsans.dk/wp-content/uploads/2011/08/screenshot-1.png" alt="Widget administration interface in the WordPress plugin Flexible Widgets" width="520" height="559" /></a><p class="wp-caption-text">Selecting categories and pages in each widget’s back end.</p></div>
<h3>Installation</h3>
<ol>
<li>Upload the <code>flexible-widgets</code> folder to the <code>/wp-content/plugins/</code> directory</li>
<li>Activate the plugin through the ‘Plugins’ menu in WordPress</li>
</ol>
<p>or search for “Flexible Widgets” in the “Add new” section of the plugins menu in your WordPress admin interface and hit “Install now”.</p>
<h3>Change log</h3>
<h4>0.3</h4>
<ul>
<li>Fixes an issue: Optionally display widgets on the home page, whether it is set up to be a static page or the blog posts page.</li>
</ul>
<h4>0.2</h4>
<ul>
<li>Tiny update to get the plugin and author URIs right.</li>
<li>Update on the installation info.</li>
</ul>
<h4>0.1</h4>
<ul>
<li>Brand new plugin. Still playing with the bubble wrap.</li>
</ul>
<h3>Known issues</h3>
<p>May conflict with themes or plugins which include custom widgets.</p>
<p>Please see <a href="http://wordpress.org/tags/flexible-widgets?forum_id=10">the plugin support forum</a>.</p>
<h3>Additional information</h3>
<p>The Flexible Widgets plugin consists of a bunch of ideas and lines of code, I wrote for the WordPress theme in use at <a href="http://horsensbibliotek.dk/">the website of Horsens Public Library</a>.</p>
<p>This is my first plugin for WordPress. I am sure, there is room for improvement. The code is far from perfect as my programming skills are somewhat limited. But I do think the idea is quite good, so if you can write lean code and are desperately in need of a small side project, you should be very welcome to help me out.</p>
<p>If you have any questions or comments, feel free to leave a reply.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/fkddlYQZJIA" height="1" width="1"/>]]></content:encoded><description>Flexible Widgets is a plugin for WordPress that makes it possible to display a widget on selected categories and/or pages. The Flexible Widgets plugin lets you display a widget on any category or page you wish. When setting up the widget, you are able to select the categories and/or pages where you want to display [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2011/08/12/flexible-widgets-for-wordpress/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">7</slash:comments><feedburner:origLink>http://netsans.dk/2011/08/12/flexible-widgets-for-wordpress/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=flexible-widgets-for-wordpress</feedburner:origLink></item><item><title>Sådan finder man variabler i WordPress</title><link>http://feedproxy.google.com/~r/netsans/~3/gKSncN34fas/</link><category>Web Development</category><category>Wordpress</category><category>query_vars</category><category>Variable</category><category>wp_query</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Fri, 03 Dec 2010 04:57:56 PST</pubDate><guid isPermaLink="false">http://netsans.dk/?p=250</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Når man arbejder med templates i WordPress, kan det være enormt nyttigt at vide, hvilke variable, man har at arbejde med. Jeg havde et konkret problem omkring en tag template (tag.php), hvor jeg havde brug for at finde ID-nummeret på det aktuelle tag til brug i funktionen <code>get_tag_link()</code>.</p>
<p>Jeg fandt det ved at skrive listen over mulige variable i query_vars ud med følgende stump kode:<br />
<code>&lt;?php  print_r($wp_query-&gt;query_vars); ?&gt;</code></p>
<p>… og fandt, at den variabel, jeg havde brug for, hed <code>tag_id</code>.</p>
<p>Særdeles anvendeligt, når man har brug for overblik over tilgængelige variable.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/gKSncN34fas" height="1" width="1"/>]]></content:encoded><description>Når man arbejder med templates i WordPress, kan det være enormt nyttigt at vide, hvilke variable, man har at arbejde med. Jeg havde et konkret problem omkring en tag template (tag.php), hvor jeg havde brug for at finde ID-nummeret på det aktuelle tag til brug i funktionen get_tag_link(). Jeg fandt det ved at skrive listen [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2010/12/03/sadan-finder-man-variabler-i-wordpress/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">1</slash:comments><feedburner:origLink>http://netsans.dk/2010/12/03/sadan-finder-man-variabler-i-wordpress/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=sadan-finder-man-variabler-i-wordpress</feedburner:origLink></item><item><title>Google Fonts API — Det her er stort!</title><link>http://feedproxy.google.com/~r/netsans/~3/8vMNVoOZvzs/</link><category>CSS</category><category>Quick tips</category><category>@font-face</category><category>Fonts</category><category>Google</category><category>webfonts</category><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Morten Brunbjerg Bech</dc:creator><pubDate>Wed, 19 May 2010 14:07:53 PDT</pubDate><guid isPermaLink="false">http://netsans.dk/?p=234</guid><content:encoded xmlns:content="http://purl.org/rss/1.0/modules/content/"><![CDATA[<p>Som bekendt har man relativt begrænsede typografiske muligheder i webdesign. Der findes en del workarounds, såsom <a href="http://cufon.shoqolate.com/generate/">Cufon</a> og <a href="http://wiki.novemberborn.net/sifr/">sIFR</a> og de går an, men det bliver aldrig helt godt. Nu vender Google hele møllen på hovedet med <a href="http://code.google.com/webfonts">hosting af fonts</a> og <a href="http://code.google.com/intl/da-DK/apis/webfonts/docs/getting_started.html#Quick_Start">en API, der gør det sindssygt nemt at implementere</a>.</p>
<p>Et lille eksempel:</p>
<div class="lobster">Skrifttypen Lobster</div>
<p>Smæk dette link ind i head sektionen i dit HTML dokument.</p>
<p><code>&lt;link href='http://fonts.googleapis.com/css?family=<strong>Lobster</strong>' rel='stylesheet' type='text/css'&gt;</code></p>
<p>Så er du klar til at bruge Lobster i din css som enhver anden font.</p>
<p>Det skulle efter sigende fungere helt tilbage til IE6. Skulle man endelig være negativ, kunne man sige at udvalget af skrifttyper stadig er ret begrænset, men mon ikke, der med tiden bliver lavet om på det?</p>
<p><a href="http://net.tutsplus.com/tutorials/html-css-techniques/quick-tip-google-fonts-api-youre-going-to-love-this/">Via Nettuts</a>.</p>
<img src="http://feeds.feedburner.com/~r/netsans/~4/8vMNVoOZvzs" height="1" width="1"/>]]></content:encoded><description>Som bekendt har man relativt begrænsede typografiske muligheder i webdesign. Der findes en del workarounds, såsom Cufon og sIFR og de går an, men det bliver aldrig helt godt. Nu vender Google hele møllen på hovedet med hosting af fonts og en API, der gør det sindssygt nemt at implementere. Et lille eksempel: Skrifttypen Lobster [...]</description><wfw:commentRss xmlns:wfw="http://wellformedweb.org/CommentAPI/">http://netsans.dk/2010/05/19/google-fonts-api-det-her-er-stort/feed/</wfw:commentRss><slash:comments xmlns:slash="http://purl.org/rss/1.0/modules/slash/">0</slash:comments><feedburner:origLink>http://netsans.dk/2010/05/19/google-fonts-api-det-her-er-stort/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=google-fonts-api-det-her-er-stort</feedburner:origLink></item></channel></rss>

