Skip to content

Instantly share code, notes, and snippets.

View sirakoff's full-sized avatar
🎯
Focusing

Daniel Sirakov sirakoff

🎯
Focusing
View GitHub Profile
@sirakoff
sirakoff / meta-tags.md
Created June 13, 2019 09:22 — forked from lancejpollard/meta-tags.md
Complete List of HTML Meta Tags

Copied from http://code.lancepollard.com/complete-list-of-html-meta-tags/

Basic HTML Meta Tags

<meta name="keywords" content="your, tags"/>
<meta name="description" content="150 words"/>
<meta name="subject" content="your website's subject">
<meta name="copyright"content="company name">
<meta name="language" content="ES">
@sirakoff
sirakoff / create_coupon.php
Created May 16, 2019 10:09 — forked from vikramacharya/create_coupon.php
Create Coupon Programmatically Magento ver1
<?php
//Initialize Mage Object
require_once 'app/Mage.php';
Mage::app();
//Code to create coupon
$couponCode='COUPONCODE'; //couponcode
$rule = Mage::getModel('salesrule/rule'); //initialize salesrule
$customer_groups = array(0,1); // Add customer group here
@sirakoff
sirakoff / grafana custom.ini
Created December 26, 2016 07:26 — forked from mvadu/grafana custom.ini
nginx config for using grafana, Influxdb via reverse proxy with authentication
# The full public facing url
#root_url = %(protocol)s://%(domain)s:%(http_port)s/
root_url = http://localhost:80/grafana/
@sirakoff
sirakoff / elb-nodejs-ws.md
Created January 28, 2016 08:01 — forked from obolton/elb-nodejs-ws.md
Configuring an AWS Elastic Load Balancer for a Node.js application using WebSockets on EC2

AWS ELB with Node.js and WebSockets

This assumes that:

  • You are using Nginx.
  • You want to accept incoming connections on port 80.
  • Your Node.js app is listening on port 3000.
  • You want to be able to connect to your Node.js instance directly as well as via the load balancer.

####1. Create load balancer

@sirakoff
sirakoff / curlies.js
Created October 8, 2015 18:16 — forked from karbassi/curlies.js
Really small native javascript function to convert text with straight quotes to curly/smart quotes.
function curlies(element) {
function smarten(text) {
return text
/* opening singles */
.replace(/(^|[-\u2014\s(\["])'/g, "$1\u2018")
/* closing singles & apostrophes */
.replace(/'/g, "\u2019")
/* opening doubles */
@sirakoff
sirakoff / readme.md
Last active August 29, 2015 14:23 — forked from wilmoore/readme.md

UMD-Inspired JS Module Boilerplate

This is the module format you don't know you need until you need it. Write your module once and have it work in a CJS/NodeJs, AMD, YUI (v3+), or Browser Global environment.

Best Used When...

  • You are migrating from namespaced (err, globals) code to either AMD or CJS modules or both.
  • You can't yet factor out browser globals but also need to test your code via NodeJS (e.g. Mocha).

Benefits & Trade-offs