Tag / php

I have been using phpDocumentor on my Windows laptop lately, and one of the requirements is to have PEAR installed.

While this is a pretty simple process on Linux, it gets a little more complex on Windows.

Actually, it is not that complex. It is just difficult to find the proper resources (or at least it was for me).

I did find a number of posts / tutorials explaining the manual process of installing PEAR, but:

  1. It introduces possibilities of mishaps,
  2. I prefer when things are automated 😉

Automatically Install PEAR on Windows

First of all, I should specify that this was done on a Windows 10 Home x64 install with PHP 7.0.6. No WAMP, no MAMP, just PHP.

There are basically 2 steps required to install PEAR:

  1. Download the “installer”
  2. Run it
  3. Add the environment variables (yeah that’s more than 2 steps, but this one is optional. Bonus!)

Download go-pear.phar

PHP.net provides a super handy phar file that will allow you to install PEAR on your system in just one command line. […]

Continue reading →

So you just got this new WordPress theme or plugin approved by the review team. Exciting!

You get your first downloads and you watch the stats all the time. What are you waiting for? We all know it: reviews! Especially 5 stars reviews 😉

Reviews are Everything

Indeed, reviews are often what convinces the user to use your product… or not. That’s why all authors are striving for good reviews.

There is another thing we all know, though: unsatisfied users tend to review more than satisfied users. This means that you can easily end up with some bad reviews even though your product is good and the majority of users are happy.

What can you do about?

It may sound simple (and it is) but you just need to ask your users to review your product.

WP Review Me

This is where this small library I wrote becomes your best marketing tool!

It does a very simple job: X days (you can configure X) after the theme/plugin was installed, the user will be prompted to leave a review on WordPress.org.

Technically speaking, […]

Continue reading →

WordPress admin notices are great. They’re extremely handy for communicating an important message to the users of your theme or plugin.

Admin notices can be used for sharing an information, warning of a problem, etc. WordPress made is very easy to register with the admin_notices hook. There is one extremely important thing though: admin notice dismissal.

Dismiss an Admin Notice

Have you ever used a plugin that displays a notice that can’t be dismissed? Or a notice that comes back on every page load, whether or not you have dismissed it already? What a pain… Nobody wants that.

In WordPress 4.2, WordPress introduced dismissible admin notices. This is basically a front-end mechanism that hides a notice when you click the close button. But again, refresh the page and the notice is back.

Persistent Notices Dismissal

What you want is for a notice to be permanently dismissed once this close button is clicked. This is exactly what WP Dismissible Notices Handler does.

After writing admin notices dismissal functions over and over I realize how dumb I was for not having a re-usable library. […]

Continue reading →