| item |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
Linux
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>It's a short and sweet guide to getting <a href="http://www.nginx.org/">nginx</a> up and running on Ubuntu using the CL but hopefully it will help someone else out.</p>
<p>Append the appropriate stanza to /etc/apt/sources.list.</p>
<b>
deb http://nginx.org/packages/ubuntu/ oneiric nginx<br/>
deb-src http://nginx.org/packages/ubuntu/ oneiric nginx
</b>
<p>Install NGINX</p>
<b>
sudo -s<br/>
apt-get update <br/>
apt-get install nginx <br/>
</b>
<p>Check it has worked</p>
<b>w3m 127.0.01</b>
<p>This should return something like " Welcome to nginx!". If you are lookg for the .CONF file its at <b>/etc/nginx/nginx.conf</b></p>
<p>For your next steps to see how NGINX processes a request read <a href="http://nginx.org/en/docs/http/request_processing.html" title="How nginx processes a request">nginx.org/en/docs/http/request_processing.html</a> then check out <a href="http://wiki.nginx.org/Main" title="Main">wiki.nginx.org/Main</a></p>
<p><a href="http://feedads.g.doubleclick.net/~a/qmRAXeXnIUxCmALjDTsBOHsTtco/0/da"><img src="http://feedads.g.doubleclick.net/~a/qmRAXeXnIUxCmALjDTsBOHsTtco/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/qmRAXeXnIUxCmALjDTsBOHsTtco/1/da"><img src="http://feedads.g.doubleclick.net/~a/qmRAXeXnIUxCmALjDTsBOHsTtco/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/8B2TADTWULI" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/4/27/Installing-NGINX-on-Ubuntu-oneiric
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/8B2TADTWULI/Installing-NGINX-on-Ubuntu-oneiric
|
| pubDate |
Thu, 26 Apr 2012 23:25:00 GMT
|
| title |
Installing NGINX on Ubuntu Oneiric
|
|
| 2 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
nodejs
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>I started seeing the following error when installing/updating packages after an update to <a href="http://nodejs.org/" title="node.js">Node.js</a></p>
<code>
npm ERR! Error: ENOENT, open '/usr/local/lib/node_modules/express/node_modules/connect/package.json'
npm ERR! You may report this log at:
npm ERR! <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR! <npm-@googlegroups.com>
</code>
<p>After some digging around I cleared the NPM cache via the following command and got back on track:</p>
<code>$ npm cache clean</code>
<p><a href="http://feedads.g.doubleclick.net/~a/NxEW4CWNf_IcqN7oNuS_46l5iPs/0/da"><img src="http://feedads.g.doubleclick.net/~a/NxEW4CWNf_IcqN7oNuS_46l5iPs/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/NxEW4CWNf_IcqN7oNuS_46l5iPs/1/da"><img src="http://feedads.g.doubleclick.net/~a/NxEW4CWNf_IcqN7oNuS_46l5iPs/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/YI5pbALSo4I" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/4/25/Error-ENOENT-open-with-NPM-install
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/YI5pbALSo4I/Error-ENOENT-open-with-NPM-install
|
| pubDate |
Wed, 25 Apr 2012 21:32:00 GMT
|
| title |
Error: ENOENT open with NPM install
|
|
| 3 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
Javascript
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>I hit some issues with getting <a href="http://lesscss.org/">LESS</a> to compile with <a href="http://expressjs.com/">Express.js</a> and it turns out I was looking at some old code.</p>
<p>To get it working now you need to use <a href="https://github.com/emberfeather/less.js-middleware">LESS-middleware</a>. The script below is the basic steps you need to get up and running.</p>
<script src="https://gist.github.com/2355649.js?file=gistfile1.txt"></script>
<p><a href="http://feedads.g.doubleclick.net/~a/cgopPfkDf6cnez6e6aChU9CZ8X4/0/da"><img src="http://feedads.g.doubleclick.net/~a/cgopPfkDf6cnez6e6aChU9CZ8X4/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/cgopPfkDf6cnez6e6aChU9CZ8X4/1/da"><img src="http://feedads.g.doubleclick.net/~a/cgopPfkDf6cnez6e6aChU9CZ8X4/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/88i_SxDwe48" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/4/11/Express-Less-and-lessmiddleware
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/88i_SxDwe48/Express-Less-and-lessmiddleware
|
| pubDate |
Wed, 11 Apr 2012 01:37:00 GMT
|
| title |
Express, Less and less-middleware
|
|
| 4 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
Blogging
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<blockquote>
You don't need us to tell you that your position on anti-"piracy" laws has been unpopular recently. Last month's historic protests, with millions of Americans registering their opposition, have made that point pretty clear. Instead, we're writing today to tell you that the Internet can be great for creators and their community, but your own leadership refuses to recognize and take advantage of its promise. It seems they'd rather spend your membership dues on lawyers, lobbyists and astroturf than innovation. We suspect many of you are realizing this, especially when you see how successful new business models can be.
We humbly suggest that you stand up and tell them to either embrace the age of the Internet or get out of the way so that new, forward-thinking industry leaders can take their place.
</blockquote>
<p>There are a lot of different fights regarding censorship on the net at the moment in the name of Piracy. So much of the issues come down to simple availability and price, the money being spent on the fight against piracy should go to making content easy to access at an attractive price, globally. We don't want to wait 6 months for that TV show, album, DVD to be released in our region. Innovate or die ... using the legal system to keep your business model never works, look at the <a href="http://en.wikipedia.org/wiki/Locomotive_Acts">Locomotive Acts</a> in the UK. If anything this practice should somehow be outlawed in itself.</p>
<a href="https://www.eff.org/deeplinks/2012/02/dear-hollywood-open-letter-hardworking-men-and-women-entertainment-industries">via www.eff.org/deeplinks/2012/02/dear-hollywood-open-letter-hardworking-men-and-women-entertainment-industries</a>
<p><a href="http://feedads.g.doubleclick.net/~a/vp-cX3N6tSwTDTqpl9ZuyWXiAmk/0/da"><img src="http://feedads.g.doubleclick.net/~a/vp-cX3N6tSwTDTqpl9ZuyWXiAmk/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/vp-cX3N6tSwTDTqpl9ZuyWXiAmk/1/da"><img src="http://feedads.g.doubleclick.net/~a/vp-cX3N6tSwTDTqpl9ZuyWXiAmk/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/_qJEoksiWWk" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/2/3/Entertainment-Industries-innovate-or-die
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/_qJEoksiWWk/Entertainment-Industries-innovate-or-die
|
| pubDate |
Fri, 03 Feb 2012 01:18:00 GMT
|
| title |
Entertainment Industries: innovate or die
|
|
| 5 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
CFML
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<blockquote>The project will remain in the Apache License. The copyright will be removed as most modern project no longer need or have a copyright. The Fusebox.org domain ownership will be transferred initially to John Blayter. The domain ownership shall only be owned by a commiter of at least 3 months. The rights of the domain ownership must be given up if 50% or more of the commiters vote to have it moved to another commiter.</blockquote>
<p>Looks like there is a <a href="http://fusebox.org/index.cfm/about/contributors/">new set of developers in town</a> for Fusebox with TeraTech letting it change hands in to the community. I still have one old project on FB (and its doing well) so I wish them all the best of luck going forward! It always good to see any project live on rather than go stale.</p>
<p><a href="http://fusebox.org/index.cfm/fusebox-downloads/fusebox-56/">fusebox.org/index.cfm/fusebox-downloads/fusebox-56/</a></p>
<p><a href="http://feedads.g.doubleclick.net/~a/rpAwZIJtTi5B_EAoNQXVeZTPVW0/0/da"><img src="http://feedads.g.doubleclick.net/~a/rpAwZIJtTi5B_EAoNQXVeZTPVW0/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/rpAwZIJtTi5B_EAoNQXVeZTPVW0/1/da"><img src="http://feedads.g.doubleclick.net/~a/rpAwZIJtTi5B_EAoNQXVeZTPVW0/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/-6krzQt2o_o" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/1/31/Fusebox-has-changed-hands-from-TeraTech
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/-6krzQt2o_o/Fusebox-has-changed-hands-from-TeraTech
|
| pubDate |
Tue, 31 Jan 2012 09:44:00 GMT
|
| title |
Fusebox has changed hands from TeraTech
|
|
| 6 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
Blogging
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p><img src="http://www.andyjarrett.co.uk/blog/images/Screen Shot 2012-01-27 at 07.45.06.png" /></p>
<p>This kind of rollback does nothing except help Asda with their stats i.e. "Rolling back 1000's of prices". I know, technically yes its a rollback, but really come'on. </p>
<p><a href="http://feedads.g.doubleclick.net/~a/q03YuWLFPRSiGaoPY6lpS7za5AE/0/da"><img src="http://feedads.g.doubleclick.net/~a/q03YuWLFPRSiGaoPY6lpS7za5AE/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/q03YuWLFPRSiGaoPY6lpS7za5AE/1/da"><img src="http://feedads.g.doubleclick.net/~a/q03YuWLFPRSiGaoPY6lpS7za5AE/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/gyhwvz3z34o" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/1/27/Is-this-really-an-asda-rollback
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/gyhwvz3z34o/Is-this-really-an-asda-rollback
|
| pubDate |
Fri, 27 Jan 2012 08:47:00 GMT
|
| title |
Is this really an @asda rollback?
|
|
| 7 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
Blogging
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<blockquote>ACTA is one more offensive against the sharing of culture on the Internet. ACTA (Anti-Counterfeiting Trade Agreement) is an agreement secretly negotiated by a small "club" of like-minded countries (39 countries, including the 27 of the European Union, the United States, Japan, etc). Negotiated instead of being democratically debated, ACTA bypasses parliaments and international organizations to dictate a repressive logic dictated by the entertainment industries.</blockquote>
<p>ACTA (Anti-Counterfeiting Trade Agreement) is the worlds <a href="https://twitter.com/#!/search?q=%23sopa">#SOPA</a>, though possibly worse in every way. If you live in the UK take 1 minute and make sure you get heard on this non-democratic process at <a href="http://epetitions.direct.gov.uk/petitions/20685">http://epetitions.direct.gov.uk/petitions/20685</a>.</p>
<p>Don't forget you can also tell your MP how you feel via <a href="http://www.theyworkforyou.com/">theyworkforyou.com</a></p>
<p>If you want to know more about ACTA then check out <a href="http://www.laquadrature.net/ACTA">http://www.laquadrature.net/ACTA</a></p>
<p>Just before I get off my soap box though what also bugs me is that this can be agreed on in principle by so many countries yet nothing can be done to the banking industry for years and after investigations?</p>
<p><a href="http://feedads.g.doubleclick.net/~a/06LKbKKPYcXMvEyFx9_Dxr33rwU/0/da"><img src="http://feedads.g.doubleclick.net/~a/06LKbKKPYcXMvEyFx9_Dxr33rwU/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/06LKbKKPYcXMvEyFx9_Dxr33rwU/1/da"><img src="http://feedads.g.doubleclick.net/~a/06LKbKKPYcXMvEyFx9_Dxr33rwU/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/z7sU1s059IQ" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/1/26/Say-NO-to-ACTA
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/z7sU1s059IQ/Say-NO-to-ACTA
|
| pubDate |
Thu, 26 Jan 2012 10:54:00 GMT
|
| title |
Say NO to #ACTA
|
|
| 8 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
CFML
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<span class="label notice">Update: O2 have fixed this already)</span>
<blockquote>
Whenever a mobile user accesses a website from their phone they share information about that device with the site.
It usually includes the web browser and the model of phone being used to allow the website to display its information in a way that suits your device.
However, O2's mobile network in the UK is also apparently including the phone number of some users in the data.
<br/><br/>
The mobile phone number can be seen in the HTTP header
<br/><br/>
Malicious websites could use the information to target users with spam texts or scams.
</blockquote>
<p>Wow, just saw this on <a href="http://news.sky.com/home/technology/article/16156276">Sky news</a>, seems like a silly mistake for someone to make. They probably had a reason for it but it seems silly!</p>
<p>I wanted to check if this was true and how easy it was with ColdFusion. Check if yours is visible at <a href="http://www.andyjarrett.co.uk/o2/">http://www.andyjarrett.co.uk/o2/</a>, the code is below:</p>
<p><script src="https://gist.github.com/1676224.js?file=o2checker.cfm"></script></p>
<p><a href="http://feedads.g.doubleclick.net/~a/8CA30Ok6tHdEMJV6qJCoTJF6adI/0/da"><img src="http://feedads.g.doubleclick.net/~a/8CA30Ok6tHdEMJV6qJCoTJF6adI/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/8CA30Ok6tHdEMJV6qJCoTJF6adI/1/da"><img src="http://feedads.g.doubleclick.net/~a/8CA30Ok6tHdEMJV6qJCoTJF6adI/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/r1N17yqQmrg" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/1/25/O2-shares-users-phone-numbers-with-every-site-they-visit
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/r1N17yqQmrg/O2-shares-users-phone-numbers-with-every-site-they-visit
|
| pubDate |
Wed, 25 Jan 2012 14:17:00 GMT
|
| title |
O2 shares users phone numbers with every site they visit
|
|
| 9 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
XHTML HTML CSS
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>I've created a <a href="git://gist.github.com/1599544.git">gist</a> which gives you the basics for getting to grips with WebSQL.
It's heavily commented and shows you the three core methods used (openDatabase,transaction,executeSql) and how to:
<ol>
<li>Create a database</li>
<li>Create a table</li>
<li>Insert a record</li>
<li>Get the data back in to HTML</li>
</ol>
</p>
<p>Don't forget that WebSQL is currently only supported on Chrome, Opera, iPhone, and Android. It's not on Firefox(!) or Internet Explorer (<i>shock</i>).</p>
<script src="https://gist.github.com/1599544.js?file=webssql.htm"></script>
<p>To see your results right click on the page and <b>Inspect Element</b> to bring up the following window and go to the <b>Resources tab</b>. Under <b>Databases</b> you should find a table called <b>fightclub</b></p>
<p><img src="http://www.andyjarrett.co.uk/blog/images/inspect_element.png" alt="inspect element" /></p>
<p><a href="http://feedads.g.doubleclick.net/~a/RCqq5eFS0uQQ5PpIX0Dkz-mFi98/0/da"><img src="http://feedads.g.doubleclick.net/~a/RCqq5eFS0uQQ5PpIX0Dkz-mFi98/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/RCqq5eFS0uQQ5PpIX0Dkz-mFi98/1/da"><img src="http://feedads.g.doubleclick.net/~a/RCqq5eFS0uQQ5PpIX0Dkz-mFi98/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/tKPkNr82ebw" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2012/1/12/A-quick-tutorial-for-WebSQL
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/tKPkNr82ebw/A-quick-tutorial-for-WebSQL
|
| pubDate |
Thu, 12 Jan 2012 10:35:00 GMT
|
| title |
A quick tutorial for WebSQL
|
|
| 10 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
ColdFusion
|
|
| 2 |
| Stomach Contents: Structure - struct |
| value |
CFML
|
|
| 3 |
| Stomach Contents: Structure - struct |
| value |
Blogging
|
|
| 4 |
| Stomach Contents: Structure - struct |
| value |
Railo
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<blockquote>
A few weeks ago I came to realize that I was holding back BlogCFC as a product. I was a barrier to it growing. I thought about Joe Rinehart (a man I greatly admire) and his decision to hand over the reigns of Model-Glue to Dan Wilson, and it occurred to me that maybe it was time to do the same.
</blockquote>
<p>I just read the <a href="http://news.blogcfc.com/index.cfm/2011/12/29/The-future-of-BlogCFC">news over at the BlogCFC blog</a> about Ray stepping to the side and can't help but feel this could give the project a needed kick it with new blood taking over the reins. </p>
<p>Thank you Ray for a great project, Scott when we seeing version 6 :p </p>
<p><a href="http://feedads.g.doubleclick.net/~a/jTKNSZfyqtcLd-arauapUEWztp8/0/da"><img src="http://feedads.g.doubleclick.net/~a/jTKNSZfyqtcLd-arauapUEWztp8/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/jTKNSZfyqtcLd-arauapUEWztp8/1/da"><img src="http://feedads.g.doubleclick.net/~a/jTKNSZfyqtcLd-arauapUEWztp8/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/DdVqBlr_wHI" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/30/BlogCFC-and-a-new-future-ahead
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/DdVqBlr_wHI/BlogCFC-and-a-new-future-ahead
|
| pubDate |
Fri, 30 Dec 2011 08:16:00 GMT
|
| title |
BlogCFC and a new future ahead
|
|
| 11 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
nodejs
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>Adding some DateFormat functions to Node ended up being quite simple</p>
<code>
$ mkdir testDateFormat && testDateFormat
$ npm install dateformat
$ subl app.js
</code>
<p>For this I installed it locally, you can always add <b>-g</b> to add it locally. The final line opens up a new file called <b>app.js</b> in Sublime Text 2 for me. In there we are going to create a simple web app (cause thats what you do with Node.js apparently) and quickly return the date to a Hello World program.</p>
<code>
var http = require('http');
// requre the dateFormat
var dateFormat = require('dateFormat')
// Create a function to return the current Date and Time
function getDateTime(){
var now = new Date();
return dateFormat(now, "dddd, mmmm dS, yyyy, h:MM:ss TT");
}
http.createServer(function (req, res) {
// Add some output to the browser including date and time
var textResponse = "Hello world @ " + getDateTime() + '\n\nCheck out more at https://github.com/felixge/node-dateformat';
// output to the browser
res.writeHead(200, {'Content-Type': 'text/plain'});
res.end( textResponse );
}).listen(1337, "127.0.0.1");
// Tell the console when the server was started
console.log('Server running on http://127.0.0.1:1337/ Started @ ' + getDateTime());
</code>
<p>Once you've saved <b>app.js</b> call <b>$ node app.js</b> from the Terminal and go to <a href="http://localhost:1337">http://localhost:1337</a>. </p>
<p>This only scratches the service of what it can do, check out more at <a href="https://github.com/felixge/node-dateformat">github.com/felixge/node-dateformat</a></p>
<p><a href="http://feedads.g.doubleclick.net/~a/QxWOFR1PgefbT5S8k2eBtEZ1RvE/0/da"><img src="http://feedads.g.doubleclick.net/~a/QxWOFR1PgefbT5S8k2eBtEZ1RvE/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/QxWOFR1PgefbT5S8k2eBtEZ1RvE/1/da"><img src="http://feedads.g.doubleclick.net/~a/QxWOFR1PgefbT5S8k2eBtEZ1RvE/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/U2UtMFYMfWI" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/21/DateFormat-in-nodejs
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/U2UtMFYMfWI/DateFormat-in-nodejs
|
| pubDate |
Wed, 21 Dec 2011 10:41:00 GMT
|
| title |
DateFormat in #nodejs
|
|
| 12 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
nodejs
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p>When moving over to a templating system like <a href="http://jade-lang.com/">Jade</a> it is the silly things you get stuck on. This is probably more for my reference than anyone else but its a simple <b>layout.jade</b> to use with <a href="http://twitter.github.com/bootstrap/">Twitters Bootstrap</a>.</p>
<code>
!!!
html
head
title= title
link(rel='stylesheet', href='http://twitter.github.com/bootstrap/1.4.0/bootstrap.min.css')
body
div.topbar
div.fill
div.container
a(href='#').brand #{title}
ul.nav
li.active
a(href='#') Home
li
a(href='http://www.andyjarrett.co.uk/blog') Blog
li
a(href='#') Contact
div.container!= body
footer
p © Company 2011
</code>
<p>Each of your views will then be within the container, you just need to add the div.row in each view file. Below is the current index file at <a href="http://andyjarrett.nodester.com/">andyjarrett.nodester.com</a> <span class="help-block">(subject to change of course)</span></p>
<code>
div.hero-unit
h1 Hello Node and Nodester
p More content coming soon
div.content
div.page-header
div.row
div.span6
h2 Currently using
p Jade and Express
div.span5
h2 Starting with Node.js
p <a href="http://www.andyjarrett.co.uk/blog/index.cfm/2011/4/20/Developing-with-NodeJs-starting-links">Links to start you off</a>
div.span5
h2 The message board
p.label.notice Coming soon
</code>
<p>If you are looking for more documentation then check this out from the Scala communitya href="http://scalate.fusesource.org/documentation/jade-syntax.html">scalate.fusesource.org/documentation/jade-syntax.html</a>
<p><a href="http://feedads.g.doubleclick.net/~a/10Ro-pfn50ziCzVVTZnKSgNEA3k/0/da"><img src="http://feedads.g.doubleclick.net/~a/10Ro-pfn50ziCzVVTZnKSgNEA3k/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/10Ro-pfn50ziCzVVTZnKSgNEA3k/1/da"><img src="http://feedads.g.doubleclick.net/~a/10Ro-pfn50ziCzVVTZnKSgNEA3k/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/ZdkQBRo-pzg" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/21/layoutjade-for-Twitters-Bootstrap
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/ZdkQBRo-pzg/layoutjade-for-Twitters-Bootstrap
|
| pubDate |
Tue, 20 Dec 2011 23:44:00 GMT
|
| title |
layout.jade for Twitters Bootstrap
|
|
| 13 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
nodejs
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p><a href="http://nodester.com/" title="Nodester -> Open Source Node.JS PaaS">Nodester</a> Allows you to Deploy your Node.JS applications to Nodester.com for FREE
and is a good way to quickly get playing around with <a href="http://nodejs.org/" title="node.js">Node.js</a>. The site has some quick guides for
getting your app created and deployed within 40 seconds, this post is about getting from
Hello World to having a Express+Jade site deployed. Before we continue some assumptions have been made: you know Git,
you've installed Node,
installed <a href="http://expressjs.com/" title="http://expressjs.com/">expressjs</a>,
signed up at <a href="http://nodester.com/" title="Nodester -> Open Source Node.JS PaaS">nodester.com</a>,
and now just want to get your web goodness deployed to show the world.</p>
<div class="alert-message block-message warning">The below commands are all run from a Mac terminal but should fire for any *nix.</div>
<ol>
<li>
$ nodester app create [app name]
<ul>
<li>For this example my app will be called <b>scribble</b> and can be seen at
<a href="http://scribble.nodester.com">scribble.nodester.com</a>. When you run this call
you will get a port number back i.e. 12332 Note this down!</li>
</ul>
</li>
<li>
$ nodester app init <b>scribble</b>
<ul>
<li>At this point your app is running at http://[app name].nodester.com and you should see "Hello World".
Basically you Node.js web app is running. Simples. Now we are going to add
<a href="http://expressjs.com/" title="Express - node web framework">Express.js</a> which is a node web framework.</li>
</ul>
</li>
<li>$ cd [app name]</li>
<li>$ express
<ul>
<li>You'll get a message <b>destination is not empty, continue?</b>, type <b>Yes</b> and hit return at which point the
folder structure will be setup.</li>
</ul>
</li>
<li>$ npm install <span class="help-block">dont forget to install dependencies</span></li>
<li>When Express sets up it uses <b>app.js</b> and Nodester uses <b>server.js</b> easiest way to fix this is to run <b>$ mv app.js server.js</b></li>
<li>$ vi server.js <span class="help-block">open server.js and change the port number at the bottom (<b>app.listen( xxxxx );</b>) to the one you noted earlier i.e. 12332</span></li>
<li>$ node server.js
<ul>
<li>We're running this to check everything is ok. Open your browser at <a herf="#">localhost:[port number]</a> and
you should get the "Welcome to Express" message. Once you're happy go back to the terminal and ctrl-c</li>
</ul>
</li>
<li>$ git add .</li>
<li>$ git commit -m"My first express.js commit"</li>
<li>$ git push</li>
<li>Thats it, the Push should of restarted your app, go to your Nodester URL and you should be up and running.</li>
</ol>
<p><a href="http://feedads.g.doubleclick.net/~a/65TYO3i7u8q7Ua5a7xH6QvVhvzA/0/da"><img src="http://feedads.g.doubleclick.net/~a/65TYO3i7u8q7Ua5a7xH6QvVhvzA/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/65TYO3i7u8q7Ua5a7xH6QvVhvzA/1/da"><img src="http://feedads.g.doubleclick.net/~a/65TYO3i7u8q7Ua5a7xH6QvVhvzA/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/d60waRJd2Cw" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/19/Getting-your-Node-JS--Express-app-deployed-on-Nodester
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/d60waRJd2Cw/Getting-your-Node-JS--Express-app-deployed-on-Nodester
|
| pubDate |
Mon, 19 Dec 2011 18:10:00 GMT
|
| title |
Getting your Node JS + Express app deployed on Nodester
|
|
| 14 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
jQuery
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p><blockquote><a href="http://phono.com/">Phono</a> is a simple jQuery plugin and JavaScript library that turns any web browser into a phone; capable of making phone calls and sending instant messages. You can even connect to SIP clients; all with a simple unified API.</blockquote></p>
<p>There are some amazing APIs popping up out there and this is an example of one that I could imagine being really handing for instant call support. The only problem which is stopping me from jumping in now is US domestic calls only at the moment. If you try it out let me know.</p>
<p><a href="http://feedads.g.doubleclick.net/~a/0p6BFri5RfMp0i38tuYMoIlm4LQ/0/da"><img src="http://feedads.g.doubleclick.net/~a/0p6BFri5RfMp0i38tuYMoIlm4LQ/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/0p6BFri5RfMp0i38tuYMoIlm4LQ/1/da"><img src="http://feedads.g.doubleclick.net/~a/0p6BFri5RfMp0i38tuYMoIlm4LQ/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/kWiiV67LYfw" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/9/Turn-your-web-browser-into-a-phone-capable-of-making-phone-calls
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/kWiiV67LYfw/Turn-your-web-browser-into-a-phone-capable-of-making-phone-calls
|
| pubDate |
Thu, 08 Dec 2011 23:50:00 GMT
|
| title |
Turn your web browser into a phone capable of making phone calls
|
|
| 15 |
| Stomach Contents: Structure - struct |
| category |
| Stomach Contents: Structure - array
|
| 1 |
| Stomach Contents: Structure - struct |
| value |
nodejs
|
|
|
| description |
| Stomach Contents: Structure - struct |
| value |
<p><a href="http://browserling.com/">Browserling</a> is an interactive cross-browser testing tool inside of your browser built with <a href="http://nodejs.org">Node.js</a>. There are a few of these popping up now and if you do any testing its most likely worth the investment if you don't want the VMs running locally or want to show a client away from the office!</p>
<img src="http://www.andyjarrett.co.uk/blog/images/browserling.png" alt="Browserling, cross browser testing from your browser" style="height:347px;width:500px;" />
<p><a href="http://feedads.g.doubleclick.net/~a/DduZFrtkF1Q-oD7ZyKaU3FjN3WM/0/da"><img src="http://feedads.g.doubleclick.net/~a/DduZFrtkF1Q-oD7ZyKaU3FjN3WM/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/DduZFrtkF1Q-oD7ZyKaU3FjN3WM/1/da"><img src="http://feedads.g.doubleclick.net/~a/DduZFrtkF1Q-oD7ZyKaU3FjN3WM/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/AndyJarrett/~4/NpEl6dJsD9Y" height="1" width="1"/>
|
|
| guid |
| Stomach Contents: Structure - struct |
| isPermaLink |
NO
|
| value |
http://www.andyjarrett.co.uk/blog/index.cfm/2011/12/8/Free-crossbrowser-testing-from-your-browsers
|
|
| link |
http://feedproxy.google.com/~r/AndyJarrett/~3/NpEl6dJsD9Y/Free-crossbrowser-testing-from-your-browsers
|
| pubDate |
Thu, 08 Dec 2011 10:36:00 GMT
|
| title |
Free cross-browser testing from your browsers
|
|
|