Skip to content

Instantly share code, notes, and snippets.

View lukasleitsch's full-sized avatar

Lukas Leitsch lukasleitsch

View GitHub Profile
@lukasleitsch
lukasleitsch / VPN_On_Demand.xml
Last active July 8, 2018 18:19 — forked from noestreich/VPN_On_Demand.xml
Der VPN-On-Demand Codeblock zur Integration in eine Profildatei. Siehe: http://www.iphone-ticker.de/?p=97462
<!-- VPN-On-Demand Codeblock -->
<key>OnDemandEnabled</key>
<integer>1</integer>
<key>OnDemandRules</key>
<array>
<dict>
<!-- VPN bei ausgewählten WLAN-Netzen deaktivieren -->
<key>InterfaceTypeMatch</key>
<string>WiFi</string>
<key>SSIDMatch</key>
@lukasleitsch
lukasleitsch / functions.php
Last active May 18, 2016 21:02 — forked from tomazzaman/functions.php
Insert responsive image in WordPress with HTML5 <figure> tag and caption
<?php
// Don't include the opening tag
function html5_insert_image( $html, $id, $caption, $title, $align, $url, $size, $alt ) {
$img = wp_get_attachment_image($id, $size, false, array('alt' => $alt));
$html5 = "<figure id='post-$id media-$id' class='align-$align'>";
if ( $url ) {
$html5 .= "<a href='$url' class='image-link'>$img</a>";
} else {