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 | |
abstract class BaseModelManager { | |
protected $em; | |
protected $class; | |
protected $repository; | |
protected $container; | |
/** | |
* Constructor. |
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
"use strict"; | |
/** | |
* @author geoff | |
*/ | |
var Marshal = (function() { | |
var debug = false; | |
var symbols; | |
var marshal_major = 4, marshal_minor = 8; |
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 | |
error_reporting(E_ALL); | |
define('NUM_FEATURES', 3); | |
// My dataset describes cities around the world where I might consider living. | |
// Each sample (city) consists of 3 features: | |
// * Feature 1: average low winter temperature in the city | |
// * Feature 2: city population, in millions |
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 | |
/** | |
* Functionality taken from Mage_ImportExport_Model_Import_Entity_Product | |
*/ | |
class Your_Module_Model_Category_Finder | |
{ | |
/** | |
* Categories text-path to ID hash. | |
* | |
* @var array |
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
#!/bin/bash | |
##################################################################################################### | |
# Cache Warmer | |
# | |
# Useage: cache-warmer.sh ...args | |
# | |
# This script grabs the sitemap of the site you wish to warm, then grep the urls to wget each one | |
# to cache it on the server. I'm sure there are better ways to do this, but this was a simple enough | |
# method for my needs. I didn't want to have to type in the urls each time I warmed their cache, so | |
# I just made simple functions with short names to feed those urls into the cache warming function. |