running:
bash create-vod-hls.sh beach.mkv
will produce:
beach/
|- playlist.m3u8
|- 360p.m3u8
| <?php | |
| /** | |
| * @file | |
| * Contains \Drupal\jcmodule\Theme\ThemeNegotiator | |
| */ | |
| namespace Drupal\jcmodule\Theme; | |
| use Drupal\Core\Routing\RouteMatchInterface; | |
| use Drupal\Core\Theme\ThemeNegotiatorInterface; |
running:
bash create-vod-hls.sh beach.mkv
will produce:
beach/
|- playlist.m3u8
|- 360p.m3u8
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <title>Remove rubberband scrolling from web apps on mobile safari and standalone (iOS)</title> | |
| <meta name="apple-mobile-web-app-capable" content="yes"> | |
| <meta name="apple-touch-fullscreen" content="yes"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no"> | |
| <style> | |
| html, body {margin: 0; padding: 0; width:100%; height:100%; overflow: hidden; background: #333} | |
| p.center { |
| use Drupal\Core\Entity\EntityStorageInterface; | |
| +use Drupal\Core\Entity\RevisionableContentEntityBase; | |
| use Drupal\Core\Field\BaseFieldDefinition; | |
| use Drupal\Core\Entity\ContentEntityBase; | |
| use Drupal\Core\Entity\EntityChangedTrait; | |
| @@ -19,6 +20,7 @@ | |
| * @ContentEntityType( | |
| * id = "restaurant", | |
| * label = @Translation("Restaurant"), | |
| + * show_revision_ui = TRUE, |
| #!/bin/bash | |
| # download | |
| wget https://bin.equinox.io/c/4VmDzA7iaHb/ngrok-stable-linux-amd64.zip | |
| # unzip | |
| unzip ngrok-stable-linux-amd64.zip | |
| # move to /usr/local/bin | |
| sudo mv ngrok /usr/local/bin |
// Not much of PHP magic
// This just takes a PDF file from a path
// and executes Ghostscript to convert your
// PDF to version 1.4
// You need to have Ghostscript installed
// See https://www.ghostscript.com/Documentation.html
$PDFFile = '/path/to/your/pdf.pdf';| <?php | |
| // The drupal_set_message() function is being deprecated! | |
| // @see https://api.drupal.org/api/drupal/core%21includes%21bootstrap.inc/function/drupal_set_message/8.5.x | |
| // > Deprecated in Drupal 8.5.0 and will be removed before Drupal 9.0.0. | |
| // > Use \Drupal\Core\Messenger\MessengerInterface::addMessage() instead. | |
| // In some custom code. | |
| \Drupal::messenger()->addMessage('Say something else'); |
Find MAMP's installed PHP version(s) you want to use the PHP CLI for:
$ ls -l /Applications/MAMP/bin/php/
.bash_profile in edit mode, in order to add aliases for accessing the PHP CLI locally$ pico ~/.bash_profile
| /* Circular loader ring (a real basic one) | |
| * | |
| * By: Andrew Tuline | |
| * | |
| * Date: May, 2019 | |
| * | |
| * One version uses a loop and fixed colours, while the other uses a fader. | |
| * | |
| */ |