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
(function () { | |
const base_path = 'https://example.com/base/path/'; | |
function addStyle(name) { | |
const path = base_path + 'css/' + name + '?v=' + Date.now(); | |
const link = document.createElement('link'); | |
link.rel = 'stylesheet'; | |
link.type = 'text/css'; | |
link.href = path; | |
document.head.appendChild(link); | |
} |
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
-- https://www.bishoy.me/changed-wp-table-prefix-now-cannot-access-wp-admin/ | |
-- http://www.neoegm.com/tech/wordpress/how-to-fix-the-you-do-not-have-sufficient-permissions-to-access-this-page-message-in-wordpress/ | |
UPDATE `new_prefix_wp_usermeta` SET `meta_key` = REPLACE(`meta_key`,'old_prefix_wp_','new_prefix_wp_'); | |
UPDATE `new_prefix_wp_options` SET `option_name` = REPLACE(`option_name`,'old_prefix_wp_','new_prefix_wp_'); |
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
//http://igorescobar.github.io/jQuery-Mask-Plugin/docs.html#callback-examples | |
$('.phone-mask').mask('(A00) 000 00 00',{ translation: { 'A': { pattern: /[1-9]/, optional: false } } }); |
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
<!-- | |
https://github.com/igorescobar/jQuery-Mask-Plugin/issues/25#issuecomment-20642590 | |
cmwelsh | |
--> | |
<input type="text" pattern="[0-9]*" /> <!-- display a numeric keyboard --> | |
<!-- azerafati --> | |
<input type="tel" /> <!-- display a telephone keypad --> |
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
//http://stackoverflow.com/a/1026087/181295 | |
String.prototype.turkishUpperCase = function () { | |
return this.replace(/ğ/g, 'Ğ') | |
.replace(/ü/g, 'Ü') | |
.replace(/ş/g, 'Ş') | |
.replace(/ı/g, 'I') | |
.replace(/i/g, 'İ') | |
.replace(/ö/g, 'Ö') | |
.replace(/ç/g, 'Ç') | |
.toUpperCase(); |