Skip to content

Instantly share code, notes, and snippets.

@ingozoell
ingozoell / all-wordpress-js-in-footer.php
Created July 3, 2014 09:36
All WordPRess JS in Footer
sudo defaults write /Library/Preferences/com.apple.windowserver DisplayResolutionEnabled -bool YES
@ingozoell
ingozoell / conditional-comment-ie10.html
Created July 15, 2014 16:38
Conditional comments IE10
<!--[if !IE]><!-->
<script> // If It's not IE (or <IE10)
if (/*@cc_on!@*/false) { // If cc_on exists then if (!false)
document.documentElement.className+=' ie10'; // Add classname to element
}
</script>
<!--<![endif]-->
<!--
@ingozoell
ingozoell / Add-html-class-language.js
Last active August 29, 2015 14:04
Add html class "lang-en":lang
jQuery(document).ready(function () {
if ( jQuery('html').attr('lang') == 'en-US' ) {
jQuery('html').addClass('lang-en');
}
});
/* CSS */
/* Added class ".lang-en" by jQuery */
.ie6.lang-en .btn-infobox,
<?php if(qtrans_getLanguage() == "en") : ?>
<?php echo do_shortcode( '[contact-form 1 "Contact form 1"]' ) ?>
<?php endif ?>
<?php if(qtrans_getLanguage() == "fr") : ?>
<?php echo do_shortcode( '[contact-form 2 "Contact form 2"]' ) ?>
<?php endif ?>
<?php if(qtrans_getLanguage() == "nl") : ?>
<?php echo do_shortcode( '[contact-form 3 "Contact form 3"]' ) ?>
<?php endif ?>
@ingozoell
ingozoell / anfiehrungszeichen.js
Created July 23, 2014 10:09
Anführungszeichen "9966"
$('h5').prepend("&bdquo;").append("&ldquo;");
/**
* Create a shortcode to insert content of a page of specified ID
*
* @param array attributes of shortcode
* @return string $output Content of page specified, if no page id specified output = null
*/
function pa_insertPage($atts, $content = null) {
// Default output if no pageid given
$output = NULL;
/* Add function */
function cn_include_content($pid) {
$thepageinquestion = get_post($pid);
$content = $thepageinquestion->post_content;
$content = apply_filters('the_content', $content);
$content = str_replace(']]>', ']]>', $content);
echo $content;
}
@ingozoell
ingozoell / index.html
Last active August 29, 2015 14:05 — forked from anonymous/Reveal-Modal.markdown
Reveal Modal
<a href="#" class="big-link" data-reveal-ajax="true" data-reveal-id="myModal">
Fade and Pop
</a>
<div id="myModal" class="reveal-modal">
<h1>Reveal Modal Goodness</h1>
<p>This is a default modal in all its glory, but any of the styles here can easily be changed in the CSS.</p>
<a class="close-reveal-modal x">&#215;</a>
<a href="#" class="close-reveal-modal">Link to Close</a>
</div>
@ingozoell
ingozoell / jquery-default-fn-footer.js
Created August 17, 2014 15:27
jQuery default function (in footer)