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
<!-- before --> | |
<script src="https://gist.github.com/6159716.js?file=edit_post.html"></script> | |
<!-- after --> | |
<script src="https://gist.github.com/6159716.js?file=edit_post.html"> </script> |
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
rvm use 1.9.3 do bundle install --path ../../shared/gems |
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
gem 'nokogiri' |
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
function dialogAlert(str, title) { | |
if('undefined' == typeof(title)) var title = ''; | |
$('<div>').dialog({ | |
modal: true, | |
title: title, | |
open: function (){ | |
$(this).html(str); | |
$('.ui-dialog-buttonpane') | |
.find('button:contains("Ok")') // вот так я достаю кнопку |
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
/** | |
* Excerpt | |
* | |
* Creates intro excerpts from long passages of text like a Ninja. | |
* | |
* @category snippet | |
* @version 1.0 | |
* @license http://www.gnu.org/copyleft/gpl.html GNU Public License (GPL) | |
* @autohor Kevin Marvin, Ryan Thrash | |
* @internal @modx_category Content |
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
define(["dojo/_base/declare", "dijit/Calendar", "dojo/cldr/supplemental", "dojo/string", "dojo/dom"], | |
function(declare, Calendar, cldrSupplemental, string, dom){ | |
return declare([Calendar], { | |
buildRendering: function(){ | |
// Markup for days of the week (referenced from template) | |
var d = this.dowTemplateString, | |
dayNames = this.dateLocaleModule.getNames('days', this.dayWidth, 'standAlone', this.lang), | |
dayOffset = cldrSupplemental.getFirstDayOfWeek(this.lang); | |
this.dayCellsHtml = string.substitute([d,d,d,d,d,d,d].join(""), {d: ""}, function(){ |
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"> | |
<style type="text/css"> | |
@import "/custom/dojo/resources/dojo.css"; | |
@import "/custom/dijit/themes/tundra/tundra.css"; | |
@import "/custom/dijit/themes/dijit.css"; | |
@import "/custom/dojox/widget/Calendar/Calendar.css"; |
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
rails g scaffold Book title:string description:text | |
rails g scaffold Pubhouse title:string address:text | |
rails g model BookPubhouse book_id:integer pubhouse_id:integer | |
rake db:migrate |