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
$.fancybox.open({ | |
href:'image.jpg' | |
}); |
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 | |
if(strtotime(date('d-m-Y')) > strtotime('27-11-2016')) { | |
echo 'OK'; | |
} |
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
#/etc/apache2/sites-available/000-default.conf | |
DocumentRoot /home/user/Projects | |
<Directory /home/user/Projects/> | |
Options Indexes FollowSymLinks MultiViews | |
AllowOverride All | |
Order allow,deny | |
allow from all | |
Require all granted | |
</Directory> |
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
#!/bin/bash | |
wget --user-agent Mozilla/4.0 'wetransferlink' -O file.zip |
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 | |
if ( isset( $_POST['g-recaptcha-response'] ) ) { | |
// ENVIA INFORMAÇÕES POR POST PARA TESTAR O CAPTCHA | |
$result = file_get_contents( 'https://www.google.com/recaptcha/api/siteverify', false, stream_context_create( array( | |
'http' => array( | |
'header' => "Content-type: application/x-www-form-urlencoded\r\n", | |
'method' => 'POST', | |
'content' => http_build_query( array( |
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 | |
$ch = curl_init(); | |
curl_setopt( $ch, CURLOPT_URL, 'http://url.com' ); | |
curl_setopt( $ch, CURLOPT_HTTPHEADER, array( 'Content-Type: application/xml' ) ); | |
curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true ); | |
$output = curl_exec( $ch ); | |
curl_close( $ch ); | |
var_dump( $output ); |
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
#!/bin/bash | |
wget --auth-no-challenge --user='user' --password='pass' 'url' |
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 | |
// Change number or products per row to 3 | |
add_filter('loop_shop_columns', 'loop_columns'); | |
if (!function_exists('loop_columns')) { | |
function loop_columns() { | |
return 3; // 3 products per row | |
} | |
} |
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 | |
$cat = get_categories( array( | |
'taxonomy' => 'product_tag' | |
) ); | |
foreach( $cat as $key => $value ){ | |
var_dump( get_field( 'imagem', 'product_tag_'.$value->term_id ) ); | |
echo get_term_link( $value->term_id, 'product_tag' ); | |
} |
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 | |
add_filter( 'projects_loop_columns', 'jk_projects_columns', 99 ); | |
function jk_projects_columns( $cols ) { | |
$cols = 3; | |
return $cols; | |
} |
OlderNewer