Skip to content

Instantly share code, notes, and snippets.

View centerax's full-sized avatar
✈️

Pablo S. Benitez centerax

✈️
View GitHub Profile
@centerax
centerax / create_user.php
Created June 26, 2014 14:50
Create New Magento admin User programmatically
<?php
// Create New admin User programmatically.
require_once('./app/Mage.php');
umask(0);
Mage::app();
try {
$user = Mage::getModel('admin/user')
->setData(array(
#!/bin/sh
# http://www.alfredklomp.com/programming/shrinkpdf
# Licensed under the 3-clause BSD license:
#
# Copyright (c) 2014-2019, Alfred Klomp
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
---- /var/www/magento2/dev/tests/unit> php /var/www/magento2/./vendor/phpunit/phpunit/phpunit
PHPUnit 4.1.0 by Sebastian Bergmann.
Configuration read from /var/www/magento2/dev/tests/unit/phpunit.xml.dist
........................................................... 59 / 21839 ( 0%)
........................................................... 118 / 21839 ( 0%)
........................................................... 177 / 21839 ( 0%)
@centerax
centerax / keybase.md
Last active February 1, 2017 12:43
keybase.md

Keybase proof

I hereby claim:

  • I am centerax on github.
  • I am pablobenitez (https://keybase.io/pablobenitez) on keybase.
  • I have a public key ASDh42P370WXdmjfJCqibYEeyoBM6sctOzOL4Jenw942bgo

To claim this, I am signing this object:

#!/usr/bin/php
<?php
/**
* Copyright © 2015 Magento. All rights reserved.
* See https://github.com/magento/magento2/blob/develop/COPYING.txt for license details.
*/
/**
* validate_m2_package.php - a script that checks a given M2 zip package to ensure
* it is structured correctly and has all the required files.
<?php
class Ebizmarts_SageOne_Block_Adminhtml_Sales_Order_Creditnote_Note extends Mage_Core_Block_Template {
public function getCreditMemo() {
return Mage::registry('current_creditmemo');
}
/**
@centerax
centerax / sagePaySuite_Checkout.js
Created August 5, 2013 20:02
PayPal Hosted PRO with Sage Pay Suite - OneStepCheckout
//Before 'if(!this.isSagePay()) {' add
if(this.getPaymentMethod() == "hosted_pro") {
submitOsc($('onestepcheckout-form'), location.href, 'Please wait, processing your order...', SuiteConfig.getConfig('global', 'osc_loading_image'));
window._sagepayprocessingorder = false;
return;
}
/**
* Sage50 compatible Basket.
*
* @param Mage_Sales_Model_Quote $quote
* @return string Basket as string.
*/
public function getSageBasket($quote) {
$basket = '';
<?php
/**
* @see Ebizmarts_SagePaySuite_Block_Paypal_Express_Review
*/
?>
<div class="page-title">
<h1><?php echo $this->__('Review Order') ?></h1>
</div>
<?php echo $this->getMessagesBlock()->getGroupedHtml() ?>
<currencies>
<currency type="AFN">
<symbol>Af</symbol>
</currency>
<currency type="ANG">
<symbol>NAf.</symbol>
</currency>
<currency type="AOA">
<symbol>Kz</symbol>
</currency>