Categories
Web Development

A quick Doxygen fix for @type

Doxygen doesn’t recognize the @type docblock tag. That’s a problem, since at GravityView, we try to replicate WordPress core’s usage of the @type docblock tags to define nested values in associative arrays. The fix? Add an ALIAS in Doxygen where @type is treated as @param. Here’s how:

Categories
Web Development

UserVoice Gadget API

I wanted to learn what data is sent by the UserVoice Inspector Gadgets (I do appreciate the name ūüėČ), but there was no information I could find online. Here’s some basic information about the HTTP request that is made by the Gadget.

Categories
Web Development

Is your Easy Digital Downloads AJAX request taking too long to load?

TLDR: If you want faster credit card AJAX load times in EDD, disable the “Show previously used cards” setting in EDD. Hint: It only happens when you or a customer are logged-in. I’ve recently found that it can take up to 8 seconds for the credit card fields to load when working on the GravityView […]

Categories
Code Web Development

Allow customers to update their cards in disabled gateways using Easy Digital Downloads Recurring Payments

Last year, GravityView was using PayPal Pro to process credit card transations with our shopping cart, Easy Digital Downloads. Over time, we became frustrated with the error rate of PayPal notifications: PayPal kept telling us the country code wasn’t set. But it was. This was preventing customers from checking out, so GravityView switched to using […]

Categories
Web Development WordPress

Translating Multiple Branches of Your Premium Plugin with Transifex

Since GravityView launched in 2014, we have used Transifex to manage translations. Our process has always relied on a single translation resource file, and we’ve had the same flow over time: Create an update with new strings Upload the translation file to Transifex Release the update In the next minor release, include any new translations […]

Categories
Web Development

Restoring VVV functionality to Pressmatic

I switched from developing using Vagrant with VVV to using the new Mac app Pressmatic. I’ve been very happy, and so has my Mac‚ÄĒthe dev environment runs much faster and my computer has been working a lot less. Less fan noise is good. The server environment that Pressmatic uses don’t have some basic stuff that […]

Categories
Google Web Development

Set the Width for a Google Maps InfoWindow

Working with Google Maps v3 is way fun. If you’re a masochist. It seems like there’s no easy way to set the width of an InfoWindow. You can set the minWidth parameter, but that does nothing. If you have content that exceeds the InfoWindow window, you get this: a scrolling box. That’s terrible. The solution […]

Categories
Google Web Development

Get URL for Searches in Safari 6

There have been many articles and conversations about the question of how to get the URL of a Google search in Safari 6. Some solutions include using the Terminal to get the URL, using AppleScript, ¬†using bookmarklets, and¬†using Automator. I created a Safari Extension to make this process easier. Get URL: Easily get the URL […]

Categories
Mac Web Development

Add Googlebot User Agent to Safari Develop Menu

If you’re like me, you’ve wanted to have the Googlebot user agent availalbe in the Develop menu of Safari. Go to /Applications/ Right-click on¬†Safari.app and select Show Package Contents Navigate to Contents/Resources/ Find `UserAgents.plist` Open¬†`UserAgents.plist` in your favorite text editor Either Replace with the contents of this file and continue to step 9: [download id=”12″] […]

Categories
Web Development WordPress

Generate a Link to Activate a Plugin in WordPress

Here’s another specialized plugin development tip! If you want to create a link to activate a plugin, you need to know the path of the plugin file. Let’s use Akismet for this example. $path = ‘akismet/akismet.php’; $link = wp_nonce_url(admin_url(‘plugins.php?action=activate&plugin=’.$path), ‘activate-plugin_’.$path); The `$link` URL will be something like http://yoursite.com/wp-admin/plugins.php?action=activate&plugin=akismet%2Fakismet.php&_wpnonce=f97dabdf9

Categories
Web Development WordPress

How to Hard-Code a UA String for the Google Analytics for WordPress Plugin

If you want to define a Google Analytics “UA String” while using Yoast Google Analytics¬†plugin for WordPress. Add the following to your theme’s `functions.php` file: add_filter( ‘option_Yoast_Google_Analytics’, ‘custom_ua_string_filter’); function custom_ua_string_filter($options = array()) { $options[‘uastring’] = ‘UA-########-#’; $options[‘manual_uastring’] = true; return $options; } For users of WordPress Multisite, this will allow you to pre-configure new blogs […]

Categories
Web Development WordPress

Simple Way to Get Plugin Status in WordPress

I have previously written on how to determine if a widget is active. This is helpful for widgets, but not for plugins. WordPress has a couple of different functions that help you determine plugin status. They are both located in wp-includes/plugin.php `validate_plugin()` spits out an error if the plugin file does not ¬†exist or has […]

Categories
Web Development WordPress

A WordPress Developer's Tips for Using Panic Coda

I use Panic Coda¬†for coding. I like its Mac-style interface and it “fits” me well. There are some items that are frustrating, including a lack of auto-complete for functions you’ve already used in your code. Here are three tips to improve your coding experience.

Categories
Web Development

A Sweet Javascript Slideshow Script

Developers: reveal.js is a great standards-compliant slideshow script. It looks great and is an awesome alternative to Flash-based or image-based slideshows. reveal.js

Categories
Plugins Web Development

Yourls Google Analytics Link Tagging

In my last post, I wrote about the benefits of using YOURLS, a self-hosted link-shortening service.¬†I’m finding that YOURLS is great, but it’s not perfect. Some of the issues I have experience are part of what you get using most URL shortener services. Some of the downsides of using link shorteners are: Google Analytics doesn’t […]

Categories
Domains Web Development

YOURLS URL Shortener

I was having trouble finding the right URL shortening service.¬†My requests for shortening were not too picky.¬†I wanted two simple features: Good statistics that are visible only to administrators Edit the long URLs after generating shortened links …but not one service has both features: http://sn.im has editable URLs, a bookmarklet, but no stats. Oh, and […]

Categories
Tutorial Web Development

Enable PDF Uploads in CubeCart 4

The CubeCart file and image uploader in the product editor only allows for a small set of file types: jpg, gif, jpeg, png, swf, fla, jpg, gif, jpeg, png, avi, mpg, and mpeg. If you want to upload a PDF in CubeCart, you will have to manually FTP it into the uploads folder, and even […]

Categories
Web Development

WordPress.org Changes Plugin Page Layout

WordPress.org plugin page layout change likely for usability A couple of weeks ago, WordPress.org changed the layout of their plugins directory plugin pages. The update was likely to improve usability for users trying to determine whether a plugin is trustworthy and what it does. I believe the re-arranging of the page has achieved those goals. […]

Categories
QuickTip Web Development

How to Add www. – or Remove www. – From Your URL

This has been done many times by others, but just a quick tip on how to add or remove www. from your website’s address. This is helpful for URL canonicalization and user experience consistency. You can also achieve SEO-friendly canonicalization using rel=”canonical”. Oh boy, I’m getting too technical ūüôā Here’s the juicy part: Add the […]

Categories
Web Development WordPress

Save Coding Time by Creating Special-Case Categories in WordPress

When you would use excluded categories: When using WordPress as more of a content management system (CMS) than a blogging platform, there are many things that you need control over. One of them is special-case categories. Frequently asked questions Testimonials Case studies Press releases When you have a category of posts that you don’t want […]