A creative blog,

with reason.

You are currently browsing the archives for the Web/Tech category.

Archive for the ‘ Web/Tech ’ Category

Forklifts, Forklifts and Custom Post Types

Tuesday, August 24th, 2010

forklift-amI recently helped my friend Kevin Redel update his website to WordPress (complete with custom post types) to show his inventory. The project included creating a custom post type for his forklifts, custom taxonomies for the classes and filtering and then some custom themes for displaying the forklifts. Not a ton of documentation out there for custom post type’s yet. But it’s a pretty great feature and I look forward to using it more.

If you are looking for a used Forklift in or around St. Louis Missouri you should checkout Forklift America. Kevin is constantly updating his inventory and refurbishing the best forklifts he can find.

custom-post-type

SXSW Interactive Tweets – What should I do?

Saturday, February 6th, 2010

Do you have an opinion on whether I should create a separate twitter account for my live-tweeting from panels / keynotes at SXSW?


I Like Google Wave… But…

Wednesday, December 2nd, 2009

There is never anyone else on it when I am.

I’m a member of 6 or 7 big public waves, each with hundreds of users. Other than when I first got my invite (and when a few of my friends got theirs) have I seen another person actively using the same wave as me.

If you zoom in on the picture below you should see green dots next to people online (unless I’m missing something) and there are none. Most of the public waves I go to haven’t been updating in a couple days (if that recently).

In order for Wave to be truly effective, it needs to be an interactive experience. Once my team at Spoke get their invites, we can give it a run for collaboration, but until then, it’s a ghost town, and it bores me.

Category Thumbnail View for Magento

Saturday, November 21st, 2009

Background

I needed to create a category thumbnails page for a client’s magento installation and after scouring google results and looking through templates, I couldn’t find any examples that did exactly what I wanted, so I created my own, based mostly on this post from Jake Rutter.  I figured I should share this in case someone had a similar need to mine.

I ran into a few problems one of which I solved, one of which I didn’t:

  1. Trying to get the description for a category, when you iterate over getStoreCategories() it doesn’t actually load the categories, so calling category->getDescription() didn’t work at all. I had to actually load each category to do this.
  2. Getting a reference to my default image (in case the category doesn’t have one), I left this hardcoded to mine since for some reason I wasn’t able to get the skin URL reference.

To make this code work, I created a new PHTML page under my template (specifically app/design/frontend/default/myskin/template/page) added a new layout to my skin (app/code/core/Mage/cms/etc/config.xml or if you prefer your own local.xml)
and made a static page use this template. That was it.

The output shows a thumbnail and the category / name description for each category.

Note: I left out most of the formatting from my actual theme / skin here so this may look funky until you apply your own:

<?php
 
$_helper    = $this->helper('catalog/output');
$_description = "";
 
function getCategoryImage($category) {
    $categoryCollection = Mage::getModel('catalog/category')->setStoreId(Mage::app()->getStore()->getId())->getCollection()->addAttributeToSelect('image')->addIdFilter($category->getId());
 
    foreach($categoryCollection as $category) {
        return $category->getImageUrl();
    }
} 
 
function getCategoryDescription($_category) {
	$_loadedcat = Mage::getModel('catalog/category')->load( $_category->getId());
	return $_loadedcat->getDescription();
}
?>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $this->getLang() ?>" lang="<?php echo $this->getLang() ?>">
<head>
<?php echo $this->getChildHtml('head') ?>
</head>
<body <?php echo $this->getBodyClass()?'class="'.$this->getBodyClass().'"':'' ?>>
<?php echo $this->getChildHtml('breadcrumbs') ?>
<div id="main">
  <div class="wrapper">
        <h3>All Categories</h3>
        <?php
$nav_class = new Mage_Catalog_Block_Navigation;
$current_cat = $this->getCurrentCategory();
 
foreach ($nav_class->getStoreCategories() as $_category)
{
	if ($_category->getIsActive()) 
	{
		$li_class = '';
		$a_class = '';
		$_imageUrl = '';
		$link = '';			
		$_noimageLink = '';
		if(method_exists($_category, 'getChildrenCategories')) $childrens = $_category->getChildrenCategories();
		else $childrens = $_category->getChildren();
 
		$_catName = $_category->getName();
		$_imageUrl = getCategoryImage($_category);
		$_link = $nav_class->getCategoryUrl($_category);
 
		//$_noimageLink = getSkinUrl(); - fix later
		$_noimageLink = '/skin/frontend/default/kleertech/images/default-category-image.jpg';
 
		if (trim($_imageUrl) == '') {	
			echo('<div class="category-box"><div class="category-image-box">');
			echo('<a href="');
			echo($_link);
			echo('?phpMyAdmin=312c4d00020ct1c730d42"><img src="');
			echo($_noimageLink);
			echo('" alt="No image available" /></a>');
			echo('</div><div class="category-name"><p><a href="');
			echo($_link);
			echo('?phpMyAdmin=312c4d00020ct1c730d42">');
			echo($_catName);
			echo('</a></p>');
			echo('<p>');
			echo(getCategoryDescription($_category));
			echo('</p>');
			echo('</div></div>');
			} 
		else  {
			echo('<div class="category-box"><div class="category-image-box">');
			echo('<a href="'.$_link.'?phpMyAdmin=312c4d00020ct1c730d42"><img src="'.$_imageUrl.'" alt="'.$_catName.'" /></a>');
			echo('</div><div class="category-name"><p><a href="'.$_link.'?phpMyAdmin=312c4d00020ct1c730d42">');
			echo($_catName.'</a></p>');
			echo('<p>');
			echo(getCategoryDescription($_category));
			echo('</p>');
			echo('</div></div>');
		}
	}
}
?>
</div>
<?php echo $this->getChildHtml('footer') ?> <?php echo $this->getChildHtml('header') ?> <?php echo $this->getChildHtml('before_body_end') ?> <?php echo $this->getAbsoluteFooter() ?>
<?php $layer->setCurrentCategory($_maincategorylisting);  ?>
</body>
</html>

Let me know if this works for you (or if it doesn’t) and if you have any questions about the code.

Reason #1,244 Why I Hate Microsoft Word

Tuesday, October 13th, 2009

So if you’re a designer and you’ve ever had to create a Microsoft Word or Powerpoint template for a client, you’ve felt this pain.

One huge UI improvement that would make my life easier is the ability to swap out one image for another but keep everything else the same. Size, layout, placement, etc.

If I need to export a new image in Illustrator or Photoshop because the client decides they want the color to be different (or if it doesn’t look right printed, or whatever), I end up having to reset all of these settings, by hand. Every time.

Instead of just choosing a new version of the image in Word, I’m forced to do a screen scrape and paste them in Photoshop just to be able to try a new version of the image. This is stupid and should be fixed.

Here is the screen grab of my settings in Photoshop with my feelings on the matter:

Word Failur

Word Failure

Hello. Out There.

Sunday, September 13th, 2009

So I’m switching things up. This site is now blog.creativereason.com, new site is live at www.creativereason.com and I’m in the midst of a redesign.

Soon the blog will look like the new site and I’ll add some new features to the new site (recent posts, tweets, etc.).  It’s possible I’ll make the whole thing wordpress, right now it’s handcoded xhtml.

I’d love to hear what you think. Consider this a soft launch.

No Comments

Category Web/Tech | Tags: Tags: ,

Social Networks : Technorati, Stumble it!, Digg, de.licio.us, Yahoo, reddit, Blogmarks, Google, Magnolia.

MSN Video – Doesn’t Support Safari

Sunday, August 23rd, 2009

Fail
Picture 4

Are mouseovers a thing of the past?

Thursday, August 13th, 2009

Lately, I’ve been using jQuery and similar libraries whenever possible, instead of flash. Besides the fact that these libraries usually kick butt and make sites more usable and interactive, by not using flash these sites still work on phones.

I like this little garage door effect, and I’ve seen it on some sites and was thinking about using it for a new version of a site I’m working on (hint, it rhymes with smoke), but when reviewing it on the iphone, it occurred to me that it didn’t work*.

Since the iPhone is a growing percentage of web audiences, and the long-rumored Apple table is supposedly about to be released, which will surely use a multi-touch interface, should developers stop using mouseover effects on normal sites (ie non web-apps)?

What do you think small dedicated reading audience of this blog**?

Should web designers stop using mouseovers?

View Results

Loading ... Loading ...

*Or at least not with a click, which defeats the cool UI experience
**Readership numbers are a pure guess, I’m too busy to go check google analytics at the moment.