This file will setup Wordpress, MySQL & PHPMyAdmin with a single command. Add the code below to a file called "docker-compose.yaml" and run the command
$ docker-compose up -d
# To Tear Down
$ docker-compose down --volumes
# If this commit is applied, it will: | |
# Why was this change made? | |
# Any references to tickets, articles etc? | |
#Customize WordPress Gallery HTML Output
This snippet is for modifying the shortcode and output for Wordpress's built in gallery function HTML. Particularly to modify the stucture for use with the Salvattore & Featherlight jquery to creat a masonary gallery with lightbox as none of the wordpress plugins meet my need. The source of the function is a little out of date compared with the current function Wordpress is using to output the galleries, but meets my needs as I am stripping out most of the markup. Plus I can't seem to get the shortcode_atts assigned in the function to work but thats not a deal breaker. I've updated the php with my new function. Still not sure if this is the best way to go about this but it works well for my need.
I've also added a second if statment to create another modified gallery to create a homepage slideshow using the wordpress agllery function and add suport for the Responsiveslides Jquery plugin.
I am using a conditional statment to check if the
function wp_api_encode_acf($data,$post,$context){ | |
$data['meta'] = array_merge($data['meta'],get_fields($post['ID'])); | |
return $data; | |
} | |
if( function_exists('get_fields') ){ | |
add_filter('json_prepare_post', 'wp_api_encode_acf', 10, 3); | |
} |
// Fonts mixin | |
font-url(file) | |
return '../fonts/' + file | |
webfont(family, file, hack-chrome-windows = false, weight = 'normal') | |
@font-face | |
font-family family | |
src url(font-url(file + '.eot')) | |
src url(font-url(file + '.eot?#iefix')) format('embedded-opentype'), | |
url(font-url(file + '.woff')) format('woff'), |