Press "Enter" to skip to content

Month: September 2014

Theming in WordPress without Sacrificing the Dashboard

When theming in WordPress, we often face this dilemma of how to balance writing custom code and maintaining a manageable dashboard. How much freedom is too much when we’re creating something for our users? And if we really do need all these bells and whistles, how do we ensure the dashboard still makes sense?

After working on a good number of WP builds and learning from mistakes over the years, there are a few rules that I’ve set for myself that help to resolve this dilemma along with a few plugins that make life a bit easier for both the dev and the user.

2 Comments

My First Time Attending WordCamp NYC 2014

A month has passed since my first time attending WordCamp NYC 2014 in good ‘ole Brooklyn. It was a new experience, admission was cheap, and I still don’t know what to do with all the stickers and buttons I admittedly hoarded from the booths. ( I have this thing where if it’s free, well hell, I think I’ll help myself, thank you. ) In all seriousness, the entire conference was awesome and totally worth it. Only from attending on Saturday, I’ve decided to become a WC NYC attendee forever!

Being a WordCamp noob, there were a few things that surprised me, terrified me, and all in all, a lot that I learned from the adventure that I hope to share with people thinking of trying it out as well – or people just wanting another perspective on it.

2 Comments

How to add background videos to your WordPress posts

Gasp! This is really cool, guys! How to add background videos to your WordPress Posts @ wpmudev.org. It involves a plugin for shortcode usage, and…

Leave a Comment

How to Add Counter Classes with a Global Variable

Ever wonder how to add counter/numbered classes to your posts? Is this the fourth post or the seventh? Well, if you have wished upon a star (or even if you didn’t, but it was more like cursing out your computer, that’s fine too), then your wish is about to come true with this tutorial.

In this tutorial’s example, we want our blog posts to have classes like “article-number”, and we can achieve this using the post_class(); function and a counter that we’ll set as a global variable.

It’s not as hard as you think. Also, keep in mind that this is a technique that can be applied to other scenarios too, and it’s not limited to just adding classes to our blog posts. Well, let’s get started, shall we?

Before we begin:

  1. Some familiarity with loops and general PHP will help.
  2. Might want to review what variables are. I also go over variables with better analogies in an old article of mine on the Pixafy Blog: Understanding WordPress’ $args Variable
  3. Make sure you have a theme that you can edit files in – for my example, I’m using TwentyThirteen. The files I’ll be working in are: functions.php, index.php, and content.php.

What we’re going to achieve:

global-results

Leave a Comment

Underscores: A Starter Theme for WordPress

I love it when I discover cool new sites! It’s a theme meant for hacking and learning to build themes – have at it! http://underscores.me/

Leave a Comment