#HTML presentation tools
There are many HTML presentation tools and they are all created for slightly different reasons. Here's an overview. Please let me know if I forgot any.
##CSSS
CSS-based SlideShow System
<?php | |
$countries = array | |
( | |
'AF' => 'Afghanistan', | |
'AX' => 'Aland Islands', | |
'AL' => 'Albania', | |
'DZ' => 'Algeria', | |
'AS' => 'American Samoa', | |
'AD' => 'Andorra', |
<?php | |
/* gform_pre_submission will do all forms. gform_pre_submission_1 will do a form with an ID of 1 | |
* Keep an eye on the priority of the filter. In this case I used 9 because the Salesforce plugin we used ran a presubmission filter at 10 so we needed this to happen before it | |
*/ | |
add_filter( "gform_pre_submission_1", "add_salesforce_campaign_id_footer", 9 ); | |
function add_salesforce_campaign_id_footer( $form ){ | |
foreach($form["fields"] as &$field) | |
if($field["id"] == 2){ | |
/* Set the variable you want here - in some cases you might need a switch based on the page ID. | |
* $page_id = get_the_ID(); |
.sticky, | |
.bypostauthor, | |
.gallery-caption | |
display: normal | |
.alignright | |
float: right | |
display: block | |
.alignleft |
var inFolder = Folder.selectDialog("Please select folder to process"); | |
if(inFolder !== null) { | |
var fileList = inFolder.getFiles(/\.(jpg|tif|psd|)$/i); | |
var outfolderName = prompt('Folder name', 'zoom'); | |
var outfolder = new Folder(decodeURI(inFolder) + "/" + outfolderName); | |
if (!outfolder.exists) outfolder.create(); | |
for(var a = 0; a < fileList.length; a++) { |
/* Row and Column defaults */ | |
.row { margin-left: auto; margin-right: auto; margin-top: 0; margin-bottom: 0; max-width: 62.5em; width: 100%; } | |
.row .row.collapse { margin-left: 0; margin-right: 0; max-width: none; width: auto; } | |
.row .row { margin-left: -0.9375em; margin-right: -0.9375em; max-width: none; width: auto; } | |
.row.collapse .column, .row.collapse .columns { padding-left: 0; padding-right: 0; float: left; } | |
.column, .columns { padding-left: 0.9375em; padding-right: 0.9375em; width: 100%; float: left; position: relative; } | |
/* Up to 640px */ | |
@media only screen { | |
.small-1 { width: 8.33333% } |
Full tutorial: http://hofmannsven.com/2013/laboratory/svg-stacking/
Demo (with a div): http://hofmannsven.com/demo/svg-stacking/
Demo (with a background image): http://hofmannsven.com/demo/svg-stacks/background/
<?php | |
// Warning: this will overwrite every post in your database | |
// BACKUP FIRST! | |
clean_post_content(); | |
function clean_post_content() { | |
$posts = get_posts(array( | |
'post_type' => array('post'), // or page, or cpt | |
'post_status' => 'publish', // or any, draft, etc |
/** | |
* VH and VW units can cause issues on iOS devices: http://caniuse.com/#feat=viewport-units | |
* | |
* To overcome this, create media queries that target the width, height, and orientation of iOS devices. | |
* It isn't optimal, but there is really no other way to solve the problem. In this example, I am fixing | |
* the height of element `.foo` —which is a full width and height cover image. | |
* | |
* iOS Resolution Quick Reference: http://www.iosres.com/ | |
*/ | |
/* | |
* Generate a SVG-sprite mixin for Sass | |
* ==================================== | |
* | |
* Gaya Kessler - http://gaya.ninja - http://twitter.com/GayaNinja | |
* | |
* SVGSprite is a wonderful package, but doesn't enable responsive sprites out of the box. | |
* This moustache template generates a sass file with a mixin for the generated SVG-sprite. | |
* Calculates the position and size of the background by filename. | |
* Included SVG image scales to width and height. |