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://gist.github.com/dblandin/2991970 | |
Alabama | |
Alaska | |
American Samoa | |
Arizona | |
Arkansas | |
California | |
Colorado | |
Connecticut |
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
Paste this Code in Validator.php | |
public function validateAlphaSpaces($attribute, $value, $params) | |
{ | |
return preg_match('/^[\pL\s]+$/u', $value); | |
} | |
Create Custom Message some where at bottom in Validation.php | |
/* |
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
the reported geolocation info of a domain URL fast with this quick #oneliner: | |
curl -s ipinfoโ.io/`dig +short exampleโ.com` | tr -d '",{}' |
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
(\ autocomplete\=\")([a-z\-0-9\_\"]+) |
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
Add custom s/css like: | |
.note-placeholder { | |
display: block; //somehow it's display:none in the summernot bs4.css | |
} | |
because in the summernote bs4 css it's set to `display: none` for some f@cking reason |
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
$('.reveal').on('click', function() { | |
var reveal = '.' + $(this).attr('id'), // reveal's id *should* be to-be-revealed's class | |
type = $(reveal).attr('type') === 'password' ? 'text' : 'password'; | |
$(reveal).attr('type', type); | |
}); |
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
(value\=\"\{\{\ old\(\')([a-z\-\_]+)(\')(\)\ \}\}\") | |
usage: $1$2$3\,\ \$variableObject\->$2$4 | |
works as long as: | |
$2 is the same key as the column name (or whatever is in the object coming back) | |
see https://regex101.com/r/DfQngW/1 |
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 | |
$timezones = array( | |
'America/Adak' => '(GMT-10:00) America/Adak (Hawaii-Aleutian Standard Time)', | |
'America/Atka' => '(GMT-10:00) America/Atka (Hawaii-Aleutian Standard Time)', | |
'America/Anchorage' => '(GMT-9:00) America/Anchorage (Alaska Standard Time)', | |
'America/Juneau' => '(GMT-9:00) America/Juneau (Alaska Standard Time)', | |
'America/Nome' => '(GMT-9:00) America/Nome (Alaska Standard Time)', | |
'America/Yakutat' => '(GMT-9:00) America/Yakutat (Alaska Standard Time)', | |
'America/Dawson' => '(GMT-8:00) America/Dawson (Pacific Standard Time)', |
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
(\s*)([^=^\s]*)\s*=\s*(.*); | |
$1$3 = $2; |
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
SELECT * FROM KEY_COLUMN_USAGE WHERE REFERENCED_TABLE_NAME = 'table_name' AND REFERENCED_COLUMN_NAME = 'id' |
NewerOlder