This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title> User define form element Example </title> | |
<link rel="stylesheet" href="https://code.jquery.com/qunit/qunit-1.23.1.css"> | |
<style> | |
#div1 { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Getting started aws ses | |
http://codechannels.com/video/amazonwebservices/cloud/getting-started-with-amazon-ses/ | |
1. Verify email address | |
In the sandbox you can send email only from emails yiu have verified. | |
Go to email AWS SES then on the left clcik on 'verified senders' | |
to start the verification process: | |
a. click 'verify a ne sender' | |
in the dialogue box add your email and click submit. you will receive |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Deploying a simple Rails application with AWS Elastic Beanstalk by Julien SIMON, Principal Technical Evangelist @ Amazon Web Services | |
18/02/2016 | |
http://www.slideshare.net/JulienSIMON5/deploying-a-simple-rails-application-with-aws-elastic-beanstalk | |
1. . Create a Git repository with AWS CodeCommit | |
$ aws codecommit create-repository --repository-name blog --region us-east-1 --repository-description "ElasticBeanstalk demo" | |
$ git clone ssh://git-codecommit.us- east-1.amazonaws.com/v1/repos/blog | |
2. Create a new Rails application |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#http://www.stat.wisc.edu/~st571-1/gtest.R | |
#see page 2 for data & page 17 for g-test http://www.stat.wisc.edu/~st571-1/06-tables-2.pdf | |
# Bret Larget | |
# October 28, 2010 | |
# September 30, 2011 | |
# Use source() to read this file into R to use it. | |
# Example: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#https://rforge.net/doc/packages/Deducer/likelihood.test.html | |
#http://www.pmc.ucsc.edu/~mclapham/Rtips/G%20test.txt | |
# Log-likelihood tests of independence & goodness of fit | |
# Does Williams' and Yates' correction | |
# does Monte Carlo simulation of p-values, via gtestsim.c | |
# | |
# G & q calculation from Sokal & Rohlf (1995) Biometry 3rd ed. | |
# TOI Yates' correction taken from Mike Camann's 2x2 G-test fn. | |
# GOF Yates' correction as described in Zar (2000) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//https://github.com/maccman/abba/blob/master/app/assets/javascripts/client/index.coffee | |
var extend, getCookie, host, request, setCookie, | |
slice = [].slice; | |
host = function(url) { | |
var parent, parser; | |
parent = document.createElement('div'); | |
parent.innerHTML = "<a href=\"" + url + "\">x</a>"; | |
parser = parent.firstChild; | |
return "" + parser.host; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ember new cms | |
ember generate model page navbar:string title:string body:string | |
import DS from 'ember-data'; | |
export default DS.Model.extend({ | |
navbar: DS.attr('string'), | |
title: DS.attr('string'), | |
body: DS.attr('string'), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :api do | |
#when devise_for is called in a namespace, the helpers and controller filters change | |
#:singular => :user added so we can use current_user instead of current_api_user. | |
#And before_filter authenticate_user! instead of authenticate_api_user! | |
#https://github.com/plataformatec/devise/issues/412 | |
#devise_for :users, :singular => :user, skip: :all | |
get :csrf, to: 'csrf#index' | |
resources :users |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Route.extend({ | |
//a = Charity.__container__.lookup('controller:application') | |
//a.get('csrfService') | |
//a.get('csrfService').token.authenticity_token | |
//or | |
//a.csrfService | |
//a.csrfService.token.authenticity_token |