Skip to content

Instantly share code, notes, and snippets.

View gist:c22085c137b4a8b84e580db298ac4656
$event = $container->get('event');
$event->on('cli.commands',function($console){
// you can now bind a route to the console //
$console->command('users:add',function($arguments) {
//$arguments come from the command line like this...
// php run users:add --username="cannap" --password="dp"
// $arguments['username']=cannap;
// $arguments['password']="dp";
$users = $this->get('users'); // get a pre registered service container class under users
return $users->addUser($arguments);
View foo.php
<?php
$console->command('users:add',function($arguments) {
$success = $this->get('users')->add($arguments);
};
//USAGE: php run users:add --username=foo --password=bar
?>
View Apple system log
Marker - 11 Jul 2016, 12:32:52
Jul 11 12:33:03 Alexs-MacBook-Pro MobileSafari[1313]: the behavior of the UICollectionViewFlowLayout is not defined because:
Jul 11 12:33:03 Alexs-MacBook-Pro MobileSafari[1313]: the item width must be less than the width of the UICollectionView minus the section insets left and right values, minus the content insets left and right values.
Jul 11 12:33:03 Alexs-MacBook-Pro MobileSafari[1313]: The relevant UICollectionViewFlowLayout instance is <_UIAlertControllerCollectionViewFlowLayout: 0x7fcc4ecf27a0>, and it is attached to <UICollectionView: 0x7fcc4d921600; frame = (0 44; 10 0); clipsToBounds = YES; gestureRecognizers = <NSArray: 0x7fcc4ec6fdb0>; animations = { bounds.origin=<CASpringAnimation: 0x7fcc4ecc1fb0>; bounds.size=<CASpringAnimation: 0x7fcc4ecc6f80>; position=<CASpringAnimation: 0x7fcc4ecc7100>; }; layer = <CALayer: 0x7fcc4ecd70d0>; contentOffset: {0, 0}; contentSize: {0, 0}> collection view layout: <_UIAlertControllerCollectionViewFlowLayout: 0x7fcc4ecf27a0>.
Jul 1
View Apple system log
I have found a very very strange bug in Safari and Chrome on iPad, iPhone and Simulator (Xcode)
On certain photo's (in my case it was photo's from an older iOS pre-update) the uploader will not let me choose a file. By this I mean that it will open the "choose files from "Take photo" and "Photo Library" but as soon as I choose (certain) photo's it fails.
This is where it gets strange. On the same devices it will allow me quite easily to upload other photos that are in the same "Photo library" - the difference being that they're newer images and not pre iOS update.
I have reproduced this on the Xcode simulator and it raises some interesting logs.
`Marker - 11 Jul 2016, 12:32:52
Jul 11 12:33:03 Alexs-MacBook-Pro MobileSafari[1313]: the behavior of the UICollectionViewFlowLayout is not defined because:
View gist:f7386b30a80d72b426498915e33d1e5f
server {
listen 80;
server_name .yourdomain.com;
return 301 https://yourdomain.com$request_uri;
}
You can’t perform that action at this time.