This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<style> | |
.with-sidebar { | |
display: flex; | |
flex-wrap: wrap; | |
margin: -1.5rem; | |
} | |
.sidebar, .not-sidebar { | |
margin: 1.5rem; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
as seen at https://www.smashingmagazine.com/2018/02/generated-content-grid-layout/ | |
*/ | |
.elem { | |
text-align: center; | |
display: grid; | |
grid-template-columns: 1fr auto 1fr; | |
grid-gap: 20px; | |
} | |
@supports (display: grid) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* get youtube video ID from URL | |
* as found at http://stackoverflow.com/questions/6556559/youtube-api-extract-video-id | |
* | |
* @param string $url | |
* @return string Youtube video id or FALSE if none found. | |
*/ | |
function youtube_id_from_url($url) { | |
$pattern = |