Overview of ACF field attributes to assist with field authorship via StoutLogic's Acf Builder.
Full description about registering ACF Fields for PHP is available her: Register fields via PHP
| /** | |
| * Formated Dumper (tee hee) | |
| * @return {string} a parsable string representation of a variable | |
| */ | |
| function jumpoff_dump( $var, $name = '' ) { | |
| echo '<pre>'; | |
| if ( '' !== $name ) { | |
| echo $name . ': '; | |
| } | |
| var_export( $var ); |
Overview of ACF field attributes to assist with field authorship via StoutLogic's Acf Builder.
Full description about registering ACF Fields for PHP is available her: Register fields via PHP
| /** | |
| * Get Lat Lng from Address via gmaps geocode api | |
| * results[0].geometry.location.lat(), results[0].geometry.location.lng() | |
| */ | |
| function geocodeAddress() { | |
| var address = getAddress(); | |
| geocoder.geocode( { 'address': address}, function(results, status) { | |
| if (status == 'OK') { | |
| //console.log(results); |
| /** | |
| * No Current Sessions | |
| * Simple class to prevent concurrent user sessions. | |
| */ | |
| class NoConcurrentSessions { | |
| function __construct() { | |
| add_action( 'init', array( $this, 'only_one' ) ); | |
| } |
| <IfModule mod_ssl.c> | |
| # Enable TLSv1.2, disable SSLv3.0, TLSv1.0 and TLSv1.1 | |
| SSLProtocol all -SSLv3 -TLSv1 -TLSv1.1 | |
| # Enable modern TLS cipher suites | |
| SSLCipherSuite ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256 | |
| # The order of cipher suites matters | |
| SSLHonorCipherOrder on |
| <?php | |
| /** | |
| * Authentication Login | |
| * @link http://php.net/manual/en/features.http-auth.php | |
| */ | |
| if ( ! defined( 'ABSPATH' ) ) exit; | |
| if (isset($_SERVER['PHP_AUTH_USER']) && isset($_SERVER['PHP_AUTH_PW'])) { | |
| if ($_SERVER['PHP_AUTH_USER'] != 'admin' || |
| # Open Ampps Application -> MySQL Tab -> Configuration. | |
| # In [mysqld] section, add line: | |
| innodb_force_recovery = 1 | |
| # If successful, comment out line. |
| <button class="js-chat-btn btn-chat"> | |
| <svg class="btn-chat__icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 426.667 426.667" width="25" height="25"><path d="M384 0H42.667C19.093 0 0 19.093 0 42.667v384l85.333-85.333H384c23.573 0 42.667-19.093 42.667-42.667v-256C426.667 19.093 407.573 0 384 0z" fill="#FFF"/></svg> | |
| <span class="btn-chat__text">Live Chat?</span> | |
| </button> | |
| <style> | |
| .btn-chat { | |
| position: fixed; | |
| left: 1em; | |
| bottom: 1em; |
| # Block WordPress xmlrpc.php requests | |
| <Files xmlrpc.php> | |
| order deny,allow | |
| deny from all | |
| </Files> |