Consider supporting my work by purchasing the course this tutorial is a part of i.e. VSCode Power User →
- Make sure your
Local by FlyWheel
WordPress install is a custom install
... | |
Beautifier.prototype.beautify = function() { | |
... | |
var source_text = this._source_text; | |
// BEGIN | |
source_text = source_text.replace(/\{\{(--)?((?:(?!(--)?\}\}).)+)(--)?\}\}/g, function(m, ds, c, dh, de) { |
Consider supporting my work by purchasing the course this tutorial is a part of i.e. VSCode Power User →
Local by FlyWheel
WordPress install is a custom install/** | |
* Add this to your setup.php | |
* Usage @loop( $wp_query ) or $loop and end with @endloop | |
* the new $loop variable is available | |
*/ | |
/** | |
* Create @loop Blade directive | |
*/ | |
sage('blade')->compiler()->directive('loop', function ( $query = null ) { |
<?php | |
/** | |
* This class handles downloading a remote image file and inserting it | |
* into the WP Media Library. | |
* | |
* Usage: | |
* $download_remote_image = new KM_Download_Remote_Image( $url ); | |
* $attachment_id = $download_remote_image->download(); | |
* |
# Don't show errors which contain full path diclosure (FPD) | |
# Use that line only if PHP is installed as a module and not per CGI | |
# try using a php.ini in that case. | |
# Change mod_php5.c to mod_php7.c if you are running PHP7 | |
<IfModule mod_php5.c> | |
php_flag display_errors Off | |
php_value session.cookie_httponly 1 | |
php_value session.cookie_secure 1 | |
</IfModule> |
This is an incomplete list of resources including courses and individuals who publish content that has helped me grow as a web developer and designer. Many of these resources are WordPress-specific as that is my current area of specialization. This list will grow over time. If you've got something to add, send me a link @kevinwhoffman and I'll check it out!
<?php | |
function change_yoast_seo_og_meta() { | |
add_filter( 'wpseo_opengraph_desc', 'change_desc' ); | |
} | |
function change_desc( $desc ) { | |
// This article is actually a landing page for an eBook | |
if( is_singular( 123 ) ) { |
admin
user + generate a new passwordHello, visitors! If you want an updated version of this styleguide in repo form with tons of real-life examples… check out Trellisheets! https://github.com/trello/trellisheets
“I perfectly understand our CSS. I never have any issues with cascading rules. I never have to use !important
or inline styles. Even though somebody else wrote this bit of CSS, I know exactly how it works and how to extend it. Fixes are easy! I have a hard time breaking our CSS. I know exactly where to put new CSS. We use all of our CSS and it’s pretty small overall. When I delete a template, I know the exact corresponding CSS file and I can delete it all at once. Nothing gets left behind.”
You often hear updog saying stuff like this. Who’s updog? Not much, who is up with you?
################################################################ | |
# Example configuration file for nginx | |
# | |
# To add a new local WordPress domain to your environment, copy | |
# this file using a filename that matches the domain you wish to | |
# setup. For example - mylocaldomain.com.conf would be an ideal | |
# filename for http://mylocaldomain.com | |
# | |
# Once copied, you will need to modify two settings in the server | |
# configuration provided: |