Skip to content

Instantly share code, notes, and snippets.

<% nmonth = "" %>
<li>
<ul class="weeks">
<li>Week</li>
<% navigation_weeks.each do |w| %>
<li class="<%= (controller_name == "posts" || controller_name == "things") && params[:action]=="index" && params[:week].present? && params[:year].present? && params[:week]==w.week.to_s && params[:year]==w.year.to_s ? 'active' : '' %>">
<%= link_to posts_path(:week => w.week, :year => w.year), :class => 'tip', :title => week_dates(w.week, w.year) do %>
<%= w.week %>
<% if nmonth != week_month(w.week, w.year) %>
<span class="<%= week_month(w.week, w.year).downcase %>"><%= week_month(w.week, w.year) %></span>
@riklomas
riklomas / loz-tipsy-1
Created February 7, 2012 14:41 — forked from lawrencebrown/loz-tipsy-1
tipsy start
<script type="text/javascript">
(function ($) {
$(function () {
$('ul.dd li').tipsy({gravity: $.fn.tipsy.autoNS});
});
})(jQuery);
</script>
@riklomas
riklomas / rikify.html
Created February 13, 2012 15:28 — forked from jgwhite/rikify.html
Rikify
<!doctype html>
<html>
<head>
<title>Rikify</title>
<style type="text/css">
#button {
font-family: Lucida Grande;
font-size: 11px;
text-decoration: none;
font-weight: bold;
@riklomas
riklomas / directions.sh
Created September 28, 2018 21:08 — forked from hhff/directions.sh
SSL Proxy for Multi Tenant Sites on AWS
ssh -i your_key.pem ec2-user@YOUR_EC2_IP
sudo yum-config-manager --add-repo https://openresty.org/package/amazon/openresty.repo
sudo yum install openresty
sudo yum install openresty-resty
# if https://openresty.org/package/amazon/2/x86_64/repodata/repomd.xml: \[Errno 14\] HTTPS Error 404 - Not Found
# sudo vim /etc/yum.repos.d/openresty.repo
# exchange the $releasever placeholder of the baseurl to “latest” baseurl=https://openresty.org/package/amazon/latest/$basearch.
import Controller from '@ember/controller';
import { reads } from '@ember/object/computed';
export default Controller.extend({
children: reads('model'),
actions: {
clickChild(child) {
child.parent.then(parent => {
console.log(parent.name);
});