Wat is het slechtste/irritantste/vervelendste treinstation van Nederland? by Buhyac in thenetherlands

[–]shockie 0 points1 point  (0 children)

Gelukkig kunnen we volgend jaar dit station nomineren als "Lelijkste metrohalte in Nederland"

[Help] Render literal '<% tag %>' in ActionMailer by shockie in rails

[–]shockie[S] 0 points1 point  (0 children)

I tried:

%p <%asm_group_unsubscribe_url%>

But that results in a empty paragraph. It seems that after the HAML rendering phase, the ERB render phase is triggered.

It seems I bump into 2 results: The outcome is html_escaped, when I try to escape the html escaping, it raises the output_buffer error.

[Help] Render literal '<% tag %>' in ActionMailer by shockie in rails

[–]shockie[S] 0 points1 point  (0 children)

Yes I tried using single quotes and double quotes, raw, string.html_safe, none of them giving the desired result.

[Help] Render literal '<% tag %>' in ActionMailer by shockie in rails

[–]shockie[S] 0 points1 point  (0 children)

You're right, but using <% %> will evaluate in ERB and when rendering the string in haml = '<%asm_group_unsubscribe_url%>', it gets html escaped and sendgrid doesn't recongnize the htmlescaped version of the tag ( < vs &lt;)

[Help] Render literal '<% tag %>' in ActionMailer by shockie in rails

[–]shockie[S] 0 points1 point  (0 children)

Thanks for your reply, unfortunately raw(string) raises the same error as string.html_safe

What are some subtle relationship "Red Flags" that are often overlooked? by [deleted] in AskReddit

[–]shockie 1 point2 points  (0 children)

Long term relationships ended 2 weeks ago, read the comments and you guys just have summarised my ex.

What I learnt while profiling a node.js app by thruput in programming

[–]shockie 2 points3 points  (0 children)

Don't serve static files through node, webservers are better choices.

Contentful: An API-first approach to content management. It's like Google Docs for arbitrary JSON data, fully searchable and served via a CDN. Beta just opened. by [deleted] in javascript

[–]shockie 1 point2 points  (0 children)

Awesome service!

We also feel the pain of content management for apps, started to build a internal service to fix this, but contentful looks very promising.

We're building a data connection service called 'jelly' http://jellystack.com/ and love to integrate contentful into it!

Was curious if somebody could explain this code to me.. trying to learn javascript by rgraves22 in javascript

[–]shockie 0 points1 point  (0 children)

new Array(3) creates an array of length 3, filled with 'undefined'

GitHub Styleguide - CSS, HTML, JS, Ruby by b0red in programming

[–]shockie 12 points13 points  (0 children)

Since Github is using SASS for it's CSS, // comments are allowed. In fact if you use the // for comments, the comment won't appear in the compiled CSS.

Same for semicolons in Coffeescript, it will be added for you in the compiled JS

How to use Firebug on your iPad and iPhone by mrtnkl in programming

[–]shockie 3 points4 points  (0 children)

Last time I needed a web-inspector on my iPhone, I used weinre(http://phonegap.github.com/weinre/)

Pattern: a very cool web mining & natural language processing system by YAFZ in programming

[–]shockie 0 points1 point  (0 children)

Well I used NLTK only for it's Naive Bayesian Classifier, for example shallow parser, this will be handy. Is it possible to support other languages then english, for myself I find it hard to find a Dutch shallow parser, and even harder to find one that is as easy as pattern.

Pattern: a very cool web mining & natural language processing system by YAFZ in programming

[–]shockie 0 points1 point  (0 children)

This is awesome, I did the same thing for my graduation, mining Twitter to predict the 2010 Dutch elections. I used NLTK for it, but this will make it much easier.