This file contains 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
<ul> | |
<li><a href="#">★</a></li> | |
<li><a href="#">★</a></li> | |
<li><a href="#">★</a></li> | |
<li><a href="#">★</a></li> | |
<li><a href="#">★</a></li> | |
</ul> |
This file contains 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
var Module1 = function() { | |
this.message = 'Hello World from Module1'; | |
this.init(); | |
}; | |
Module1.prototype.init = function() { | |
console.log(this.message); | |
}; |
This file contains 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
#dev.site.com | |
<VirtualHost *:80> | |
ServerAdmin fatihacet.com | |
DocumentRoot "/Users/fatih/Sites/dev.site.com/source/public" | |
ServerName dev.site.com | |
ServerAlias dev.site.com | |
SetEnv APPLICATION_ENV "development" | |
<Directory "/Users/fatih/Sites/dev.site.com/source/public"> | |
Options Indexes FollowSymLinks | |
AllowOverride All |
This file contains 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
$.ajax({ | |
type: 'GET', | |
dataType: 'xml', | |
url: '/feed', | |
success: function(xmlDocument) { | |
var rss = $(xmlDocument.firstChild); | |
console.log(rss.find('item')); | |
} | |
}); |
This file contains 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
var u = 'www.loremipsum.com'; | |
var p = /^(http:\/\/)?([^\/]+)/i | |
u.match(p)[2] | |
// http://www.loremipsum.com -> www.loremipsum.com | |
// www.loremipsum.com -> www.loremipsum.com | |
// www.loremipsum.com/dolor/sit/amet -> www.loremipsum.com |
This file contains 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
// Divide by 10 and round it, then multiply by 10. | |
var x = 136; | |
console.log(Math.round(x / 10) * 10); | |
This file contains 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
var events = data.events; | |
var date = {}; | |
for (var i = 0, ii = events.length; i < ii; i++) { | |
if (!date[events[i]['date']]) { | |
date[events[i]['date']] = []; | |
}; | |
date[events[i]['date']].push(events[i]); | |
} | |
console.log(date); |
This file contains 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
var pubsub = {}; | |
(function(q) { | |
var topics = {}, subUid = -1; | |
q.subscribe = function(topic, func) { | |
if (!topics[topic]) { | |
topics[topic] = []; | |
} | |
var token = (++subUid).toString(); | |
topics[topic].push({ | |
token: token, |
This file contains 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
$.ajaxQueue = []; | |
var que = $.ajaxQueue; | |
$.ajaxSetup({ | |
beforeSend: function(){ | |
if (this.queue) { | |
que.push(this); | |
} | |
else { | |
return true; |
This file contains 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
.panelNode-script { background-color: #EFEFE7; color: black; cursor: default; font-family: Monaco,Monospace,Courier New !important; font-size: 12px; } | |
.sourceRow.hovered { background-color: #EEEEEE; } | |
.sourceLine { background: none no-repeat scroll 2px 0 #EEEEEE; border-bottom: 1px solid #EEEEEE; border-right: 1px solid #CCCCCC; color: #888888; } | |
.sourceLine:hover { text-decoration: none; } | |
.scriptTooltip { background: none repeat scroll 0 0 LightYellow; border: 1px solid #CBE087; color: #000000; } | |
.sourceRow[exeline="true"] { background-color: lightgoldenrodyellow; outline: 1px solid #D9D9B6; } | |
.js-comment { color: gray; font-size: 11px; } | |
.whitespace { color: blue; } | |
.js-variable { color: #7C3A99; } | |
.js-punctuation { color: black; } |