Skip to content

Commit b855dc9

Browse files
authored
Merge pull request #1 from Kendysond/master
Merge new changes
2 parents 1767762 + 20c6b32 commit b855dc9

13 files changed

+79
-307
lines changed

README.txt

Lines changed: 50 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -1,114 +1,89 @@
1-
=== Plugin Name ===
2-
Contributors: (this should be a list of wordpress.org userid's)
3-
Donate link: kendyson.com
4-
Tags: comments, spam
5-
Requires at least: 3.0.1
6-
Tested up to: 3.4
7-
Stable tag: 4.3
1+
=== Paystack Forms ===
2+
Contributors: kendysond
3+
Donate link: https://paystack.com/demo
4+
Tags: paystack, recurrent payments, nigeria, mastercard, visa, target
5+
Requires at least: 3.1
6+
Tested up to: 4.6
7+
Stable tag: 1.0.0
88
License: GPLv2 or later
99
License URI: http://www.gnu.org/licenses/gpl-2.0.html
1010

11-
Here is a short description of the plugin. This should be no more than 150 characters. No markup here.
11+
Paystack forms allows you create forms that will be used to bill clients for goods and services.
12+
1213

1314
== Description ==
1415

15-
This is the long description. No limit, and you can use Markdown (as well as in the following sections).
16+
This is a Paystack plugin that provides Payment forms for Wordpress.
1617

17-
For backwards compatibility, if this section is missing, the full length of the short description will be used, and
18-
Markdown parsed.
18+
Paystack is on a mission to deliver a safe and convenient payment experience for customers and merchants. Paystack provide Nigerian merchants with the tools and services needed to accept online payments from local and international customers using MasterCard, Visa and Verve Cards.
1919

20-
A few notes about the sections above:
20+
To signup for a Paystack Merchant account, visit [https://dashboard.paystack.co](https://dashboard.paystack.co).
2121

22-
* "Contributors" is a comma separated list of wp.org/wp-plugins.org usernames
23-
* "Tags" is a comma separated list of tags that apply to the plugin
24-
* "Requires at least" is the lowest version that the plugin will work on
25-
* "Tested up to" is the highest version that you've *successfully used to test the plugin*. Note that it might work on
26-
higher versions... this is just the highest one you've verified.
27-
* Stable tag should indicate the Subversion "tag" of the latest stable version, or "trunk," if you use `/trunk/` for
28-
stable.
22+
Paystack forms allows you to create payment forms for numerous purposes. You can see the form and payment data from your dashboard.
2923

30-
Note that the `readme.txt` of the stable tag is the one that is considered the defining one for the plugin, so
31-
if the `/trunk/readme.txt` file says that the stable tag is `4.3`, then it is `/tags/4.3/readme.txt` that'll be used
32-
for displaying information about the plugin. In this situation, the only thing considered from the trunk `readme.txt`
33-
is the stable tag pointer. Thus, if you develop in trunk, you can update the trunk `readme.txt` to reflect changes in
34-
your in-development version, without having that information incorrectly disclosed about the current stable version
35-
that lacks those changes -- as long as the trunk's `readme.txt` points to the correct stable tag.
24+
With this Paystack Forms, you will be able to accept the following payment methods on a recurring basis:
3625

37-
If no stable tag is provided, it is assumed that trunk is stable, but you should specify "trunk" if that's where
38-
you put the stable version, in order to eliminate any doubt.
26+
* __MasterCard__
27+
* __Visa__
3928

40-
== Installation ==
29+
= Note =
4130

42-
This section describes how to install the plugin and get it working.
31+
This plugin is meant to be used by merchants in Nigeria.
4332

44-
e.g.
33+
= Plugin Features =
4534

46-
1. Upload `paystack-forms.php` to the `/wp-content/plugins/` directory
47-
1. Activate the plugin through the 'Plugins' menu in WordPress
48-
1. Place `<?php do_action('plugin_name_hook'); ?>` in your templates
35+
* __Accept payment__ via MasterCard and Visa Cards.
36+
* __Seamless integration__ into any WordPress page or post. Accept subscription payments directly on your site
4937

50-
== Frequently Asked Questions ==
5138

52-
= A question that someone might have =
5339

54-
An answer to that question.
40+
= Suggestions / Feature Request =
5541

56-
= What about foo bar? =
42+
If you have suggestions or a new feature request, feel free to get in touch with us via [http://paystack.com](http://paystack.com)
5743

58-
Answer to foo bar dilemma.
44+
You can also follow us on Twitter! **[@paystack](http://twitter.com/paystack)**
5945

60-
== Screenshots ==
6146

62-
1. This screen shot description corresponds to screenshot-1.(png|jpg|jpeg|gif). Note that the screenshot is taken from
63-
the /assets directory or the directory that contains the stable readme.txt (tags or trunk). Screenshots in the /assets
64-
directory take precedence. For example, `/assets/screenshot-1.png` would win over `/tags/4.3/screenshot-1.png`
65-
(or jpg, jpeg, gif).
66-
2. This is the second screen shot
47+
== Installation ==
6748

68-
== Changelog ==
49+
= Automatic Installation =
50+
* Login to your WordPress Admin area
51+
* Go to "Plugins > Add New" from the left hand menu
52+
* In the search box type __Paystack Forms__
53+
* From the search result you will see __Paystack Forms__ click on __Install Now__ to install the plugin
54+
* A popup window will ask you to confirm your wish to install the Plugin.
55+
* After installation, activate the plugin.
56+
* Open the settings page for Paystack Forms
57+
* Configure your __Paystack Forms__ settings as instructed on the page.
6958

70-
= 1.0 =
71-
* A change since the previous version.
72-
* Another change.
59+
= Manual Installation =
60+
1. Download the plugin zip file
61+
2. Login to your WordPress Admin. Click on "Plugins > Add New" from the left hand menu.
62+
3. Click on the "Upload" option, then click "Choose File" to select the zip file from your computer. Once selected, press "OK" and press the "Install Now" button.
63+
4. Activate the plugin.
64+
5. Under paystack forms, configure your api keys under api keys settings.
65+
6. Click on paystack forms and create a form.
66+
7. Paste the form shortcode on any page or widget.
7367

74-
= 0.5 =
75-
* List versions from most recent at top to oldest at bottom.
7668

77-
== Upgrade Notice ==
7869

79-
= 1.0 =
80-
Upgrade notices describe the reason a user should upgrade. No more than 300 characters.
8170

82-
= 0.5 =
83-
This version fixes a security related bug. Upgrade immediately.
71+
== Frequently Asked Questions ==
8472

85-
== Arbitrary section ==
73+
= What Do I Need To Use The Plugin =
8674

87-
You may provide arbitrary sections, in the same format as the ones above. This may be of use for extremely complicated
88-
plugins where more information needs to be conveyed that doesn't fit into the categories of "description" or
89-
"installation." Arbitrary sections will be shown below the built-in sections outlined above.
75+
1. You need to open a Paystack merchant account on [Paystack](https://paystack.com)
9076

91-
== A brief Markdown Example ==
9277

93-
Ordered list:
9478

95-
1. Some feature
96-
1. Another feature
97-
1. Something else about the plugin
9879

99-
Unordered list:
80+
== Changelog ==
10081

101-
* something
102-
* something else
103-
* third thing
82+
= 1.0.0 =
83+
* First release
10484

105-
Here's a link to [WordPress](http://wordpress.org/ "Your favorite software") and one to [Markdown's Syntax Documentation][markdown syntax].
106-
Titles are optional, naturally.
85+
== Screenshots ==
10786

108-
[markdown syntax]: http://daringfireball.net/projects/markdown/syntax
109-
"Markdown is what the parser uses to process much of the readme file"
11087

111-
Markdown uses email style notation for blockquotes and I've been told:
112-
> Asterisks for *emphasis*. Double it up for **strong**.
11388

114-
`<?php code(); // goes in backticks ?>`
89+
== Other Notes ==

admin/class-paystack-forms-admin.php

Lines changed: 2 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,5 @@
11
<?php
22

3-
/**
4-
* The admin-specific functionality of the plugin.
5-
*
6-
* @link kendyson.com
7-
* @since 1.0.0
8-
*
9-
* @package Paystack_Forms
10-
* @subpackage Paystack_Forms/admin
11-
*/
12-
13-
/**
14-
* The admin-specific functionality of the plugin.
15-
*
16-
* Defines the plugin name, version, and two examples hooks for how to
17-
* enqueue the admin-specific stylesheet and JavaScript.
18-
*
19-
* @package Paystack_Forms
20-
* @subpackage Paystack_Forms/admin
21-
* @author kendysond <[email protected]>
22-
*/
233
class Paystack_Forms_Admin {
244

255
private $plugin_name;
@@ -338,7 +318,8 @@ function wpt_form_data() {
338318
if ($currency == "") {$currency = 'NGN';}
339319
// Echo out the field
340320
echo '<p>Currency:</p>';
341-
echo '<input type="text" name="_currency" value="' . $currency . '" class="widefat" />';
321+
echo '<input type="text" name="_currency" value="' . $currency . '" class="widefat" />
322+
<small>We currently support only payments in Naira(NGN).</small>';
342323
echo '<p>Amount to be paid(Set 0 for customer input):</p>';
343324
echo '<input type="number" name="_amount" value="' . $amount . '" class="widefat pf-number" />';
344325
echo '<p>Pay button Description:</p>';

icon.png

100755100644
7.47 KB
Loading

includes/class-paystack-forms-activator.php

Lines changed: 6 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,5 @@
11
<?php
22

3-
/**
4-
* Fired during plugin activation
5-
*
6-
* @link kendyson.com
7-
* @since 1.0.0
8-
*
9-
* @package Paystack_Forms
10-
* @subpackage Paystack_Forms/includes
11-
*/
12-
13-
/**
14-
* Fired during plugin activation.
15-
*
16-
* This class defines all code necessary to run during the plugin's activation.
17-
*
18-
* @since 1.0.0
19-
* @package Paystack_Forms
20-
* @subpackage Paystack_Forms/includes
21-
* @author kendysond <[email protected]>
22-
*/
233
class Paystack_Forms_Activator {
244

255
/**
@@ -31,10 +11,9 @@ class Paystack_Forms_Activator {
3111
*/
3212
public static function activate() {
3313
global $wpdb;
34-
$charset_collate = $wpdb->get_charset_collate();
3514
$table_name = $wpdb->prefix . 'paystack_forms_payments';
3615

37-
$sql = "CREATE TABLE $table_name (
16+
$sql = "CREATE TABLE IF NOT EXISTS `".$table_name."` (
3817
id int(11) NOT NULL AUTO_INCREMENT,
3918
post_id int(11) NOT NULL,
4019
user_id int(11) NOT NULL,
@@ -43,15 +22,14 @@ public static function activate() {
4322
paid int(1) NOT NULL DEFAULT '0',
4423
txn_code varchar(255) DEFAULT '' NOT NULL,
4524
amount varchar(255) DEFAULT '' NOT NULL,
46-
views smallint(5) NOT NULL,
25+
ip varchar(255) NOT NULL,
4726
deleted_at varchar(255) DEFAULT '' NULL,
48-
created_at datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
49-
modified datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
27+
created_at timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
28+
modified timestamp DEFAULT '0000-00-00 00:00:00' NOT NULL,
5029
UNIQUE KEY id (id)
51-
) $charset_collate;";
52-
30+
);";
5331
require_once( ABSPATH . 'wp-admin/includes/upgrade.php' );
54-
dbDelta( $sql );
32+
dbDelta($sql);
5533
}
5634

5735

includes/class-paystack-forms-deactivator.php

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,6 @@
11
<?php
22

3-
/**
4-
* Fired during plugin deactivation
5-
*
6-
* @link kendyson.com
7-
* @since 1.0.0
8-
*
9-
* @package Paystack_Forms
10-
* @subpackage Paystack_Forms/includes
11-
*/
123

13-
/**
14-
* Fired during plugin deactivation.
15-
*
16-
* This class defines all code necessary to run during the plugin's deactivation.
17-
*
18-
* @since 1.0.0
19-
* @package Paystack_Forms
20-
* @subpackage Paystack_Forms/includes
21-
* @author kendysond <[email protected]>
22-
*/
234
class Paystack_Forms_Deactivator {
245

256
/**

includes/class-paystack-forms-i18n.php

Lines changed: 1 addition & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,6 @@
11
<?php
22

3-
/**
4-
* Define the internationalization functionality
5-
*
6-
* Loads and defines the internationalization files for this plugin
7-
* so that it is ready for translation.
8-
*
9-
* @link kendyson.com
10-
* @since 1.0.0
11-
*
12-
* @package Paystack_Forms
13-
* @subpackage Paystack_Forms/includes
14-
*/
15-
16-
/**
17-
* Define the internationalization functionality.
18-
*
19-
* Loads and defines the internationalization files for this plugin
20-
* so that it is ready for translation.
21-
*
22-
* @since 1.0.0
23-
* @package Paystack_Forms
24-
* @subpackage Paystack_Forms/includes
25-
* @author kendysond <[email protected]>
26-
*/
3+
274
class Paystack_Forms_i18n {
285

296

includes/class-paystack-forms-loader.php

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,6 @@
11
<?php
22

3-
/**
4-
* Register all actions and filters for the plugin
5-
*
6-
* @link kendyson.com
7-
* @since 1.0.0
8-
*
9-
* @package Paystack_Forms
10-
* @subpackage Paystack_Forms/includes
11-
*/
12-
13-
/**
14-
* Register all actions and filters for the plugin.
15-
*
16-
* Maintain a list of all hooks that are registered throughout
17-
* the plugin, and register them with the WordPress API. Call the
18-
* run function to execute the list of actions and filters.
19-
*
20-
* @package Paystack_Forms
21-
* @subpackage Paystack_Forms/includes
22-
* @author kendysond <[email protected]>
23-
*/
3+
244
class Paystack_Forms_Loader {
255

266
/**

includes/class-paystack-forms.php

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,6 @@
11
<?php
22

3-
/**
4-
* The file that defines the core plugin class
5-
*
6-
* A class definition that includes attributes and functions used across both the
7-
* public-facing side of the site and the admin area.
8-
*
9-
* @link kendyson.com
10-
* @since 1.0.0
11-
*
12-
* @package Paystack_Forms
13-
* @subpackage Paystack_Forms/includes
14-
*/
153

16-
/**
17-
* The core plugin class.
18-
*
19-
* This is used to define internationalization, admin-specific hooks, and
20-
* public-facing site hooks.
21-
*
22-
* Also maintains the unique identifier of this plugin as well as the current
23-
* version of the plugin.
24-
*
25-
* @since 1.0.0
26-
* @package Paystack_Forms
27-
* @subpackage Paystack_Forms/includes
28-
* @author kendysond <[email protected]>
29-
*/
304
class Paystack_Forms {
315

326
/**

0 commit comments

Comments
 (0)