This file contains hidden or 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 | |
/** | |
* Function in order to support previous versions of WordPress | |
*/ | |
if ( ! function_exists( 'wp_body_open' ) ) { | |
function wp_body_open() { | |
do_action( 'wp_body_open' ); | |
} | |
} |
This file contains hidden or 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 | |
/** | |
* Validate Date | |
* | |
* @return boolean Returns TRUE if the date given is valid; otherwise returns FALSE. | |
*/ | |
function is_date_valid( $date, $format = 'Y-m-d H:i:s'){ | |
if( ! isset( $date ) || isset( $date ) && ! is_string( $date ) ) | |
return false; |
This file contains hidden or 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 | |
/** | |
* Verifies that an email is valid. | |
* | |
* @param $email (string) (Required) Email address to verify. | |
* @return (string|bool) Either false or the valid email address. | |
*/ | |
function is_email( $email ){ | |
// Test for the minimum length the email can be | |
if ( mb_strlen( $email ) < 6 ) { |
This file contains hidden or 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
import { Dimensions } from "react-native"; | |
const { width, height } = Dimensions.get("window"); | |
const Constants = { | |
useReactotron: true, // Debug | |
Language: "en", | |
fontFamily: "system font", // Default font | |
WordPress: { // No required | |
defaultDateFormat: "YYYY-MM-DD HH:mm:ss" |
This file contains hidden or 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
const list_names = [ | |
"Hello", | |
"World", | |
"Lenivene", | |
"Bezerra", | |
"Lenivene", | |
"Enevinel", | |
"World" | |
]; |
This file contains hidden or 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 | |
function text_line_json_encode( $value, $options = 0, $depth = 512 ){ | |
$to_json = $value; | |
if( ! is_array( $value ) || ! is_object( $value ) ){ | |
$to_json = preg_split("/\r\n|\n|\r/", (string) $value ); | |
} | |
return json_encode( $to_json, $options, $depth ); |
This file contains hidden or 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 | |
/** | |
* Verificar se o CNPJ ( Cadastro nacional de pessoas Jurídicas ) é um número valido. | |
* | |
* @author Lenvene Bezerra | |
* @return true | false | |
*/ | |
function is_cnpj( $cnpj ){ | |
if( ! isset( $cnpj ) || isset( $cnpj ) && empty( $cnpj ) ) | |
return false; |
This file contains hidden or 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 | |
/** | |
* Verificar se o CPF ( Cadastro de pessoas físicas ) é um número valido. | |
* | |
* @author Lenvene Bezerra | |
* @return true | false | |
*/ | |
function is_cpf( $cpf ){ | |
if( ! isset( $cpf ) || isset( $cpf ) && empty( $cpf ) ) | |
return false; |
This file contains hidden or 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
<p style="line-height: 18px; font-size: 18px; font-family: times;"> | |
<script> | |
for (var line=1; line<60; line++) { | |
for(var i=1;i<29;i++) { | |
var s = (Math.floor((Math.random()*2)%2)) ? "╱" : "╲"; | |
document.write(s); | |
} | |
document.writeln("<br>"); | |
} | |
</script> |
This file contains hidden or 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
<!--[if lte IE 8]><script>(function(){var e="abbr,article,aside,audio,canvas,datalist,details,figure,footer,header,hgroup,mark,menu,meter,nav,output,progress,section,time,video".split(','),i=e.length;while(i--){document.createElement(e[i]);}}());</script><![endif]--> |