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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<style type="text/css"> | |
div { | |
display: block; | |
width: 200px; | |
height: 200px; |
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
/** | |
* How to vertical align (top | middle | bottom) your html elements | |
* @usage: | |
* <div class="valign-box"> | |
* <div class="valign-top"></div> | |
* <div class="valign-middle"></div> | |
* <div class="valign-bottom"></div> | |
* </div> | |
*/ | |
.valign-box { |
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
text.replace(/<a.*?href=["']([^"']*)["'][^>]*>([^<]*)</a>/igm, "[$2]($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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond %{REQUEST_URI} !/robots.txt [NC] | |
Rewriterule ^(.*)$ http://yournewsite.com/$1 [L,R=301] | |
</IfModule> |
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
// | |
// Best way to fix it even it'll never been fixed in WordPress core | |
if ($_SERVER['HTTP_PROXY_HTTPS'] == 'https') $_SERVER['HTTPS']='on'; | |
// | |
// OR | |
// | |
if ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') $_SERVER['HTTPS']='on'; |
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 ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') $_SERVER['HTTPS']='on'; | |
class JConfig { | |
/* default datas */ |
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
# banvhost begin | |
RewriteEngine On | |
RewriteCond %{REMOTE_ADDR} !^NUM\.NUM\.NUM\.NUM\. | |
#RewriteRule ^.* http://example.com/maintenance.html [P,L] | |
RewriteCond %{REQUEST_URI} !^/maintenance/ | |
RewriteRule ^.* /maintenance/ [R,L] | |
# banvhost end |
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
git rm -r --cached . | |
git add . | |
git commit -am "Remove ignored files" |
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
/** @var WP $wp */ | |
/** @var wpdb $wpdb */ | |
/** @var WP_Locale $wp_locale */ | |
/** @var WP_Query $wp_query */ | |
/** @var WP_Query $wp_the_query */ | |
/** @var WP_Rewrite $wp_rewrite */ | |
/** @var WP_Roles $wp_roles */ | |
/** @var WP_Widget_Factory $wp_widget_factory */ | |
/** @var WP_Post $post */ | |
/** @var WP_Embed $wp_embed */ |
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
/** | |
* Inverse dom elements for mobile display | |
* @link with the help of http://www.alsacreations.com/tuto/lire/1493-css3-flexbox-layout-module.html | |
*/ | |
.media-inverse { | |
display: flex; | |
flex-wrap: wrap-reverse; | |
} | |
.media-inverse > div { | |
width: 100%; |
OlderNewer