Sunday, September 6, 2015

Out-of-the-Box WordPress: Bundling With Themes & Plugins and wp-config Tweaks

Ten years after the first release of WordPress, the installation process is still kind of... boring. Move the core WordPress files, install WordPress, then install plugins and themes, switch themes... Is there quicker way to install WordPress?

Well, there is.

Warning: This is a tutorial for all levels of WordPress users, but I kept the tutorial short to be compatible with most hosting environments. I know that we can install WordPress way faster with varying techniques, but this tutorial will tell you how to create an out-of-the-box WordPress installation that can be installed on a shared hosting environment. Be that as it may, I'll be delighted if you shoot a comment below in the Comments section and share more techniques that can be used in "better" environments. Be sure to specify the environment that should be arranged, though.

Creating a Ready-to-Install WordPress Package

We, as human beings, are lazy. We weren't always like this, but when the communication speed came close to the speed of light, we became lazier and more impatient. Because of this laziness, we want everything as soon as possible—right after we want it, if possible. (We want it all, and we want it now!) We want speed so bad that we actually started wiring our brains that way. That's why our attention span has shortened and automatization has been equated to efficiency.

But this doesn't necessarily have to be a bad thing. We really need automatization and we really need some (incoming hype word!) zen in our lives. And in terms of web design, it's always better to finish the project fast because then we might get our money earlier.

This two-part series might get you your money earlier. With these tutorials, you're going to learn about:

  • bundling your WordPress installation with themes and plugins of your choice
  • utilizing the wp-config-sample.php file to define constants earlier than usual
  • and ***REDACTED TO KEEP THE HYPE*** which will blow your mind!

Let's begin!

Bundling Your Installation With Themes and Plugins

This one's kind of obvious, so I'll keep it short and move on to the wp-config-sample.php trick.

As of 2015, WordPress comes with the "Twenty Ten", "Twenty Eleven", "Twenty Twelve", "Twenty Thirteen", "Twenty Fourteen", and "Twenty Fifteen" themes. I like some of them but I really really dislike "Twenty Thirteen" and "Twenty Fourteen". I totally like "Twenty Fifteen" though. But still, I don't use any of them at all and use my own "theme boilerplate". 

So it's sensible to get rid of all the "default themes" before installing WordPress. We normally encounter a "default theme not found" error because WordPress sets a "default theme" inside its core and doesn't let you change that—or does it? Stay tuned for the awesome second part of this series!

The same goes for the default plugins. "Hello Dolly" is a fun plugin to see how plugins work for WordPress beginners, and "Akismet" is an effective solution for WordPress comment spam. But if you're not a WordPress beginner and don't use the "comments" feature in your projects (or use an external comments service like Disqus or Facebook Comments), you don't need either of those plugins. So why keep it in the installation file and clutter it up?

Instead, you can ship with your favorite plugins (or your own plugins). In this series, we're going to use three popular WordPress plugins:

We're not going to use them in this part, but you'll see them in the next part.

Little tip for cPanel users: In cPanel, there's a feature called "skeleton directory", which allows you to create cPanel accounts with files inside the /home/ directory. I, personally, like to use this feature to create a /wp/ folder in the /public_html/ directory in the hosting account that I use for my clients. It contains the core WordPress files, a "theme boilerplate" that I made, and plugins that I use in almost every project that I begin to make. (I also delete the default plugins and themes, and edit the wp-config-sample.php file—I'm going to talk about that in the next section.) If you have cPanel as the hosting control panel in your server, locate the /cpanel3-skel/ directory in the root (or ask your server administrator where it is) and move the files there to create hosting accounts with WordPress files already inside it. If you don't have cPanel in your server, ask the server administrator if there's a way to make this functionality work with your server.

Editing the wp-config-sample.php File

Here's a fun fact that will blow your mind: Most of the changes in the wp-config-sample.php file are automatically applied to the wp-config.php file during the installation. (If I'm not mistaken, database credentials and salt keys in wp-config-sample.php don't migrate to wp-config.php.) This was a tip I shared on Tuts+ about a year ago; and back then, this information couldn't be found anywhere on the internet—not even in WordPress Codex. So, ahem, I was the first one to share this tip in the world. (Foreshadowing: In the next part, I will share another trick that's never been discovered by another WordPress developer!)

Anyway, back to this part: Just edit the wp-config-sample.php file in your package which you'll be using in your future projects. I put together some custom constant definitions that can be applied for client projects:

These are the things that came to my mind. Do you have different ideas? Share them in the Comments section!

On to Part Two

While the things I've written above are already very cool tricks that will speed up your installation process, the "hack" in the next article is even cooler. You probably feel my excitement in my words but I'll say it again: I'm extremely excited that I will reveal a groundbreaking technique that's going to be published first and only on Tuts+ Code!

What do you think about the tricks that we went over above? Shoot us a comment in the Comments section below, if you want to share your thoughts with us. And be sure to share this article with your friends!


by Barış Ünver via Tuts+ Code

The Beginners Guide to WooCommerce: Managing Coupons

Cameron's World

Cameron's World is a web-collage of text and images excavated from the buried neighbourhoods of archived GeoCities pages (1994–2009).
by via Awwwards - Sites of the day

ViewerJS : JavaScript Spreadsheets & PDF File Viewer

ViewerJS must be the easiest way to use presentations, spreadsheets, PDF’s and other documents on your website or blog without any external dependencies. No tricks, no conversions, no unexpected downtime from external services, and no plugins required – it happens to work just fine in all major browsers today from the comfort of your own webserver. Free of cost, free as in open source (so you can tweak it yourself) and very easy to use.

The post ViewerJS : JavaScript Spreadsheets & PDF File Viewer appeared first on jQuery Rain.


by Admin via jQuery Rain

Verbatim : jQuery plugin for Deep linking to Content

Verbatim is a jQuery plugin that allows deep-linking directly to content. When installed, website visitors will be able to highlight text content (or select images), generate a direct link to the content, and share the link via Twitter. When a user clicks on the generated link, the page will scroll and highlight the selected content. It’s magic.

The post Verbatim : jQuery plugin for Deep linking to Content appeared first on jQuery Rain.


by Admin via jQuery Rain

Beep.js : JavaScript Library for browser-based Synthesizers

Beep is a JavaScript toolkit for building browser-based synthesizers using the WebAudio API.

The post Beep.js : JavaScript Library for browser-based Synthesizers appeared first on jQuery Rain.


by Admin via jQuery Rain

Saturday, September 5, 2015

Meerkat Introduces Live Hashtags: This Week in Social Media

Welcome to our weekly edition of what’s hot in social media news. To help you stay up to date with social media, here are some of the news items that caught our attention. What’s New This Week Meerkat Introduces Live #Hashtags: “This new approach to stream discovery is the quickest way to meet people around shared […]

This post Meerkat Introduces Live Hashtags: This Week in Social Media first appeared on Social Media Examiner.
Social Media Examiner - Your Guide to the Social Media Jungle


by via Social Media Examiner