This file contains 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
public function processJob($job) | |
{ | |
try { | |
// stuff | |
} catch(Exception $e) { | |
if(Offers\Model::getDb()->errno() == 2006) { | |
Offers\Model::connectDb(); | |
$this->processJob($job); | |
} else { | |
throw $e; |
This file contains 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 | |
public function getActionText() | |
{ | |
session_start(); | |
if($this->coupon_image) { | |
$action = 'view coupon'; | |
} else if($this->in_store) { | |
if($this->product_deal) { | |
$action = 'get deal'; |
This file contains 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
All, | |
In an effort to try and figure out how we can get more done, I need to collect some more data on what we're currently doing and how long it's taking. As I mentioned last week, please make sure to log work on tickets at the time the work is done, don't save it until the ticket is complete. For tickets that take >1 day, I would expect this means you're at least logging work on them twice a day. I want to make sure the estimates and work logs on the ticket are for programming time only. Don't factor in the auxiliary tasks like code reviews or acceptance meetings in either the estimates or the work logs. If you have to go spend 2 hours learning something to get a ticket accomplished, go ahead and count that as a work log, and also include it in the estimates. | |
The main things i'm trying to learn are 1) how much capacity do build things do we actually have, and 2) can we get more by improving efficiency, and if not, how many people do we need to hire. With that in mind, and looking at past weeks' number o |
This file contains 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 | |
$array = json_decode(json_encode(simplexml_load_string($str)), true); |
This file contains 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
---foo.php | |
Namespace mylib; | |
class Foo implements ArrayAccess | |
{ | |
public function _call() | |
} | |
--bar.php |
This file contains 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 | |
namespace Genoa\Data\Transport; | |
use Genoa\Model\Provider; | |
use Psr\Log\LoggerInterface; | |
class Cjftp extends \SplFileObject | |
{ | |
const TEMP_DIR = "/tmp/genoa"; |
This file contains 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
public function testSetGet() | |
{ | |
$d = new Document; | |
$d->foo[] = 'bar'; | |
$this->assertEquals(['bar'], $d->foo); | |
$d->bar = 'baz'; | |
$test = $d->bar; | |
$test = 'foo'; |
This file contains 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
{ | |
"_id": "foo", | |
"mapping": { | |
"1->2->3": "tag1", | |
"$woozles!!": "tag2" | |
}, | |
"origin": { | |
"name": "Walmart.com", | |
"slug": "walmart" | |
} |