Skip to content

Instantly share code, notes, and snippets.


Rabea Abdelwahab RabeaWahab

Block or report user

Report or block RabeaWahab

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View yamile.js
* The weathermap application.
var express = require('express');
var request = require('request');
// Rabea: checkout out Dotenv module, it is a better way of handling creds
var config = require('./config');
var app = express();
View cancel.php
public function retrieveCoupon($observer)
$payment = $observer->getEvent()->getPayment();
$order = $payment->getOrder();
if ($code = $order->getCouponCode()) {
$coupon = Mage::getModel('salesrule/coupon')->load($code, 'code');
View pi.go
package main
import (
func init() {
View dalek_report.js
"tests": [
"id": "test2",
"name": " HomePage",
"browser": "PhantomJS",
"status": true,
"passedAssertions": 5,
"failedAssertions": 0,
"actions": [
View dalek_homepage.js
module.exports = {
' HomePage': function (test) {
// Just a random number
var now = Math.floor( / 1000);
// Open
View CategoryAttribute.php
* Use those two commands to delete the attribute for testing
//$this->removeAttribute('catalog_category', 'custom_attribute_1');
//$this->removeAttribute('catalog_category', 'custom_attribute_2');
// creating the attributes
View Sheet.html
<tr><th>File Path</th>
<td> 'customer_address_format'</td>
View MagentoOneStepCoupon.php
public function couponPostAction()
* No reason continue with empty shopping cart
if ($this->_expireAjax()) {
View MonitRedis.conf
check process redis with pidfile /var/run/redis/
start program = “/etc/init.d/redis start”
stop program = “/etc/init.d/redis stop”
if failed host port 6379 then restart
if 5 restarts within 5 cycles then alert
View GoogleAnalytics.php
use UnitedPrototype\GoogleAnalytics;
// initiate the tracker
$tracker = new GoogleAnalytics\Tracker($accountId, $account_domain);
// Assemble Visitor information
// (could also get unserialized from database)
$visitor = new GoogleAnalytics\Visitor();
You can’t perform that action at this time.