Blog

How to Create WordPress Posts in Themes/Plugins

You are here: Home > Blog > PHP

How to Create WordPress Posts in Themes/Plugins

User-Submitted Posts in WordPress

Recently, one of our clients needed to let visitors create WordPress posts (Or custom post types of course) from the website itself.

In this post, I’m going to walk through some of the WordPress functions I used to achieve this. We’ll go over creating the post itself, adding categories/tags, and adding metadata.

Read More »

How to Get Facebook, Twitter, and RSS Counts {WP}

Twitter, Facebook, RSS Counts

You will have seen blogs showcase their Twitter, Facebook, and RSS counts with typography. With these numbers in plain text, you can style them into your website far more effectively than if you were to use the old-fashioned “chicklets.”

Twitter and Facebook make this easy, but you’ll need to take an extra step with FeedBurner first. Log in, then click Publicize > Awareness API, and click activate.

All set? Then let’s get started!

Read More »

Add a jQuery DatePicker to Event Posts {WP}

jQuery Events DatePicker in WordPress

In previous posts, we set up an events system for WordPress. Users could enter the date of an event, and we had great archives for displaying and categorizing them.

Today, we want to improve the admin end of things. Instead of using custom fields, we’ll make a box for the event’s date, and use jQuery to let users pick the date from a calendar.

Read More »

How to Use the Twitter API in WordPress

Twitter with WordPress

There are plenty of Twitter plugins for WordPress. Why would we want to make our own script?

Well, most of the plugins come with a lot of fluff you just don’t need. Ours will be simple and efficient; all it needs to do is grab your tweets and display them.

The other reason is control; you write the markup, so it’s entirely up to you how it is displayed.

The last reason is that because we’re getting the tweets directly from the Twitter API feeds (i.e. no verification is going to be needed), we can easily display tweets from a Twitter List instead of just our own tweets.

Read More »

How to Create Image Galleries in Your Theme

WordPress makes it straightforward to create a gallery from the images attached to a post. Just a couple of clicks and the gallery shortcode will be inserted into your post for you.

Why not make it even easier though? In this post, I will walk you through adjusting your theme to automatically insert a gallery after every post.

We’ll also limit how many images show up in the gallery (The rest can be shown on the individual image pages themselves), and exclude our post’s featured image if it has one.

Read More »

How to Get Your Twitter Follower Number in Plain Text

Twitter Follower Count in Plain Text

It’s easy to use a service like TwitterCounter.com to get a little chicklet button of your Twitter follower number. If you have that number in plain text though, then you can style and integrate it into your site much more attractively. In this post, I’ll show you how to get it.

You can see the end result in the top right of Tiny Buddha, a site I recently coded using Chameleon (Though this will work on any WordPress theme!)

Read More »

Working With WordPress Shortcodes

WordPress shortcodes are used frequently in plugins and themes as a way to achieve extra functionality, without the need to modify template files. You just type the shortcode word right into your post. Some plugins and themes use them to add event calendars, some for making announcements, while others use them for inserting contact forms.

Simply, WP shortcodes are awesome.

However, what if you’re a theme / plugin developer wishing to use them for your next great product, but you have no idea where to start? We’re going to fix that in this tutorial.

Read More »

Page 1 of 41234