Skip to content

Instantly share code, notes, and snippets.

View meabed's full-sized avatar
👨‍💻
Coding

Mohamed Meabed meabed

👨‍💻
Coding
View GitHub Profile

Most web traffic should be available over HTTPS. AWS makes this easy with Elastic Load Balancers (ELBs). When configured with an SSL certificate, an ELB will perform SSL termination and forward the traffic onto our group of non-encrypted web server instances.

Using an ELB is advantageous to offload many responsibilities to Amazon:

Maintaining uptime for the primary service DNS name Balancing traffic to one or more instances Re-balancing traffic when instances are added, removed, or become unhealthy Storing and applying your mission-critical secret SSL certificate Configuring critical aspects of HTTP like what SSL protocols, cypher and options are available and permitted

angular.module('globalmodule')
.config(['$provide', '$httpProvider', function($provide, $httpProvider){
$provide.factory('GlobalAjaxInterceptor', ['$q', '$rootScope', function($q, $rootScope){
var currentRequests={http: {}, ajax: {}};
function addHttpRequest(conf){
currentRequests.http[conf.url] = conf.promiseObj;
}
<?php
/**
* Merge two dimensional arrays my way
*
* Will merge keys even if they are of type int
*
* @param array $array1 Initial array to merge.
* @param array ... Variable list of arrays to recursively merge.
*

Magento Code Snippets

Download extension manually using mage

./mage config-set preferred_state stable
./mage clear-cache
./mage sync
./mage download community Module_Name
@meabed
meabed / mpnml
Created February 17, 2014 06:13 — forked from holms/mpnml
sudo port -v install mysql5-server
# Don't do any post-install instructions
sudo -u _mysql mysql_install_db5
# if above command produce this error: ERROR: 1004 Can't create file '/var/tmp/#sqle967_1_0.frm' (errno: 9)
# do this:
# sudo chown -R mysql:mysql /opt/local/var/db/mysql5
# sudo chmod u+rwx,go= /opt/local/var/db/mysql5
# sudo /opt/local/lib/mysql5/bin/mysql_install_db --user=mysql
ּ_בּ
בּ_בּ
טּ_טּ
כּ‗כּ
לּ_לּ
מּ_מּ
סּ_סּ
תּ_תּ
٩(×̯×)۶
٩(̾●̮̮̃̾•̃̾)۶