By Ed Reckers on April 17, 2012
I was finally moved to “Request an Invite” at Pinterest this evening and when I received the initial email I was amazed at how simple it really was. I mean, this coming from the fastest growing social network ever. It goes to show, not everything needs to be over designed. In fact, it looks like in order to become the fast growing site around you may just want to send your customers simple text emails that look like this:

Thanks for Joining the Pinterest Waiting List
I don’t know how much I’ll ever use Pinterest the social network, but I will be coming back to this post everytime I’m banging my head against the keyboard thinking that even my emails need to be stylized.
Posted in Blogging |
By Ed Reckers on April 13, 2012
Finally got tired of manually wrapping print_r in <pre> tags so I’m just going to drop this here for future reference:
// wrap print_r in preformatted text tags
// usage: print_pre($value)
function print_pre($value) {
echo "<pre>",print_r($value, true),"</pre>";
}
Basically, using print_pre (if the name doesn’t collide w/ another function in your program) will work just like print_r except of course wrap the output in preformatted text tags <pre>.
I do a lot of work in WordPress so if you can just drop this into your functions.php file if you’d like to use it. The same goes for Drupal, add it to your themes file for easy access. Another option I supposed would be to prepend it to your PHP documents but I’m just speculating right now and that could turn out not so good.
Anyways, print_pre can be used in place of print_r to dump output of print_r pre wrapped in pre tags.
References:
This is probably the better long term solution:
Posted in Development |
By Ed Reckers on April 12, 2012
There are a number of WordPress Plugins that appear to allow you to auto-post your WordPress blog posts to Twitter, Facebook, and LinkedIn. However, I am going with a service called dlvr.it to help me post my WordPress blog posts to Twitter.
It’s a simple matter of adding your source, in this case your WordPress Feed, and then adding and authorizing your destination account, which would be Twitter.
The UI is pretty straight forward and it allows you to forgo loading another WordPress Plugin to simply allow you to feed your blog posts to your Twitter account.
Posted in WordPress |
By Ed Reckers on April 8, 2012
Per client request I was asked that the WPtouch menu default to toggled open when on the frontpage . There may be more elegant solutions, but in order to achieve this I ended up editing a single WPtouch plugin file. If you’re going to do this make sure your code is in version control so that you can easily identify and add back the changes after any plugin update.
Now, to update WPtouch to start with an expanded menu on your homepage/frontpage open header.php for the WPtouch theme that you are using. In my case:
themes/classic/iphone/header.php
Around line 64 is the menu containing div id, id=”main-menu”:
<!-- This brings in menu.php // remove it and the whole menu won't show at all -->
<?php if ( wptouch_has_menu() ) { ?>
<div id="main-menu" class="closed">
<!-- The Hidden Search Bar -->
What you’ll want to do is add an if statement checking for is_front_page and if true you’ll go ahead and add a style to display, style=”display: block;”:
<!-- This brings in menu.php // remove it and the whole menu won't show at all -->
<?php if ( wptouch_has_menu() ) { ?>
<?php if ( is_front_page() ) : ?>
<div id="main-menu" class="closed" style="display: block;">
<?php else : ?>
<div id="main-menu" class="closed">
<?php endif; ?>
<!-- The Hidden Search Bar -->
That should do it.
Editing header.php of your chosen WPtouch mobile theme as seen above should get you an expanded menu (if you’re using the menu) on front-page visits.
Posted in WordPress | Tagged wordpress code snippets, wordpress development, wordpress plugins, wordpress snippets |