[Journey] - From PHP Novice to 10 Sales of a WordPress Plugin on Code Canyon

Panther28

Elite Member
Executive VIP
Jr. VIP
Joined
May 2, 2010
Messages
10,006
Reaction score
16,139
What:
I'm taking the plunge to develop a WordPress plugin. I've pretty much learned everything I think I need from working on one of my vanilla PHP sites. Its a plugin that takes either one or multiple urls and does something with it.

When:
I've been learning PHP and JS HTML etc as much as I could for the past year, and I will be updating this thread whenever I make some progress on the steps outlined below.

Where:
I feel I can achieve everything in the plugin, I already found a couple of StackOverflow posts, and websites detailing the steps I need to develop into my plugin. I plan to publish it on code canyon as it's quite a niche plugin, and the similar one is not well supported. I am working in PHP storm IDE.

Who:
There are a couple of developers I have on speed dial on skype from BHW, so I might be contacting them if I get really flummoxed!

Why:
I hope to sell my plugin on code canyon for I think $25, which is reasonable, compared with the other one.
My goal is just to make 10 sales, so I can say finally I'm a paid WP developer!

Steps
[⭐️] Version 1.0 - Working installed plugin and admin menu link
[ ] Version 1.0.1 - With the basic outline of the admin page
[ ] Version 1.0.2 - Add-in settings page for plugin with input fields
[ ] Version 1.0.3 - Create functionality to make the magic happen in settings
[ ] Version 1.0.4 - Create functionality to make magic happen for one URL
[ ] Version 1.0.5 - Create functionality to make magic happen for multiple URLs
[ ] Version 1.0.6 - Test Test Test and happy working so far locally
[ ] Version 1.0.7 - Test Test Test and happy working so far live
[ ] Version 1.0.8 - Check all best practices in place for plugin
[ ] Version 1.0.9 - Room for maneuver and any final updates
[ ] Version 1.1 - First upload to code canyon
[ ] Version 1.1.1 - First set of noob mistakes update

Sold
[ ] First Sold
[ ] 5 Sold
[ ] 10 Sold

The developer I'm comparing my plugin too, sold 500 over a 3-year period.

Hopefully I can inspire you & me to do more WP development, and how easy it is. Cheers.
 
This is cool. Following. Best of luck on the sales. I hope you blow that goal out of the water.
 
[⭐️] Version 1.0 - Working installed plugin and admin menu link
[⭐️] Version 1.0.1 - With the basic outline of the admin page
[⭐️] Version 1.0.2 - Add-in settings page for plugin with input fields

[ IN PROGRESS ] Version 1.0.3 - Create functionality to make the magic happen in settings

I have been making great progress, and I just got my plugin talking to the WordPress database and creating a basic template table for the settings. Just need to customize it all now.

I estimated 2 months for the project, but seem to be whizzing through it! I feel like I've been creating plugins for weeks, instead of days, as it's opened up a whole new level of experience and understanding of WordPress. Should be on track to finish within that timescale though.
 
Probably BHW marketplace would be a better performer than envato with regards to extremely high fees.

There is a hefty number of guys on that marketplace having 100+ products. They manage to make $2k per month passively after extremely high fees.

So prepare your boilterplate, universal architecture and master one stack to spam these apps.

You need 100 products, so if you want to be profitable, you'll need to make a MVP like product in 3 days. In 300 days you'll have a set and forget thing (with 1000s of people banging on your doors for customer support).

Simple conclusion is that it's not worth it cause full time developer will make 5x that amount.

And with WordPress you're choosing (almost) the worst developer experience possible. I'd not be surprised to see someone spend 6 months to generate $5k.

I don't know if you're already on the white hat side, but if you aren't, consider building black hat software.
 
Last edited:
After the whole idea is developed and proven to work, there is still a task.

1. Check all aspects of security - Anti-hack, anti mySQL injections, anti XSS), etc.
2. Compatibility - Not crashing or clashing with other existing and popular plugins.
3. Performance - Not slowing down the site, balancing PHP (server) and JS (client) for not to overload one or the other. Minimize as possible server requests (both HTTP and Database).

You will notice that once the plugin is working 100%, by using it you will still get a ton of ideas to implement that you did not think of it the first time. At least that happens to me. I have only done three plugins for myself to make the workflow of my site much easier and if I assigned a version number for each implementation (which I should, but I do this only for myself), one of them would be about version v20.0.0, lol.

Oh, and:

4. Leave some key functionality server-side, so no matter who copies (without paying) or nulls your plugin, it won't work without a license. Encryption is useless as you may know by browsing this forum. But, if you do this, remember that will need a fast server because #1, that will be an extra HTTP request, and #2, if you sell, let's say 1000 copies, those will be 1000 clients doing requests multiplies by X times to your licensing server, which must also be up 99.9999% of the time. I know nothing of Envato services, but I guess they have some service for this as I often encounter Envato licensing in some plugins.

Only my two cents. I hope you succeed bro.
 
I did had few chats with you on skype and I realized you are clever guy,

so i have no doubt that it will be successful journey in the end.

Anyway good luck :)
 
[⭐️] Version 1.0 - Working installed plugin and admin menu link
[⭐️] Version 1.0.1 - With the basic outline of the admin page
[⭐️] Version 1.0.2 - Add-in settings page for plugin with input fields
[⭐️] Version 1.0.3 - Create functionality to make the magic happen in settings
[IN PROGRESS ] Version 1.0.4 - Create functionality to make magic happen for one URL

Done a power of work today learning all the best ways to interact with the database tables in wp. Also, doubt I will be publishing on code canyon, as there is a better website, freemius.com that helps you handle security, updates, and ongoing revenue payments as well as a free version of your plugin on wp. They take 27% first $1k then scale down to 7% after $5k, and they have quite a popular marketplace.
 
Done a power of work today learning all the best ways to interact with the database tables in wp. Also, doubt I will be publishing on code canyon, as there is a better website, https://freemius.com/ that helps you handle security, updates, and ongoing revenue payments as well as a free version of your plugin on wp. They take 27% first $1k then scale down to 7% after $5k, and they have quite a popular marketplace.
https://freemius.com/blog/themeforest-good-place-sell-premium-wordpress-theme/
They did a good job exposing their competition. I'll try that with laravel and react instead of WordPress.

I wanted to make a new custom reactive page in WordPress yesterday. It took me 3 hours to get it working and it's still hacky.

In 3 hours I made a whole DB schema in Laravel. That's quite a difference in developer experience.
 
Good luck in your journey! Looks interesting, so I’m gonna keep tabs on the thread.

:)
 
Good luck on your journey.

I have always admired WP Plugins developers. This type of job is not easy.

I've read an In-depth plugin development book once. My brain hurt.
 
Had to go back, improve the input of my text box, and use javascript to ensure it's only digits that are used. So had to learn how to use the action hook properly, and load a javascript file to be able to call upon it wherever. That bit was easy, but the part where I spent an hour working on the wrong file and wondering why the admin page error wasn't fixed wasn't easy! :D

So now for my text input fields in settings you get a digit only for the boxes that are for digits only. Still have to be text input rather than numbers.

[⭐️] Version 1.0 - Working installed plugin and admin menu link
[⭐️] Version 1.0.1 - With the basic outline of the admin page
[⭐️] Version 1.0.2 - Add-in settings page for plugin with input fields
[⭐️] Version 1.0.3 - Create functionality to make the magic happen in settings
[⭐️] Version 1.0.3.1 - Fix input to be specific to correct input only, or disallow with an error message
[IN PROGRESS ] Version 1.0.4 - Create functionality to make magic happen for one URL

Back on track now and about to learn curl workings. Should be fun.
 
Small goal of 10 sales which you will certainly surpass. Hope you get lot of sales from all around the world.
 
Small goal of 10 sales which you will certainly surpass. Hope you get lot of sales from all around the world.
When I was thinking about running my business on Envato, I considered 200k sales in 5 years.

I even made a roadmap for this and it seems predictable when you look closely.

I think that's the only scenario when it beats traditional coding job.

Freelancers need to consider scale. Nobody is going to help them scale up.

I begin with thinking "how am I going to repeat it 100 or 200 times" and "which profitable process can be interated easily".

Back on track now and about to learn curl workings. Should be fun.
You should get pockets full of dough. Then have fun. It's common when you take coding as a hobby to think of it as a fun job.

You know, a cup of hot coffee, writing a line there, reading some docs and voila. While some guys will churn out a new app in 2 days or create an MVP and raise capital.

Being a hobby programmer is just going to make you realize in couple years "well, I could take it seriously and I would be 3 years into profits".
 
Good luck buddy, im looking currently to hire someone to develop one for me, so it would be nice yo learn new stuff about the process, im still concerned about the licensing and security.
Another point, as someone suggested above, if your plugin is niche focused, it would be way better to promote it outside envato, to avoid competition.
 
HTML5 has some integrated javascript in the forms that you can use in input fields using Regular Expressions (RegEx). With RegEx, you can filter anything.

For example, I use this input tag for entering a car's VIN, which should not be more, and should not be less, than 17 characters. The property "pattern" is where you put your RegEx filter:

Code:
<input pattern="[0-9a-zA-Z]{17}" title="FORMAT: Please, enter 17 Alphanumneric Characters" class="vin_input" id="vin-user-input" type="text" name="vin" placeholder="">


Otherwise, you may use your own JS with your own rules. You must "Enqueue" it properly when starting the plugin. For example, below is one of the lines that I put in the main plugin file so it enqueues all the needed scripts. You can do this with JS and CSS:

For CSS you use the "wp_enqueue style" function with the "wp_enqueue_scripts" action hook:

Code:
// Enqueue Plugin Styles
function vin_lookup_styles() {                              // custom function name of my plugin
  $css_dir = plugin_dir_url( __FILE__ ) . 'assets/vin.css'; // location of the CSS file
  wp_enqueue_style( 'vin-css', $css_dir );                      // Add the CSS file to the styles of the website
}
add_action( 'wp_enqueue_scripts', 'vin_lookup_styles' );

For JS you use the "wp_enqueue_script" function with the same "wp_enqueue_scripts" action hook:

Code:
// Enqueue Plugin Scripts
function vin_lookup_scripts() {
  $js_dir = plugin_dir_url( __FILE__ ) . 'assets/vin.js';  // location of the JS file
  wp_enqueue_script( 'vin-js', $js_dir );
}
add_action( 'wp_enqueue_scripts', 'vin_lookup_scripts' );

In the second one (JS), do not confuse the function with the action hook. The function is "wp_enqueue_script" and the action hook is "wp_enqueue_scripts". The "s" differs one from the other.

Also, if your plugin depends on functions from another plugin, like for example, adding some custom functionality to the Woocommerce cart, then you must make sure that when your plugin fires, Woocommerce must be already loaded. Otherwise, you will receive "function does not exist" errors.

For this, in my case, I put all the functions depending on other WP functions in a file (object-oriented (OOP) or not), and get it wrapped with the specific "loaded" function. I used "wp_loaded" in this case, which worked better than "woocommerce_loaded" (you have "wp_loaded", "plugins_loaded", "woocommerce_loaded", etc.):

Code:
function vin_lookup_init() {
  include_once( plugin_dir_path( __FILE__ ) . '/functions.php' ); // the file with dependent functions
}
add_action( 'wp_loaded', 'vin_lookup_init' );

I hope this helps.
 
HTML5 has some integrated javascript in the forms that you can use in input fields using Regular Expressions (RegEx). With RegEx, you can filter anything.

For example, I use this input tag for entering a car's VIN, which should not be more, and should not be less, than 17 characters. The property "pattern" is where you put your RegEx filter:

Code:
<input pattern="[0-9a-zA-Z]{17}" title="FORMAT: Please, enter 17 Alphanumneric Characters" class="vin_input" id="vin-user-input" type="text" name="vin" placeholder="">


Otherwise, you may use your own JS with your own rules. You must "Enqueue" it properly when starting the plugin. For example, below is one of the lines that I put in the main plugin file so it enqueues all the needed scripts. You can do this with JS and CSS:

For CSS you use the "wp_enqueue style" function with the "wp_enqueue_scripts" action hook:

Code:
// Enqueue Plugin Styles
function vin_lookup_styles() {                              // custom function name of my plugin
  $css_dir = plugin_dir_url( __FILE__ ) . 'assets/vin.css'; // location of the CSS file
  wp_enqueue_style( 'vin-css', $css_dir );                      // Add the CSS file to the styles of the website
}
add_action( 'wp_enqueue_scripts', 'vin_lookup_styles' );

For JS you use the "wp_enqueue_script" function with the same "wp_enqueue_scripts" action hook:

Code:
// Enqueue Plugin Scripts
function vin_lookup_scripts() {
  $js_dir = plugin_dir_url( __FILE__ ) . 'assets/vin.js';  // location of the JS file
  wp_enqueue_script( 'vin-js', $js_dir );
}
add_action( 'wp_enqueue_scripts', 'vin_lookup_scripts' );

In the second one (JS), do not confuse the function with the action hook. The function is "wp_enqueue_script" and the action hook is "wp_enqueue_scripts". The "s" differs one from the other.

Also, if your plugin depends on functions from another plugin, like for example, adding some custom functionality to the Woocommerce cart, then you must make sure that when your plugin fires, Woocommerce must be already loaded. Otherwise, you will receive "function does not exist" errors.

For this, in my case, I put all the functions depending on other WP functions in a file (object-oriented (OOP) or not), and get it wrapped with the specific "loaded" function. I used "wp_loaded" in this case, which worked better than "woocommerce_loaded" (you have "wp_loaded", "plugins_loaded", "woocommerce_loaded", etc.):

Code:
function vin_lookup_init() {
  include_once( plugin_dir_path( __FILE__ ) . '/functions.php' ); // the file with dependent functions
}
add_action( 'wp_loaded', 'vin_lookup_init' );

I hope this helps.
Great outline. I waded through mud to learn precisely that the other day :) But I didn't know about the wp_loaded so I took note of that, cheers.

I spent the day today finishing up how to get an image URL from a different website.

121 pages of StackOverflow reading today to get this working. Scraping master, I am declared! lol
 
Managed to make a breakthrough after some much-attempted XPath hacking to get certain DOM elements. (see I'm even getting the lingo ;) )

So got all but one detail from the external source.

I've got front-end and back-end work to do next, so should get started on them soon. Still on the same version for a while yet.

[IN PROGRESS ] Version 1.0.4 - Create functionality to make magic happen for one URL
 
Back
Top