Skip to content

Instantly share code, notes, and snippets.

@Bodom78
Bodom78 / countries_array.php
Created September 22, 2021 05:57
Create a PHP array of Country Codes and Names
<?php
/**
* Will write/overwrite an array to countries_en.php in the same directory.
* $countries = [
* "AW" => "Aruba",
* "AF" => "Islamic Republic of Afghanistan",
* "AO" => "Republic of Angola",
* "AI" => "Anguilla",
* ...
* @see https://restcountries.com for more information.
@Bodom78
Bodom78 / readme.md
Last active July 18, 2024 03:33
ANZ eGate Test Credit Cards

S2I Test Cards 2.4.5

The purpose of the mandatory testing is to ensure that your integration is performing correctly with the payment server and receiving the appropriate responses to display to your card holder. For example if an ‘insufficient funds’ or ‘invalid card’ response is returned it is important your integration can interpret this and display appropriately to your card holder.

To ensure there has been enough testing to identify any problems and to familiarize yourself with the product we require a minimum of 20 test transactions across all the scenarios.

Response Codes Testing

The information below is applicable only in the testing environment, i.e. when you are using your test merchant profile.

@Bodom78
Bodom78 / dos2unix-directory.md
Created August 9, 2016 11:56
dos2unix all files in a directory

From your desired directory:

find . -type f -print0 | xargs -0 dos2unix

@Bodom78
Bodom78 / laravel-mongodb-sentinel
Last active January 1, 2018 11:25
Use the Sentinel 2.x authentication package with Laravel 5.1 and MongoDB
Work in Progress: More testing to be done.
At a glance Authentication, Activation, Throttle, Groups & Permissions seem to
be working.
Downside: Copy and modify files.
Upside: Not really much work to get it up and running.
Assumes you have Laravel 5.1, jenssegers/laravel-mongodb + session addon set up
and your app is namespaced to App/
@Bodom78
Bodom78 / whm-change-document-root.md
Last active May 13, 2024 15:54
WHM/cPanel - Changing an accounts document root

To properly edit an accounts DocumentRoot go to /var/cpanel/userdata/username/ (replace username with the actual cPanel username for the account), then edit the file domain.com (where domain.com is your primary domain name).

You will see something like this in that file:

documentroot: /home/username/public_html

You will also see the cgi-bin area in this section:

scriptalias: