Adding a “Rate” Button to your Cordova-based Mobile App (Android, iOS, etc)

Stars Rating, App

High ratings in the Google Play Store or iOS App Store are critical to an app’s success. And they’re beneficial to find out what the problems are when an app needs improvement. So, it’s very common to have a simple link/button that allows the end user to submit their review from inside the app. The less hoops to […]

Facebook’s Sharer is no Longer Being “deprecated” (2014)

Facebook Sharer, Share

Facebook’s sharer.php is officially back. Not that most people had stopped using it anyway! Along with the new Share button, you can safely use the sharer.php syntax to create a link that shares a URL on one’s Facebook timeline. As there are still many articles/answers out there that have outdated answers to questions about this, […]

Get SASS Working in Sublime Text for Windows in 8 Steps

Compile SASS, Sublime Text Windows

Follow these installation instructions to start using SASS with Sublime Text. You'll be able to save your SASS (.scss) file, and it will compile to a CSS file automatically. There are a few more extensive guides out there on this, but they skipped over a few minor things that you may miss. This boils it down to the essentials that you need to get up and running.

SVG Export Settings for the Web with Adobe Illustrator

The SVG (Scalable Vector Graphic) file-format is an XML-based vector in that can be used on the web right now. Not only are they crisp at any size they are scaled to, but they are supported by IE9+, Firefox, Chrome, and Safari. For IE8 and below, you can provide a fallback PNG. Simple icons and logos are good candidates for the format, as they are often the first noticeable elements of a design that will look blurry on a retina display...

Fix HTML5 Validator Error “Bad value X-UA-Compatible for attribute http-equiv on element meta.”

If you are using the X-UA-Compatible meta tag, then you'll probably run into this error when attempting HTML5 validation at the W3C. It's common to use X-UA-Compatible to set Internet Explorer to edge mode (forcing the latest rendering engine), and to enable Google Chrome Frame for visitors with that IE plugin. To make the validation error go away (perhaps it is your only remaining error?), the meta tag can be removed and the value can be sent through the HTTP headers instead. Depending on the web technology you're using and your server settings, this can be done in different ways, and I thought it'd be a good idea to collect the syntax in one place...

Get the Thumbnails of a YouTube Video: Standard URL and File Names

All the different thumbnail sizes of a YouTube video are accessible from a standard format. All you need is the unique video ID (viewable in the URL of your video). Thumbnail Image Format: The file name depends on which thumbnail size you are looking for. There are several to choose from...

10 Yii Framework and MVC “Beginner” Questions & Problems Solved

Sometimes "experience" means all the little stuff that no one ever bothered to write down. Learning code through doing will lead you on a zig-zag path from one problem to the next, that is different per-project. In starting a big website made with Yii, having never touched the framework before, I took notes on some of the issues and questions that arose while developing...

Yii: Adding Title Tags, Meta Descriptions, and Other SEO-Related Tags

As a followup to my post about SEO-Friendly URLs using Yii, I figured I would post this function I created for displaying SEO-related tags in the layout.Using the Gii generator with the Yii Framework, a custom base controller is created that is a parent for the others. It already contained a property called pageTitle that was used in some of the views. I decided to keep this location and expand upon it by adding in some more properties related to search engine optimization, and then create a function to display the HTML...

Clean SEO-Friendly URLs for Yii Pages

Creating SEO-friendly permalinks for an application built using the Yii Framework was a multi-step process. I figured I would outline each part. First, you can use slugs to access your view actions with the help of an extension and entries to your urlManager. Removing "index.php" is as simple as adding a few htaccess rules and changing two options. To Force trailing slashes, some code can be added to your base controller. And lastly, to give yourself cleaner "/site/page/" URLs, some more entries can be added to your urlManager...

CSS Print Media Query

Using the @media rule in your CSS allows you to target different media types, and screen sizes, from a single stylesheet. Using media queries with max-widths is integral to the current push towards responsive design. This can also be used to create your print styles using @media print. You'll notice this used on modern base-templates such as the HTML5 BoilerPlate:

Yii Framework Intro: Starting a New Database-Driven Website

In creating my first Yii application, there were a few hurdles and stumbling blocks along the way. One of the first guides/tutorials that a new user to the Yii PHP framework is directed to is the "Creating Your First Yii Application" in the "Definitive Guide to Yii" . This is kind of a companion piece that has extra explanation, plus the first steps I made to start turning the example app (generated skeleton) into my custom web application.

Add a Subscribe to MailChimp Newsletter Option on Your Contact Form in 5 Minutes

Adding a “Subscribe to Newsletter” checkbox or radio button to an existing contact form is incredibly painless using the MailChimp API. Include one library file, and you’ll have access to all functions the API has to offer. In this example, I added a Yes/No radio selection. You could easily change this to be a checkbox. When "Yes" is selected, and the form is submitted, the contact form does its thing, and then the user is added to a MailChimp List.

Launching a Codeigniter Site: 3 Steps to Disable Database Errors

Turning off error reporting is often mentioned as a standard security precaution when switching to a production environment. After all, you don’t want those precious database table and field names out in the open, for sneaky little hobbitses to view. If someone is rummaging through your site, trying to find vulnerabilities, this severely limits the […]