Skip to content

Commit

Permalink
Merge pull request #1 from slogsdon/main
Browse files Browse the repository at this point in the history
Add Initial Files
  • Loading branch information
securesubmit-buildmaster authored May 18, 2021
2 parents c6543de + 994af1b commit c74d43d
Show file tree
Hide file tree
Showing 40 changed files with 4,303 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/vendor/
.phpunit.result.cache
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Global Payments Gravity Forms

## Installation

This module installs as a standard WordPress module.

## Usage

Download the contents and extract to your WordPress plugin folder. Activate.

## Contributing

1. Fork it
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create new Pull Request
51 changes: 51 additions & 0 deletions assets/frontend/css/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
/*globalpayments styles*/

.ss-shield {
background: transparent url(../images/[email protected]) no-repeat top left;
height: 50px;
background-size:auto 40px;
}

#HPS_secure_cc iframe, #iframesCardSubmit iframe {
width: 100%;
min-height: 51px;
}

.iframeholder {
height: 50px;
width: 100%;
}

.ie8 form .iframeholder {
padding: 10px;
}

.iframeholder::after {
content: '';
display: block;
width: 100%;
height: 0px;
clear: both;
position: relative;
}

.ie8 form .form-group {
margin-bottom: 5px;
}

#iframesCardExpiration,
#iframesCardCvv {
margin-bottom: 14px;
}

@media screen and (min-width:767px) {
#global-payments-expiration-date.form-group,
#global-payments-cvv.form-group{
display: inline-block;
width: 48%;
}

#global-payments-cvv.form-group {
float: right;
}
}
Binary file added assets/frontend/images/amex.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/card-icons-sprite.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/cvv.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/cvv1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/cvv2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/discover.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/down.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/jcb.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/mastercard.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/ss-saved-mastercard.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/ss-shield-ie.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/[email protected]
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/frontend/images/visa.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
52 changes: 52 additions & 0 deletions assets/frontend/js/globalpayments-admin.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
/*jslint browser:true, unparam:true*/
/*global gp, gforms_globalpayments_admin_strings, ajaxurl*/
(function (window, $) {
window.GlobalPaymentsAdminClass = function () {
this.initEnableGatewaySettingsToggle = function () {
this.toggleGatewaySettings($('#gaddon-setting-row-gateway_type select').val());
};

this.toggleGatewaySettings = function (value) {
$('.gateway-setting').parents('[id^="gaddon-setting-row-"]').hide();
$('.gateway-' + value).parents('[id^="gaddon-setting-row-"]').show();
};

this.initAdminCCFields = function () {
var $fields = $('#iframesCardNumber,#iframesCardExpiration,#iframesCardCvv');
var that = this;
if ($fields.length > 0) {
$fields.children().remove();
$fields.each(function (i, field) {
field.append(that.getDummyField(field));
});
}
};

this.getDummyField = function (field) {
var input = document.createElement('input');
input.type = 'tel';
input.disabled = true;

switch (field.id) {
case 'iframesCardNumber':
input.placeholder = '•••• •••• •••• ••••';
break;
case 'iframesCardExpiration':
input.placeholder = 'MM / YYYY';
break;
case 'iframesCardCvv':
input.placeholder = 'CVV';
break;
}

return input;
};
};

$(document).ready(function () {
window.GlobalPaymentsAdmin = new window.GlobalPaymentsAdminClass();

window.GlobalPaymentsAdmin.initEnableGatewaySettingsToggle();
window.GlobalPaymentsAdmin.initAdminCCFields();
});
})(window, window.jQuery);
Loading

0 comments on commit c74d43d

Please sign in to comment.