This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* | |
*/ | |
trait Uniquable | |
{ | |
// this function can create a unique alphanumeric string. To create a | |
// unique string contains letter and number (alphanumeric) with the character limit $limit. These kinds of | |
// unique string can be used as Voucher Code, Referral Code, Coupon Code, OTP or any kind of Promotional Code. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* | |
*/ | |
trait UsersGeolocation | |
{ | |
// Get User's Geolocation | |
function get_timezone() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div id="section-with-background"> | |
<!-- product page section to apply background color to --> | |
</div> | |
<script> | |
document.addEventListener('DOMContentLoaded', (event) => { | |
const canvas = document.createElement('canvas'); | |
const context = canvas.getContext('2d'); | |
const image = new Image(); | |
image.crossOrigin = "Anonymous"; |