Swedish counties, municipalities and districts in JSON format.
Svenska län och kommuner och distrikt i JSON format.
Downloaded from SCB 13 jan 2021.
| <?php | |
| function getElementAttribute ($attribute, $html) { | |
| if (preg_match('/' . $attribute . '="([^"]+)"/', $html, $match)) { | |
| return $match[1]; | |
| } | |
| return false; | |
| } |
Swedish counties, municipalities and districts in JSON format.
Svenska län och kommuner och distrikt i JSON format.
Downloaded from SCB 13 jan 2021.
| name: Build and deploy | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| branches: [master] | |
| jobs: | |
| build: |
| <?php | |
| function restrict_post_deletion ($post_ID) { | |
| $restricted_pages = [ | |
| get_option('page_on_front'), | |
| 123, | |
| 666 | |
| ]; | |
| if (!current_user_can('administrator') && in_array($post_ID, $restricted_pages)) { |
| # Test | |
| find . -name "node_modules" -type d -prune -print | xargs du -chs | |
| # Remove | |
| find . -name "node_modules" -type d -prune -print -exec rm -rf "{}" \; |
| /** | |
| * detect IE | |
| * returns version of IE or false, if browser is not Internet Explorer | |
| */ | |
| function detectIE() { | |
| var ua = window.navigator.userAgent; | |
| // Test values; Uncomment to check result … | |
| // IE 10 |
| function handleHidden (callbackHidden, callbackVisible) { | |
| var browserPrefixes = ['moz', 'ms', 'o', 'webkit'] | |
| var isVisible = true // internal flag, defaults to true | |
| // get the correct attribute name | |
| function getHiddenPropertyName (prefix) { | |
| return (prefix ? prefix + 'Hidden' : 'hidden') | |
| } | |
| // get the correct event name |
| /** | |
| * Text truncation | |
| * | |
| * Prevent text from wrapping onto multiple lines, and truncate with an | |
| * ellipsis. | |
| * | |
| * 1. Ensure that the node has a maximum width after which truncation can | |
| * occur. | |
| * 2. Fix for IE 8/9 if `word-wrap: break-word` is in effect on ancestor | |
| * nodes. |
| .Cart { | |
| transition: 300ms; | |
| } | |
| .Cart[hidden] { | |
| display: inline-block; | |
| opacity: 0; | |
| visibility: hidden; | |
| } |
I hereby claim:
To claim this, I am signing this object: