View gist:727f50243cb722d9d4941f18c72474c1
🏃. 5x Magento Certified, 2x Magento Master. ✝ Follower. Co-host @magetalk,@commercefuture. Organizer @magentosofla. Evangelist @somethingdigitl
View magento-check.php
<?php
/**
* A simple fix for a shell execution on preg_match('/[0-9]\.[0-9]+\.[0-9]+/', shell_exec('mysql -V'), $version);
* The only edit that was done is that shell_exec('mysql -V') was changed to mysql_get_server_info() because not all
* systems have shell access. XAMPP, WAMP, or any Windows system might not have this type of access. mysql_get_server_info()
* is easier to use because it pulls the MySQL version from phpinfo() and is compatible with all Operating Systems.
* @link http://www.magentocommerce.com/knowledge-base/entry/how-do-i-know-if-my-server-is-compatible-with-magento
* @author Magento Inc.
*/
View election-results.txt
OpenSTV version 1.7 (http://www.OpenSTV.org/)
Suggested donation for using OpenSTV for an election is $50. Please go to
http://www.OpenSTV.org/donate to donate via PayPal, Google Checkout, or
Amazon Payments.
Certified election reports are also available. Please go to
http://www.openstv.org/certified-reports for more information.
Loading ballots from file magento-stackexchange-com-2015-election-results.blt.
View SassMeister-input-HTML.html
<a href="#" class="button">Obnoxious button</a>
View gist:fd3d153b27f7b6da9992
<?php
$__ = array(Mage::helper('yourcompany/helper'), '__');
//usage
echo $__('Translate me');
View reproduce.md
<?php

require('app/Mage.php');
Mage::app();


$product = Mage::getModel('catalog/product')->getCollection()->getFirstItem();

var_dump($product->getData('media_gallery'));
View Observer.php
class Sample_Model_Observer
{
protected $colToAdd = 'colname';
/**
* @param Varien_Event_Observer $observer
*/
public function urapidflow_profile_action( $observer )
{
$action = $observer->getData( 'action' );
$profile = $observer->getData( 'profile' );
View debugging.md

Debugging (Resource) Model Instantiation

Follow each step manually and any bugs during (resource) model instantiation will become obvious.

Since many people find model and resource model instantiation to be one of the more challenging things in Magento 1, these are all the steps Magento does to resolve the factory name to the real PHP class name.

To debug, simply follow each step manually until you find a non-match. This works really well in my experience.
Less guessing, more and faster results.

In the examples I use a factory name of "example/thing".

View cornify.js
var cornify_count = 0;
var cornify_add = function() {
cornify_count += 1;
var cornify_url = 'http://www.cornify.com/';
var div = document.createElement('div');
div.style.position = 'fixed';
var numType = 'px';
var heightRandom = Math.random()*.75;
var windowHeight = 768;