Posts Tagged ‘Functions’

We are pleased to present below all posts tagged with ‘Functions’.

WordPress Functions To Make Blogging Easier

The WordPress functions.php theme file provides an efficient way of modifying WordPress on a theme by theme basis. This file contains mostly theme related functions but it can also be used to enhance or modify default WordPress behavior. This file is saved inside the themes' folder and a limitless amount of modifications can be added.

WordPress Functions.php overview

In this article I'd like to share a few helpful functions that use WordPress default code to modify or enhance our blog's behavior. By relying on default code we can program changes that will work on all versions of WordPress and in all themes. Any modifications added to the functions.php file will only activate on the current theme, giving us control over changes on a theme by theme basis. As opposed to creating a plugin, using this file for customizations allows us to control which theme does or does not benefit from any changes.

Read more...

WordPress Shortcodes: A Complete Guide

WordPress shortcodes were introduced in version 2.5 and since then have proved to be one of the most useful features. The average user acting as editor has the ability to publish dynamic content using macros, without the need for programming skills.

When a shortcode is inserted in a WordPress post or page, it is replaced with some other content. In other words, we instruct WordPress to find the macro that is in square brackets ([]) and replace it with the appropriate dynamic content, which is produced by a PHP function.

Read more...

Inside The WordPress Toolbar

The WordPress Admin Bar, first introduced in version 3.1, debuted to mixed reactions. A Google search for “wordpress admin bar” returns multiple articles about how to disable or remove it. Version 3.2 of WordPress introduced new features and functionality, and version 3.3 has not only further enhanced it but integrated the header of the admin section into the bar itself.

Inside the WordPress Toolbar

Since this feature is not going anywhere and it figures largely in WordPress’ plan to implement front-end editing, I think we would all benefit from looking at where its features come from and how best to make this sometimes controversial feature work for us.

Read more...

Limiting The Visibility Of Posts In WordPress Via Usernames

Controlling who is able to view a post is a simple task once the system is established. Limiting access to certain users has several advantages, ranging from a design studio distributing artwork among various clients, or a small school arranging to have its students' homework posted online through a cheap and easy solution.

Limiting The Visibility Of Posts Via Username

The easiest method to get this system working is to make the receivers of the information subscribers (since they will not be able to post), and the distributors of information authors (since they can only edit their own posts). This system eliminates several headaches for a website owner by managing who has access to specific posts. The username will be used for identification of who is allowed to view certain posts since it is unique and, for the most part, constant.

Read more...

WordPress Multisite: Practical Functions And Methods

Multisite is a powerful new feature that arrived with the release of WordPress 3.0. It allows website managers to host multiple independent websites with a single installation of WordPress. Although each “website” in a network is independent, there are many ways to share settings, code and content throughout the entire network.

WordPress Multisite: Practical Functions And Methods

Since the beginning of the year, I’ve been developing themes and plugins for a WordPress Multisite-powered content network. During that time I’ve learned many powerful tips and tricks unique to Multisite. This guide will introduce you to a few Multisite-specific functions, along with real-world programming examples that you can begin using today. Hopefully, it will open your eyes to a few of the new possibilities available in Multisite.

Read more...

WordPress Essentials: The Definitive Guide To WordPress Hooks

If you’re into WordPress development, you can’t ignore hooks for long before you have to delve into them head on. Modifying WordPress core files is a big no-no, so whenever you want to change existing functionality or create new functionality, you will have to turn to hooks.

wp-hooks-guide

In this article, I would like to dispel some of the confusion around hooks, because not only are they the way to code in WordPress, but they also teach us a great design pattern for development in general. Explaining this in depth will take a bit of time, but bear with me: by the end, you’ll be able to jumble hooks around like a pro.

Read more...

How To Create Custom Post Meta Boxes In WordPress

What seems like one of the most complicated bits of functionality in WordPress is adding meta boxes to the post editing screen. This complexity only grows as more and more tutorials are written on the process with weird loops and arrays. Even meta box "frameworks" have been developed. I'll let you in on a little secret though: it's not that complicated.

sm-wp_meta-boxes

Creating custom meta boxes is extremely simple, at least it is once you've created your first one using the tools baked into WordPress' core code. In this tutorial, I'll walk you through everything you need to know about meta boxes.

Read more...

↑ Back to top