<?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>larryaronson.com &#187; wordpress</title>
	<atom:link href="http://larryaronson.com/tag/wordpress/feed/" rel="self" type="application/rss+xml" />
	<link>http://larryaronson.com</link>
	<description>Systems Psychoanalyst</description>
	<lastBuildDate>Wed, 14 Dec 2011 04:17:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>Add Author Photo — My First WordPress Filter</title>
		<link>http://larryaronson.com/2009/add-author-photo-%e2%80%94-my-first-wordpress-filter/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2009/add-author-photo-%e2%80%94-my-first-wordpress-filter/#comments</comments>
		<pubDate>Fri, 09 Oct 2009 18:18:20 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Featured]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[authors]]></category>
		<category><![CDATA[client]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[filters]]></category>
		<category><![CDATA[hooks]]></category>
		<category><![CDATA[image]]></category>
		<category><![CDATA[lawyer]]></category>
		<category><![CDATA[photos]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Smashing Magazine]]></category>
		<category><![CDATA[websites]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=802</guid>
		<description><![CDATA[My client wanted to have their authors' photos appear with their published articles. In this article, I describe how I wrote a Wordpress filter – my first – to prepend an image to the content on the home and single post pages.]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-871" style="padding-left: 0" title="your_photo_here" src="http://larryaronson.com/wp-content/uploads/your_photo_here.jpg" alt="your_photo_here" width="80" height="82" />The request was simple enough. I had just built a <a title="Air Safety And Law" href="http://airsafetyandlaw.com" target="_blank">WordPress blog for a law firm</a> and now they wanted to have their thumbnail photos in the articles they write. I had done this for <a title="Digital HHR" href="http://digitalhhr.com" target="_blank">another website</a> (also a law firm) a year ago, modifying each of the theme&#8217;s templates that displayed posts but, when I went back and looked at that code, I thought, &#8220;Too messy, there&#8217;s got to be a better way.&#8221;</p>
<p>A plug-in search turned up nothing. No surprise—Wordpress does not support user profile pictures natively. There&#8217;s no field in the database for an user&#8217;s image file name. Then I remembered reading an<a title="10 Useful WordPress Hooks" href="http://www.smashingmagazine.com/2009/08/18/10-useful-wordpress-hook-hacks/" target="_blank"> article in Smashing Magazine about filters</a> a couple of months ago. They had an example where a subscribe request was appended to the end of each post&#8217;s content. Maybe that technique would work to prepend a photo.</p>
<p>In WordPress, a filter is like a plug-in except for two important distinctions: It&#8217;s not packaged for distribution and it&#8217;s associated with the theme. That is, you can&#8217;t manage the filter from the dashboard&#8217;s plug-in manager and, if you change themes, it disappears. That was all right for my purposes. The clients were quite happy with the theme we&#8217;d chosen – <a href="http://wpthemes.info/misty-look/" target="_blank">Mistylook, by Sadish Bala</a> – and I could provide instructions on how to remove the filter from the theme&#8217;s functions file should they ever want to &#8220;deactivate&#8221; the feature.</p>
<p>I got the images from the client for the four lawyer/authors—a wallet-sized image and a thumbnail for each. The larger image would appear on the author&#8217;s profile page and the thumbnails would be placed at the beginning of their posts, floated left of the text. For the larger image, I modified the author&#8217;s template (<span style="font-family: andale mono,times;">author.php</span>) as I had with the previous website. For the thumbnails, I would use the filter approach since post content is accessed in several templates and I wanted a unified solution. For the sake of brevity, I&#8217;ll skip the part about the author template mods in this article. If you&#8217;re interested in that piece, leave a comment and I&#8217;ll write another article.</p>
<p>I created a new directory, <span style="font-family: andale mono,times;">/wp-content/authors</span> for the larger images and a sub-directory, <span style="font-family: andale mono,times;">/wp-content/authors/thumbs</span> for the smaller versions. In each, I renamed the images files to match the corresponding login usernames. If, for example, there was a user with the login username of &#8216;bobama&#8217;, then the two images files would be: <span style="font-family: andale mono,times;">/wp-content/authors/bobama.jpg</span> and  <span style="font-family: andale mono,times;">/wp-content/authors/thumbs/bobama.jpg</span> . I did this with an ftp program but you can use the dashboard&#8217;s Media manager, in which case, the image files will be somewhere in your <span style="font-family: andale mono,times;">/wp-content/uploads</span> directory with your other media files. All of the other work described in this article can be done through the dashboard&#8217;s theme editor by an admin user but I highly recommend using a good code editor with color syntax highlighting. <a href="http://bbedit.com/" target="_blank">BBEdit</a> is my favorite.</p>
<p>A WordPress filter goes into the theme&#8217;s functions file (<span style="font-family: andale mono,times;">functions.php</span>) and consists of two parts: A function definition and a call to add that function to a named WordPress &#8220;hook&#8221;. I called my function: <span style="font-family: andale mono,times;">add_author_photo() </span> and  added it to the &#8216;the_content&#8217; hook. You can think of this hook as the point in the page building process when WordPress gets the page or post content from the database and starts to get it in shape for the web page it&#8217;s building. WordPress passes the content to the function as a string and expects it back in return. Roughly, the outline of the process looks like this:</p>
<pre>&lt;?php
     function add_author_photo($content) {
         ...
         return $content;
     }</pre>
<pre>     add_filter('the_content', 'add_author_photo');
?&gt;
</pre>
<p>Note how the entire filter is enclosed in a PHP container. This is important!  Now, all we need to do is fill in the &#8220;dots&#8221;.</p>
<p>First, we need to make sure that our function does its work in the right place since it will be called anytime WordPress fetches the content from the database. We want the thumbnail photo to appear in posts on the home page and on single post pages, but not on static pages (which are, in a sense, &#8220;authorless&#8221;) nor on the archive and search result pages and especially not in RSS feeds. The following if statement does what we want:</p>
<pre style="padding-left: 30px;">if (is_home() || is_single()) {
    ...
}
</pre>
<p>Next, the code needs to check that the image file we want for the current post author actually exists. The client may add more authors and contributors before their photos are available and we don&#8217;t want an ugly, empty missing-image square to appear where a nice photo is expected. This is a bit tricky. There&#8217;s a PHP function,<span style="font-family: andale mono,times;"> file_exists()</span>, for checking whether a file exists or not but it takes, as its argument, the full Unix path to the file, as opposed to a URL fragment. WordPress provides a function for doing this: <span style="font-family: andale mono,times;">get_theme_root()</span> which returns a string that, depending on your hosting company&#8217;s site configuration, might look like this:</p>
<p style="padding-left: 30px;"><tt> </tt><span style="font-family: andale mono,times;">/var/web/clients/abc.com/htdocs/wp-content/themes</span></p>
<p>Since my &#8216;authors&#8217; directory is at the same level in <span style="font-family: andale mono,times;">/wp-content</span> as the themes directory, all I have to do is replace the &#8216;themes&#8217; part in the string above with &#8216;authors/thumbs/&#8217; and append the image&#8217;s file name. The following two lines of code will assign the username to a variable and do the replacement using  PHP&#8217;s  <span style="font-family: andale mono,times;">str_replace()</span> function.</p>
<pre style="padding-left: 30px;">$author_uname = get_the_author_meta('user_login');
$author_photo = str_replace(
                    'themes',
                    'authors/thumbs/' . $author_uname . '.jpg',
                    get_theme_root() );</pre>
<p>We can check whether the file exists with another if statement:</p>
<pre style="padding-left: 30px;">if (file_exists($author_photo)) {
    ...
}
</pre>
<p>Now we are ready to add the  image tag to the beginning of the post content. I&#8217;ll add a CSS class, &#8216;authorImage&#8217;, to the image tag which I&#8217;ll use to make the image float left and set appropriate margins and padding (see below.) I&#8217;ll also enclose the image in an anchor tag that links the image to the author&#8217;s profile page. I&#8217;ve laid this out here in several lines for readability. The dot at the end of each line is the PHP concatenation operator.</p>
<pre style="padding-left: 30px;">$image_src = '/wp-content/authors/thumbs/' .
             $author_uname . '.jpg';

$content =  '&lt;a href="/author/' .
            $author_uname .
            '"&gt;&lt;img class="authorImage" src="' .
            $image_src .
            '" alt="' .
            get_the_author() .
            '" /&gt;&lt;/a&gt;' .
            $content;</pre>
<p>Here&#8217;s a screenshot of the final code I pasted into the theme&#8217;s functions file. Because I&#8217;m a nice guy, I added  /* comments */ to explain what was going on. Click on the image to open a text division with the actual code you can copy.</p>
<p>[RAW]</p>
<p><img class="alignnone size-full wp-image-850" title="Click for text version" onclick="$('#imageText').slideDown();" src="http://larryaronson.com/wp-content/uploads/add_author_photo.jpg" alt="Click for text version" width="490" height="249" /></p>
<div id="imageText" style="border: 1px solid #666666; padding: 0.5em; display: none; width: 490px; font-size: 0.85em;">
<pre>&lt;?php
/*  Add authors' photos to posts on the home and single-post pages.
     Copyright 2009 Larry Aronson.

     For a post author identified by username, if the image file:
	/wp-content/authors/thumbs/username.jpg
     exists, it will be prepended to the content, floating left
     of the text and linked to the author's profile page		*/

function add_author_photo($content) {
  if(is_home() || is_single()) {
    $author_uname = get_the_author_meta('user_login');
    $author_photo = str_replace('themes',
         'authors/thumbs/' . $author_uname . '.jpg',
         get_theme_root());
    if (file_exists($author_photo)) {
	 $image_src = '/wp-content/authors/thumbs/' . $author_uname . '.jpg';
	 $content = '&lt;a href="/author/' . $author_uname .
             '"&gt;&lt;img class="authorImage" src="' .
	     $image_src . '" alt="' . get_the_author() . '" /&gt;&lt;/a&gt;' .
             $content;
     }
  }
  return $content;
}

/* remove the following line to deactivate the add photo feature */
add_filter('the_content', 'add_author_photo');
?&gt;
</pre>
<p><a onclick="$('#imageText').slideUp();" href="javascript: void(0);#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed">click here to hide code.</a></p>
</div>
<p>[/RAW]</p>
<p>The final version took a bit of debugging to fix some stupid typing errors but it worked as I wanted it to. A look at the source code for the home page shows the generated image tag and link:</p>
<pre style="padding-left: 30px;">&lt;a href="/author/larryaronson"&gt;&lt;img class="authorImage"
   src="/wp-content/authors/thumbs/larryaronson.jpg"
   alt="Larry Aronson" /&gt;&lt;/a&gt;
</pre>
<p>All that remained was adding some simple CSS to the style sheet to float the image to the left of the post text. The rules shown below does that and sets appropriate margins.  The images already incorporated a border so I removed the border set elsewhere in the CSS and removed the drop shadow background that Mistylook adds to images as a matter of taste.</p>
<pre style="padding-left: 30px;">img.authorImage {
   float: left;
   margin: 0 1em 0 0;
   border: 0;
   padding: 0;
   background-image: none;
 }</pre>
<p>That&#8217;s it. I hope you found this article useful. Suggestions for improvements are welcome.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2009/add-author-photo-%e2%80%94-my-first-wordpress-filter/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Humintell Launches</title>
		<link>http://larryaronson.com/2009/humintell-launches/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2009/humintell-launches/#comments</comments>
		<pubDate>Fri, 31 Jul 2009 20:19:25 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[websites]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[David Matsumoto]]></category>
		<category><![CDATA[Dean Meyers]]></category>
		<category><![CDATA[Harbrooke Group]]></category>
		<category><![CDATA[Humintell]]></category>
		<category><![CDATA[Landsman]]></category>
		<category><![CDATA[microexpression analysis]]></category>
		<category><![CDATA[minimal]]></category>
		<category><![CDATA[online training]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=617</guid>
		<description><![CDATA[<a href="http://larryaronson.com/2009/humintell-launches/"><img class="alignleft size-thumbnail wp-image-618" title="Humintell" src="http://larryaronson.com/wp-content/uploads/Humintell-About1-117x150.jpg" alt="Humintell" width="75" height="85" /></a><a href="http://humintell.com/" target="_blank">Humintell.com</a>, a website project I worked on this past Spring for the <a title="Dean Landsman" href="http://www.land-com.net/" target="_blank">Landsman Communications Group</a> recently launched. Humintell is about Microexpression Analysis—the understanding of the underlying emotions of people by looking for universal facial expressions that flick on and off in  less than a second. I built the Humintell website using Wordpress, modifying the Minimal theme to match the graphical design, typography and layout from graphic designer, <a href="http://www.deanmeyers.net/" target="_blank">Dean Meyers</a>. ]]></description>
			<content:encoded><![CDATA[<p><a href="http://larryaronson.com/wp-content/uploads/Humintell-About1.jpg#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed"><img class="alignleft size-thumbnail wp-image-629" title="Humintell" src="http://larryaronson.com/wp-content/uploads/Humintell-About1-117x150.jpg" alt="Humintell" width="117" height="150" /></a><a href="http://humintell.com/" target="_blank">Humintell.com</a> is a website project I worked on this past Spring for the <a title="Dean Landsman" href="http://www.land-com.net/" target="_blank">Landsman Communications Group</a> on behalf of their client, <a title="David Matsumoto's website" href="http://www.davidmatsumoto.com/" target="_blank">David Matsumoto</a>, a pioneering researcher in the field of  Microexpression Analysis—understanding the underlying emotions of people by looking for universal facial expressions that flick on and off in  less than a second. Humintell seeks to provide online training in these skills and the website serves a the marketing vehicle for the business, a blog for discussing related issues, and a gateway to the custom training modules for subscribers.</p>
<p>I built the Humintell.com website in WordPress on top of Minimal, a free theme from <a title="The WordPress Themeshop" href="http://wpthemeshop.com/" target="_blank">The WordPress Theme Shop</a> that features variable width columns and other nice enhancements. The wonderful graphic design, typography and layout is from <a title="Dean Meyers - graphical design" href="http://www.deanmeyers.net/" target="_blank">Dean Meyers</a>, who added some of the playful visual effects used on the site. Dean Landsman of the <a title="Dean Landsman" href="http://www.land-com.net/" target="_blank">Landsman Communications Group</a> integrated the various online pieces into a coherent whole, creating/editing much of the initial content.</p>
<p>Congratulations, Humintell! And thanks to Howard Greenstein of The <a title="The Harbrooke Group" href="http://harbrooke.com/" target="_blank">Harbrooke Group</a> for referring me to Landsman.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2009/humintell-launches/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Double Bliss</title>
		<link>http://larryaronson.com/2009/double-bliss/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2009/double-bliss/#comments</comments>
		<pubDate>Wed, 18 Feb 2009 16:09:04 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[websites]]></category>
		<category><![CDATA[Ann Phelan]]></category>
		<category><![CDATA[Antigua]]></category>
		<category><![CDATA[Bonaire]]></category>
		<category><![CDATA[diving]]></category>
		<category><![CDATA[singles]]></category>
		<category><![CDATA[vacation]]></category>
		<category><![CDATA[windsurfing]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=330</guid>
		<description><![CDATA[<a href="http://larryaronson.com/2009/double-bliss/"><img class="alignleft  wp-image-332" title="Ann Phelan &#124; Bonaire Bliss" src="http://larryaronson.com/wp-content/uploads/bonairebliss.jpg" alt="Ann Phelan &#124; Bonaire Bliss" width="75" height="75" /></a>Ann Phelan has a dream job. She facilitates and books vacations to two of the best islands in the Caribbean, Bonaire and Antigua. I recently helped Ann create two sites: <a href="http://bonairebliss.com" target="_blank" title="Ann Phelan &#124; Bonaire Bliss">BonaireBliss.com</a> and <a title="Ann Phelan &#124; Antigua Bliss" href="http://AntiguaBliss.com" target="_blank">AntiguaBliss.com</a>,  to share her love of these two wonderful destinations.]]></description>
			<content:encoded><![CDATA[<p>Ann Phelan has a dream job. She facilitates and books vacations to two of the best islands in the Caribbean, Bonaire and Antigua. Moreover, she&#8217;s active in the communities on both islands which makes her an essential resource for anyone interested in visiting these two slices of paradise.</p>
<p><a href="http://BonaireBliss.com"><img class="alignleft size-full wp-image-332" title="Ann Phelan | Bonaire Bliss" src="http://larryaronson.com/wp-content/uploads/bonairebliss.jpg" alt="Ann Phelan | Bonaire Bliss" width="150" height="150" /></a>I first met Ann a few years ago when I answered her ad in <em>Windsurfing</em> Magazine for a Windsurfing singles week in Bonaire. It was a wonderful vacation with get-togethers every evening and optional activities during the day if the wind was too light to sail. Bonaire, a Dutch island off the coast of Venezuela, is for windsurfers and divers; Antigua, in the northeast corner of the Caribbean, has 365 beaches and and a hot nightlife.</p>
<p><a href="http://AntiguaBliss.com"><img class="alignright size-full wp-image-333" title="Ann Phelan | Antigua Bliss" src="http://larryaronson.com/wp-content/uploads/antiguabliss.jpg" alt="Ann Phelan | Antigua Bliss" width="150" height="150" /></a>A few months ago, we started talking about redoing her website. She wanted a separate destination site for each island and she wanted to be able to post articles, pictures and videos. I discussed with her the various hosting options available and the features and capabilities of WordPress. We decided the best approach was for her to start blogging on a free <a title="WordPress Free Hosting account" href="http://wordpress.com" target="_blank">WordPress.com</a> account to get familiar with the process. Later, if she needed additional technology—Wordpress.com limits what you can add to a site—we could move her blogs to a hosted solution.</p>
<p>The result has been immensely satisfying and quite beautiful to see. Ann has taken to blogging like a reef fish takes to the warm, clear blue waters of Bonaire and posts something new just about every day. She&#8217;s found her personal voice in writing posts which makes both sites authentic and appealing. She&#8217;s learned quickly the ins and outs of using images and embedding YouTube videos. Every time I visit <a title="Ann Phelan | Bonaire Bliss" href="http://BonaireBliss.com" target="_blank">BonaireBliss.com</a> or <a title="Ann Phelan | Antigua Bliss" href="http://AntiguaBliss.com" target="_blank">AntiguaBliss.com</a> I find something new to make me smile and warm my heart.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2009/double-bliss/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Lawyers In New Media</title>
		<link>http://larryaronson.com/2008/lawyers-in-new-media/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2008/lawyers-in-new-media/#comments</comments>
		<pubDate>Mon, 29 Dec 2008 15:00:28 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[websites]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[flash]]></category>
		<category><![CDATA[law]]></category>
		<category><![CDATA[lawyer]]></category>
		<category><![CDATA[Seashore]]></category>
		<category><![CDATA[Social Media]]></category>
		<category><![CDATA[video]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=190</guid>
		<description><![CDATA[<img src="/wp-content/uploads/digitalhhr.jpg" width="75" height="75" class="left" /> DigitalHHR –  I just completed this Wordpress blog for the Intellectual Property department of a major law firm. It features an integrated BBs, an event manager, feature-rich videos, a Flash-powered header,  customized navigation menu and special lawyer profile pages. ]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve just finished a project: <a href="http://digitalhhr.com" target="_blank">DigitalHHR</a> – a WordPress blog for the Intellectual Property department of a big law firm. The IP department, consisting of 4 lawyers, wanted a online platform to promote their ideas and opinions about intellectual property and generate good press for their firm. I was under contract to a wonderful creative agency, <a href="http://www.ahainsight.com/" target="_blank">Aha! Insight Technology</a> and was working again with <a title="Howard Greenstein's Website" href="http://harbroke.com" target="_blank">Howard Greenstein</a>. Howard provided the strategic direction, project management and training for the client while I provided the technology.</p>
<p><a title="digitalhhr" href="http://digitalhhr.com" target="_blank"><img class="alignright" src="http://larryaronson.com/wp-content/uploads/digitalhhr.jpg" alt="Home page of DigitalHHR" width="200" height="189" /></a></p>
<p>Howard proposed a robust set of features to showcase their familiarity with leading edge, social media technologies and services. The specifications called for an integrated BBs, an event manager, feature-rich videos, a Flash-powered header with a customized navigation menu tying it all together. Howard and I knew we were pushing the limits of WordPress and that&#8217;s what the client wanted to show off.</p>
<p>We started with a three column theme, <a title="Seashore Theme page" href="http://topwpthemes.com/seashore/" target="_blank">Seashore</a> by Sadish Bala. I added a video presentation space on top of the  sidebars and a game space below. With a bit of work, I was able to shoehorn the custom flash video the lawyers designed into the header code and replaced the generated navigation menu with a two-level structure.</p>
<p>The four lawyers were already blogging on other sites. This was their first opportunity, not only to write under their own brand, but to actually craft that brand as publishers and editors. As they began to post articles, they became concerned about their authorship rights —they&#8217;re IP lawyers, remember, and important ones at that! So, as we neared completion of the project, new feature requests started creeping in.</p>
<p>They wanted special lawyer profile pages so they could edit in additional content about themselves. These page would feature a portrait image and an expanded contact section with a download-able, virtual address card. For these special pages, I cloned the standard single page template and modified it to fetch the page author&#8217;s portrait photo from a sub directory of /wp-content. I setup custom fields for the contact information and displayed those next to the portrait image. Following that, I formatted a box to display the most recent posts by that author. Finally, I displayed whatever content they wanted to add via the post editor.  <a title="Using custom fields in a wordpress template" href="javascript:void window.open('/wp-content/uploads/lawyer-page_code.gif', 'popit', 'scrollbars=0,height=764,width=772');#utm_source=feed&amp;utm_medium=feed&amp;utm_campaign=feed">Click here to see some of the code</a>.</p>
<p>The head partner of the IP division liked the profile page so much that he wanted a special version just for himself that also displayed  any press articles written about him. I figured out how to accomplish that using a custom post field and some more template programming.</p>
<p>They also wanted to post co-authored articles. I know that there was third-party plug-in that did something like that, but at this late stage of the project, it was easier to add more template modifications to get exactly the functionality the client wanted. The solution we devised features a double portrait image, double email links and a hook to pick up the post for the special lawyer profile pages.</p>
<p>It&#8217;s been exciting to watch this blog progress from it&#8217;s initial launch last month. Everything we did is being used by the client and it&#8217;s all working well.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2008/lawyers-in-new-media/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Here&#8217;s a Tip</title>
		<link>http://larryaronson.com/2008/heres-a-tip/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2008/heres-a-tip/#comments</comments>
		<pubDate>Wed, 24 Sep 2008 12:41:05 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[FAQ]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[sidebar]]></category>
		<category><![CDATA[styles]]></category>
		<category><![CDATA[tip]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=35</guid>
		<description><![CDATA[How to add a floating tipbox or editorial sidebar to a post in your Wordpress blog. I'm wrote this to answer a question from a client and it just made more sense to demonstrate the technique in a post rather than explain it in an email. ]]></description>
			<content:encoded><![CDATA[<p>Here&#8217;s how to add a floating tipbox or editorial sidebar to a post in your WordPress blog. I&#8217;m writing this to answer a question from a client and it just made more sense to demonstrate the technique in a post rather than explain it in an email.  The floating tipbox that appears below duplicates the example my client provided. The text explains how to create and customize a box to your own specifications.</p>
<p>First, make sure you are logged in as an administrative user. Go to the site admin area (also called the dashboard) and click on the <strong>Design</strong> tab; then click on the submenu tab, <strong>Theme Editor</strong>. You should now be looking at a page with a text editing window on the left and a list of theme files on the right. <em>Stylesheet (style.css)</em> should be the active file in the edit window. If it&#8217;s not, then select it from the bottom of the list on the right.</p>
<div class="tipbox">The exact formatting isn&#8217;t important. Essentially, it&#8217;s a named set of rules where each rule is composed of a selector, followed by a colon (:) followed by a value or list of values. The individual rules are separated by semi-colons and the order doesn&#8217;t matter. The entire set of rules is enclosed in braces ({}) preceded by the set&#8217;s name. If you want to, you can put it all on one line.  Just make sure you begin the name with a period (.). That identifies this rule set as a &#8220;class&#8221;.</div>
<p>Scroll to the bottom of the stylesheet file and add the follow lines. Don&#8217;t worry, you only have to do this step once:</p>
<pre><span style="font-size: 0.9em; color: #006600;">.tipbox {
 max-width: 33%;
 float: right;</span>
<span><span style="font-size: 0.9em; color: #006600;"> font-size: .66em;
</span></span><span style="font-size: 0.9em; color: #006600;"> padding: 1em;
 border-width: thick thin thin thin;
 border-style: solid;
 border-color: grey;
}</span></pre>
<p>Click the button labeled &#8220;Update File&#8221; to save your additions to the stylesheet.</p>
<p>Now, back in the post editor, edit your post as usual. The content of the tipbox should be entered just as if it were an ordinary text, but place that text before the content that you want to flow around the tipbox. Here, we just have one paragraph of text in the box but you can have any content—headings, lists, images, etc., in an floating box.</p>
<p>Once all of your content is in place, click the tab labeled, <strong>HTML</strong>, at the top of the editing area. The content of the editing area will change showing the marked up content instead of the WYSIWYG version. Find your tipbox content and insert the following text immediately in front of it:</p>
<pre><span style="font-size: 0.9em; color: #006600;">&lt;div class="tipbox"&gt;</span></pre>
<p>and the following text immediately after the content:</p>
<pre><span style="font-size: 0.9em; color: #006600;">&lt;/div&gt;</span></pre>
<p>Click the <strong>Visual</strong> tab to return to the WYSIWYG mode and save the draft. The  WYSIWYG mode doesn&#8217;t recognize the floating mode, so you&#8217;ll have to click on the &#8220;Preview this Post&#8221; button to see if it worked.</p>
<p>You can create as many tipboxes as you&#8217;d like. Enclose any content in a set of division tags  with the class assigned to tipbox – headings, paragraphs, lists, whatever, it will be boxed and floated on the right margin.</p>
<h3>Customizing the tipbox.</h3>
<p>Let&#8217;s take a look at the details and see how they can be changed to achieve different effects. The rules added to the stylesheet do this by giving your browser the following instructions:</p>
<ul>
<li>Set our tipbox to occupy no more than 1/3 (33%) of the available column width. Unlike an image element, which has a fixed width, a division element normally takes up 100% of the width available, so, we have to tell it to take less.  You can also supply a fixed value, e.g:   <span style="font-size: 0.9em; color: #006600;">max-width: 200px;</span></li>
<li>This tipbox element should float on the right margin of the column and whatever content follows this element should wrap around it on the left. This and the previous rule are required to create the sidebar or cutout element; everything else is decoration.</li>
<li>Make the font size 2/3 of what it would normally be. &#8216;em&#8217; is a measurement unit equal to the width of the letter &#8216;m&#8217;. We could have also stated the size using a percent or other measurement units: 66%, 9pt, 12px, for example, but em works better for a number of reasons.</li>
<li>Put 1 em worth of space as padding between the border of the tipbox and the content inside. Space is important for readability.</li>
<li>Give tipbox a thick border on top with thin borders on the right, bottom and left sides. Borders can also set set as pixels, l.e:  <span style="font-size: 0.9em; color: #006600;">border-width: 5px 2px 2px 2px</span>, would be about the same in this example</li>
<li>Make the border a solid line. It could also be dashed, dotted, double, inset and outset.</li>
<li>Make the border grey, You can also give it an explicit color value as an RBG value. see below</li>
</ul>
<p>Here&#8217;s a set of rules that, instead of a border, creates a class called &#8216;bluebox&#8217; that uses different background and foreground colors to visually define a floating box:</p>
<div class="bluebox"><span style="font-size:14pt">Tip:</span><br />
Keep a list somewhere of the styles you add to your stylesheet so you don&#8217;t reinvent the wheel the next time you need one.</div>
<pre><span style="font-size: 0.9em; color: #006600;">.bluebox {
 max-width: 150px;
 float: left;</span>
<span><span style="font-size: 0.9em; color: #006600;"> font-size: 9pt;
 margin-right: 8px;
</span></span><span style="font-size: 0.9em; color: #006600;"> padding: 5px;
 color: #ffffe0;                 /* light yellow text */
 background: #000066;    /* on a dark blue background */
}

</span></pre>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2008/heres-a-tip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New Critics Rescued</title>
		<link>http://larryaronson.com/2008/newcritics-rescued/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2008/newcritics-rescued/#comments</comments>
		<pubDate>Fri, 15 Aug 2008 21:19:41 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[Portfolio]]></category>
		<category><![CDATA[websites]]></category>
		<category><![CDATA[new critics]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=25</guid>
		<description><![CDATA[<a href="http://larryaronson.com/2008/newcritics-rescued/"><img class="left" src="/wp-content/uploads/newcritics_screenshot.jpg" width="75" height="75" /></a>Tom Watson's New Critics blog, had been hacked and he needed someone to rescue it. The site had been built on an old version of Wordpress and lived on a hosting service that Tom was no longer happy with. I was able to recover and export his content to rebuild the blog on a modern platform. Tom was back in business in a little more than a day.]]></description>
			<content:encoded><![CDATA[<p>Tom Watson&#8217;s &#8220;labor of love,&#8221; the <a title="New Critics" href="http://NewCritics.com" target="_blank">New Critics</a> blog, had been hacked and he had to bring it down.</p>
<p><a class="alignleft" title="New Critics" href="http://NewCritics.com" target="_blank"><img class="alignleft size-medium wp-image-26" title="New Critics Weblog" src="http://larryaronson.com/wp-content/uploads/newcritics_screenshot.jpg" alt="" width="200" height="208" /></a>I had just returned from my honeymoon and my home office had been in disarray for months. Helping Tom promised to be more fun than doing my taxes. It was. I like New Critics and regret that I haven&#8217;t had any time in this busy year to contribute.</p>
<p>Tom had built New Critics on an older version of WordPress and needed to upgrade to prevent another hack. He wasn&#8217;t happy with his current hosting arrangement either and wanted to move the site to a hosting company with more services and better support.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2008/newcritics-rescued/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Conversation Hub Rebuilt</title>
		<link>http://larryaronson.com/2008/conversation-hub-rebuilt/#utm_source=feed&#038;utm_medium=feed&#038;utm_campaign=feed</link>
		<comments>http://larryaronson.com/2008/conversation-hub-rebuilt/#comments</comments>
		<pubDate>Thu, 10 Jul 2008 16:44:27 +0000</pubDate>
		<dc:creator>Larry Aronson</dc:creator>
				<category><![CDATA[Business]]></category>
		<category><![CDATA[websites]]></category>
		<category><![CDATA[Supernova]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://larryaronson.com/?p=27</guid>
		<description><![CDATA[Kevin Werbach was in trouble. He was coordinating activities for Supernova 2008 and had used a local connection (i.e. cheap labor) to redesign Conversation Hub, the conference&#8217;s weblog. The new design was good but it was executed with old technology that just didn&#8217;t integrate with WordPress. Moreover, it was a cross-browser mess. Blogs do things [...]]]></description>
			<content:encoded><![CDATA[<p>Kevin Werbach was in trouble. He was coordinating activities for <a title="Supernova 2008" href="http://supernova2008.com/" target="_blank">Supernova 2008</a> and had used a local connection (i.e. cheap labor) to redesign <a title="Conversation Hub" href="http://conversationhub.com" target="_blank">Conversation Hub</a>, the conference&#8217;s weblog. The new design was good but it was executed with old technology that just didn&#8217;t integrate with WordPress. Moreover, it was a cross-browser mess. Blogs do things differently than the webtools many designers are still using to create brochureware. They tend to use simple lists and rely on CSS for layout and positioning rather than nested tables. This makes for faster rendering, easier modifications and better search engine visibility.</p>
<p><a title="Conversation Hub" href="http://conversationhub.com" target="_blank"><img class="right" style="float: right; margin-left: 6px; margin-right: 6px;" title="Conversation Hub" src="http://larryaronson.com/wp-content/uploads/conversationhub_screenshot.jpg" alt="Converssation Hub" width="200" height="188" /></a>Conversation Hub was also running on a very old version of WordPress and needed an upgrade to take advantage of the newer editing and media management tools and plug-ins available. I was able to upgrade the site, lay in the design changes and install/configure the new plug-ins in plenty of time to meet the conference deadlines.</p>
]]></content:encoded>
			<wfw:commentRss>http://larryaronson.com/2008/conversation-hub-rebuilt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

