Book Image

WordPress Web Application Development

By : Rakhitha Nimesh Ratnayake
Book Image

WordPress Web Application Development

By: Rakhitha Nimesh Ratnayake

Overview of this book

Developing WordPress-powered websites is one of the standout trends in the modern web development world. The flexibility and power of the built-in features offered by WordPress has made developers turn their attentions to the possibility of using it as a web development framework. This book will act as a comprehensive resource for building web applications with this amazing framework. "WordPress Web Application Development" is a comprehensive guide focused on incorporating the existing features of WordPress into typical web development. This book is structured towards building a complete web application from scratch. With this book, you will build an application with a modularized structure supported by the latest trending technologies. "Wordpress Web Application Development" provides a comprehensive, practical, and example-based approach for pushing the limits of WordPress for web applications beyond your imagination. This book begins by exploring the role of existing WordPress components and discussing the reasons for choosing WordPress for web application development. As we proceed, more focus will be put into adapting WordPress features into web applications with the help of an informal use-case-based model for discussing the most prominent built-in features. While striving for web development with WordPress, you will also learn about the integration of popular client-side technologies such as Backbone, Underscore, and jQuery, and server-side technologies and techniques such as template engines, RSS feeds, Open Auth integration, and more. After reading this book, you will possess the ability to develop powerful web applications rapidly within limited time frames with the crucial advantage of benefitting low-budget and time-critical projects.
Table of Contents (18 chapters)
WordPress Web Application Development
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Preface

Developing WordPress-powered websites is one of the standout trends in the modern web development world. The flexibility and power of the built-in features offered by WordPress has made developers turn their attention to the possibility of using it as a web development framework. This book will act as a comprehensive resource for building web applications with this amazing framework.

WordPress Web Application Development is a comprehensive guide focused on incorporating the existing features of WordPress into typical web development. This book is structured towards building a complete web application from scratch. With this book, you will build a portfolio management application with a modularized structure supported by the latest trending technologies.

This book provides a comprehensive, practical, and example-based approach for pushing the limits of WordPress to create web applications beyond your imagination.

It begins by exploring the role of existing WordPress components and discussing the reasons for choosing WordPress for web application development. As we proceed, more focus will be put into adapting WordPress features into web applications with the help of an informal use-case-based model for discussing the most prominent built-in features. While striving for web development with WordPress, you will also learn about the integration of popular client-side technologies such as Backbone.js, Underscore, jQuery, and server-side technologies and techniques such as template engines and OpenAuth integration.

This book differentiates from the norm by creating a website that is dedicated to providing tutorials, articles, and source codes to continue and enhance the web application development techniques discussed throughout this book. You can access the website for this book at http://www.innovativephp.com/wordpress-web-applications.

After reading this book, you will possess the ability to develop powerful web applications rapidly within limited time frames with the crucial advantage of benefitting low-budget and time-critical projects.

What this book covers

Chapter 1, WordPress As a Web Application Framework, walks you through the existing modules and techniques to identify their usage in web applications. Identification of WordPress features beyond the conventional CMS and planning portfolio management application are the highlights of this chapter.

Chapter 2 , Implementing Membership Roles, Permissions, and Features, begins the implementation of a portfolio management application by exploring the features of the built-in user management module. Working with various user roles and permissions as well as an introduction to the MVC process through routing are the highlights of this chapter.

Chapter 3, Planning and Customizing the Core Database, serves as an extensive guide for understanding the core database structure and the role of database tables in web applications. Database querying techniques and coverage of the planning portfolio management application database are the highlights of this chapter.

Chapter 4, The Building Blocks of Web Applications, explores the possibilities of extending WordPress posts beyond their conventional usage to suit complex applications. Advanced use of custom post types and an introduction to template engines are the highlights of this chapter.

Chapter 5, Developing Pluggable Modules, introduces the techniques of creating highly reusable and extensible plugins to enhance the flexibility of web applications. Implementing various plugins for explaining these techniques is the highlight of this chapter.

Chapter 6, Customizing the Dashboard for Powerful Backends, walks you through the process of customizing the WordPress admin panel for adding new features as well as changing existing features and design. Building reusable grids and designing an admin panel are the highlights of this chapter.

Chapter 7, Adjusting Themes for Amazing Frontends, dives into the techniques of designing amazing layouts, thereby opening them for future extension. Widgetizing layouts and building reusable templates are the highlights of this chapter.

Chapter 8, Enhancing the Power of Open Source Libraries and Plugins, explores the use of the latest trending open source technologies and libraries. Integrating open authentication in to your web application and structuring the application at the client side are the highlights of this chapter.

Chapter 9, Listening to Third-party Applications, demonstrates how to use WordPress XML-RPC API to create a custom API for your web application. Building a simple yet complete API with all the main features is the highlight of this chapter.

Chapter 10, Integrating and Finalizing The Portfolio Management Application, guides you through the integration of modules developed throughout this book into a standalone plugin while introducing you to important concepts such as caching, security, and testing.

Appendix, Configurations, Tools, and Resources, provides an application setup guide with necessary links to download the plugins and libraries used throughout the book.

What you need for this book

Technically, you need a computer, browser, and an Internet connection with the following working environment:

  • The Apache web server

  • PHP Version 5.2 or higher

  • WordPress Version 3.6

  • MySQL Version 5.0 or higher

Once you have the preceding environment, you can download the Responsive theme from http://wordpress.org/themes/responsive and activate it from the Themes section. Finally, you can activate the plugin developed for this book to get things started.

Please refer to Appendix, Configurations, Tools, and Resources, for the application setup guide, required software, and plugins.

Who this book is for

This book is intended for WordPress developers and designers who have the desire to go beyond conventional website development to develop quality web applications within a limited time frame and for maximum profit.

Experienced web developers who are looking for a framework for rapid application development will also find this to be a useful resource.

Prior knowledge of WordPress is preferable as the main focus will be on explaining methods for adapting WordPress techniques for web application development rather than explaining basic skills with WordPress.

Conventions

In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.

Code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows: "WordPress passes existing MIME types as the parameter to this function. Here, we have modified the $mimes array to restrict the image types to JPG."

A block of code is set as follows:

function filter_mime_types($mimes) {
    $mimes = array(
      'jpg|jpeg|jpe' => 'image/jpeg',
    );

    return $mimes;
}

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

public function flush_application_rewrite_rules() {
  $this->manage_user_routes();
  flush_rewrite_rules();
}

New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "Once the user fills the data and clicks on the Register button, we have to execute quite a few tasks in order to register a user in the WordPress database."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.

To send us general feedback, simply send an e-mail to , and mention the book title via the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your book, clicking on the errata submission form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded on our website, or added to any list of existing errata, under the Errata section of that title. Any existing errata can be viewed by selecting your title from http://www.packtpub.com/support.

Piracy

Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works, in any form, on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at with a link to the suspected pirated material.

We appreciate your help in protecting our authors, and our ability to bring you valuable content.

Questions

You can contact us at if you are having a problem with any aspect of the book, and we will do our best to address it.