Split content into multiple columns using more tag?

First of, this is pretty much an exact duplicate of: Split columns into three+ divs? But the given solution does not work (returns blank). I’m guessing it collides with qTranslate which adds some really weird comments to the html, but i’m not sure. I found a great code snippet that simply splits the content into pieces by the more tag. The problem is it seems to only split into two columns. It ignores the rest of the more tags. I am not actually dividing the content into columns, but rather…

Web Design Weekly #63

Headlines Learnable Programming An outstanding, well written and very accessible essay on what needs to happen to help people understand programming. (worrydream.com) responsiveimages.org This new site run by the Responsive Images Community Group aims to contain all the discussions around this hot topic in one place. (responsiveimages.org) How Fast Is… Apple.com? (zoompf.com) Articles Step by step from jQuery to Backbone In this blog post, Kim Joar Bekkelund gradually refactors a bit of code from how he used to write JavaScript before, into proper Backbone.js code using models, collections, views and…

Web Design Podcasts

As with all sites, podcasts can be up and down. Not all episodes are good; sometimes they are irrelevant and sometimes they are gold. Web design podcasts are a great way to stay in the loop about the ever-changing world of web design. They are a very easy way to learn about emerging technologies and standards, listen to in-depth discussions with some of the best designs and developers on the planet and continuously learn whilst you’re not at your desk. Below is a list of my favourite podcasts that have…

Web Design Weekly #62

Headlines IE10 Snap Mode and Responsive Design A great post by Tim Kadlec which explains how and why we need to start adding the @-ms-viewport rule to our CSS now to ensure our sites look good on Windows 8. (timkadlec.com) The Infinite Grid Grid systems are a key component of graphic design, but they’ve always been designed for canvases with fixed dimensions. Until now. Today, we’re designing for a medium that has no fixed dimensions; a medium that can and will shape-shift to better suit its environment; a medium capable…

Uploading PDF using Media Uploader

I have been using a custom code to upload images to WordPress using custom metaboxes. Here is the code: <script type= »text/javascript »> jQuery(document).ready(function( $ ) { var formfield; $(‘.upload_button’).click(function() { $(‘html’).addClass(‘Image’); formfield = $(this).prev(‘.upload_image’); // .attr(‘name’); tb_show( », ‘media-upload.php?type=image&TB_iframe=true’); return false; }); // user inserts file into post. only run custom if user started process using the above process // window.send_to_editor(html) is how wp would normally handle the received data window.original_send_to_editor = window.send_to_editor; window.send_to_editor = function(html){ if (formfield) { fileurl = jQuery(‘img’,html).attr(‘src’); $(formfield).val(fileurl); tb_remove(); formfield =  »; $(‘html’).removeClass(‘Image’); } else { window.original_send_to_editor(html);…

CSS Box-Sizing

Having a little knowledge of how the box-sizing property works and when you can utilise it is a neat trick to have up your sleeve. The reason for using the box-sizing property in your CSS is to alter the default CSS box model. Modifying the box model gives you the option of whether or not an element’s width and height include padding and border or not. In web design every element is a box and each box has a content area (e.g. text, an image, etc.) and optional surrounding padding,…

Using Sass source maps in WebKit Inspector

http://bricss.net/post/33788072565/using-sass-source-maps-in-webkit-inspector Lennart Schoors: If you’re using Firefox and Sass you might have heard about FireSass, but Chrome users have been out of luck until recently. This is where source maps come into play. Source maps are a language-agnostic way of pointing your inspector to the right location in your unminified and uncombined files. Originally devised for JavaScript, they can equally be applied to CSS preprocessors. A fairly recent commit enabled experimental support for Sass source maps in Chrome, so make sure you’re running at least Chrome 24. Awesome! Well, thats…

The Infinite Grid

http://alistapart.com/article/the-infinite-grid Chris Armstrong: Grid systems are a key component of graphic design, but they’ve always been designed for canvases with fixed dimensions. Until now. Today we’re designing for a medium that has no fixed dimensions, a medium that can and will shape-shift to better suit its environment—a medium capable of displaying a single layout on a smartphone, a billboard in Times Square, and everything in between. We’re designing for an infinite canvas—and for that, we need an infinite grid system. Cracking read! Source: web design weekly

do_shortcode() doesn’t work if shortcode contained in variable, works if shortcode passed as string

I’m developing a plugin, wherein one of the features is to switch out forms on a specific page by changing the shortcode within a custom field. within my plugin file: function getShort() { global $post; $m = get_post_meta($post->ID, ‘short’, true); return $m; } within my theme file: $short = getShort(); echo do_shortcode($short); With the code above, it just prints out the shortcode. If I echo the value of $short, copy and paste that as the argument for do_shortcode(), it prints out the expected value. I am 100% confident that the…

Focus on Input with JQuery

This is very simple and can also be done with HTML5 autofocus which I would recommend you use (if you can). If for some reason you need to control it with JavaScript, utalising jQuery’s .focus() event handler will get you out of trouble. To focus on an input field with an id of search on page load, try: $(document).ready(function() { $('#search').focus(); }); Source: web design weekly