fusi0n
15Jul/11

Grey Hat Programming on Big Commerce

One of my clients has a website constituting of two platforms: WordPress and Big Commerce. I was mandated to, among other things, create a symbiosis between the two platforms so that users didn't have to register twice. The only problem with that is being a commercial platform, Big Commerce doesn't want you messing around in their proprietary database - their API really is only for read stuff, you never write anywhere. Understandable... but my client still wants user synchronicity, and to be honest I don't think he's exaggerating.

So... how do we remotely create users on a platform that doesn't let you create users with their API? After a bit of looking around for solution, I stumbled upon my client's store registration form (which is hosted, like everything related to Big Commerce, on a server you don't control). Different domains, different servers, no API methods... but I have a form. Have you ever heard of XSS? In the world of developers, it's a real annoyance. Essentially, if you fail to secure your forms properly, anyone can grab your form, put it somewhere else on the internet and submit bogus data (because the form still sends to you, get it?). Anyway, it's usually really only a security concern, but for this particular project, it became a feature.

11Nov/10

10 of the Best WordPress Plugins

WordPress is an extremely powerful and popular blogging platform. There are over 27 million WordPress publishers as of September 2010: 13.9 million blogs hosted on WordPress.com plus 13.8 million active installations of the WordPress.org software (source). If that's not enough, there are 17,428 registered plugins to extend its functionality and 4,406 registered themes to modify its look. With all that, it can get complicated to choose the best plugins to achieve what you want. Here's a list of my personal favourites.

10Nov/10

Change localized strings in the WordPress admin

The other day, I ran into an interesting issue with a feature on a WordPress-powered site I was building for a client. Essentially, we're using the WordPress' default structure and functioning of posts, categories and tags in order to make it something different. Think of it like this lyrics site where categories are artist names and post titles are song titles. It's one of the reason WordPress implemented custom post types. Since the platform I'm building for this client doesn't really allow for other types of posts, I decided not to add a layer of posts on top of hiding the default things,

I wanted to rename the "Posts" menu in the WordPress admin. In the example I've described above, I wanted to rename the "Posts" to "Songs" and "Categories" to "Artists". The problem with that is that those are hardcoded in the a WordPress file and no hooks are defined, so we can't dynamically change it. It's also useless to manipulate the $menu variable which contains the admin sidebar items since "Posts" is also displayed on pages and at a bunch of other places. So how to efficiently turn that into a different string without hacking up the core?

The solution I came up with was to use WordPress' built-in localization mechanism. When theme and plugin developers want to output a string, they can enclose it in the__('string'); function, which calls up a gettext parser to translate. I'm not a fan of the system, it obliges you to compile a new language file for every version of your theme/plugin - and add one more for every language. But it's what WordPress uses, so we'll deal with it.

9Nov/10

New Look

I got tired of the previous design - aside from the fact that it was cool and up to date in 2002, it did its time. I've accumulated much WordPress knowledge since that setup was thought of, and I felt it was time. So here goes, a brand new design. I've kept several elements from the past one, such as the Disqus comments and WP-prettyPhoto, but it brought more interesting features not only in terms of display but also in terms of embedded plugins. The author of the theme hardcoded (obviously with function_exists checks) to ensure good compatibility, such as Yoast Breadcrumbs, PageNavi and others. So I got to play with a bunch of new toys and hack this theme up a bit.

I've also incorporated ads into this design. Yes. This blog is amazingly popular for mobile-related stuff (mostly Cydia), and well I'd be stupid not to monetize it. There's one ad unit in the sidebar that's low enough to be unobtrusive and another more obvious one at the top of single posts. I've discovered why my blog has been showing public service ads for the last 2 years and fixed that (shows how much I care).

Ideally, I'll start posting interesting stuff here eventually about WordPress, Mobile and general development. Stay tuned, and thanks for your loyalty - I still don't understand why anyone would read this blog, but whatever floats your boats.

Tagged as: Comments Off
2Sep/10

Post-Mortem: WordCamp Montreal 2010

On August 28th, the second edition of WordCamp Montreal took place at UQAM's "Coeur des Sciences". Last year, at the SAT, we were around 100 people to attend. This year's attendance easily topped the 200, thanks to the organizers and the sponsors, which were also more generous than the year before, with giveaways of goodies like Adobe software, $1 hosting packs, two iPads and a table full of stickers. The organizers (Shannon "cafenoirdesign" Smith, Jeremy Clarke and Brendan "digibomb" Sera-Shriar) worked hard to  fill the schedule with interesting topics and speakers, keep the attendees interested, fed: St-Viateur bagels with Starbucks coffee in the morning, catered lunch on day one, pizza on day two, and even cupcakes!

There were two talks attendees could choose from at any given time, 21 in all. Here are the ones I attended and bit of a summary for each.

3Jul/09

Hacking WordPress: Introduction to custom plugins and advanced templating

For those of you who don't know (which may very well be all of you right now), I will be presenting a talk at WordCamp Montreal July 12th. The title of the presentation, if you haven't guessed, is "Hacking WordPress: Introduction to custom plugins and advanced templating". I'll explain how you can use your own plugins and functions to make your WordPress site sing. In other words, it will basically be a relatively improvised primer on the following things:

If you're not registered yet, you have until July 9th to do so on EventBrite. For more information regarding WordPress Montreal 2009, check out the official site, mailing list, blog, Facebook group and Twitter account or see what's going on by looking up the #wcmtl tag.

24May/09

WP-prettyPhoto Technical Information and Usage Instructions

Lots has changed since the last article I made about WP-prettyPhoto usage, and so it is time to revamp the instructions, explain new features and hopefully be a bit more thorough. First off, let me first mention the following thing:  prettyPhoto is written by Stéphane Caron. Here are some related links to avoid repeating them throughout this article: Stéphane's blog, prettyPhoto's project page, prettyPhoto on GitHub, Stéphane on Twitter, WP-prettyPhoto at WordPress Extend, WP-prettyPhoto Support Forum.

PayPal - The safer, easier way to pay online!

Revision History: This article is intended to document the current WP-prettyPhoto (1.5.1) & prettyPhoto (2.5.2) versions.

Page 1 of 2
1
2