Customized WordPress Date Button
When I created a custom date button on Zain’s Blog people really liked it. It was a well planned out design. Then I thought it would make a great post if I show you guys how to make a Customized Wordpress Date Button.
Why should you get a customized date button? Simple. It looks cool. It goes with some themes and doesn’t go with others. I think it just spice up some themes if used correctly. For this tutorial: I am assuming you can make your own graphics, if you are not using mine. You have little knowledge of html and css (I mean you know how the div tags and padding works). The final outcome of this tutorial should look like the image on your right.
This is a 3 step tutorial. First we will add the day of the month, then we will add the month, and then finally it will be the year.
We will be using the following image as our background:

First thing you want to do is make a class in your css file that is called .datebg and set your background image.
.datebg{
background: url(images/datebg.gif) no-repeat;
height: 150px;
width: 150px;
}
Than insert it in the appropriate wordpress file. Hint: index.php, single.php…
So right now your codes should be looking like this:
<div class="datebg">
</div>
Now you need to add another class and call it .day and set the appropriate margin and CSS. Choose your color and font-size. Insert that class inside your datebg class.
Within your .day class insert the following codes: <?php the_time(‘d’) ?>
This will allow you to display the date, so like today is the 22nd so thats what it will show you.

Now you need to go ahead and add another class in your css file and name it .month and add the appropriate margin and padding to it. Insert it right after your .day class in the template files.
Within this class you need to add: <?php the_time(‘M’) ?>
This will display the month of the year like in the picture shown below:

Then you will need to make another class and name it .year. Set the appropriate padding and margins. Insert it right after your month class.
Then within this class add the following codes: <?php the_time(‘Y’) ?>
This will display the year.

So in the end your template files should look like this:
<div class="datebg">
<div class="day"><?php the_time(‘d’) ?></div>
<div class="month"><?php the_time(‘M’) ?></div>
<div class="year"><?php the_time(‘Y’) ?></div>
</div>
Now you have your own customized wordpress date button. Feel free to use my image in this post. I made it 150 x 150px so people can make it smaller and not lose quality. If you are just wondering how the heck do I enter plain simple date like Balkhis have.
Then just plain enter <?php the_time(‘M j, Y’) ?>
This will give you an outcome like Aug 22, 2008.
Enjoy.
Note: Do not copy and paste codes. Type it down by looking at these.














Well I see that some people like to complain that they spend too much time on a blog and not get enough results therefore they think blogging is a waste of time. I also see some advising others on the forum that don’t rely entirely on blogging which is fine. But what I don’t understand is how long does it take you to write a post? An hour or two? thats it if you write quality posts. If you are Bs’ing a post then you can do that in 25 minutes. There are ways you can speed up your post writing process and those are shortcuts.
Don’t sound like a SPAM Email. Give your email a voice. Show to them that you have atleast take some effort in writing. I mean why should I write about your blog post or product if you can’t even put some effort in writing an email to me? So think yourself in other person’s shoe. It won’t benefit me either way. Have a friendly tone. Don’t ask them outright to link to you. First Introduce yourself. Because you want them to know a little about you before they link to you. Make connections that is all what blogging is about. Don’t drag your email to 2000 words. Make it short and quick because considering that I get 300+ emails every day. I don’t want to read your 2000 word email asking me to link to you. Summarize a little what is this product that you want me to link to. Because if you don’t then I don’t really want to click on the link with an anchor Click HERE.
Be Generous in your own link roundups. Basically do some link love. Make friends. You have to give some to get some back. So if you don’t write about other people why should they write about you? So if you see something you like than write about it. This was one of the reasons why I started doing my weekly link roundups because I want to share the love in the blogosphere.













Hey, I am Syed Balkhi, The guy who is behind Balkhis Inc. I entered the industry back in 2002 not knowing a single thing. I barely spoke English at that time. In the past six years, my language barrier has been eliminated. Aside from English, now I also speak html, and php. Along with the languages I have also managed to master a few arts. Art of web-designing started when I first entered. Messing around with photoshop, I learned how to create my first web design. Now I founded a web designing firm Uzzz Productions. After running numerous amount of websites in various niche, I have mastered the art of web-development. Now I am compiling a resource of what I already know, and what I am learning on this blog. This resource is to help me if I ever need a guide to look back to, and it is help my fellow webmasters.



