mattmccray

 
« Rails 0.11.1 | Home | Flight of the Moot »

AJAX and Rails demo application: taskTHIS!

» Published March 28, 2005 under Rails, Software, TaskTHIS

Update: Some URL’s changed, so I updated the links…

I thought that since I was involved with the new AJAX stuff in the latest Rails (0.11.1 as of this writing), that I would create a quick demo application showing how to actually use the stuff.

So I present to you taskthis!

Before you roll your eyes and say: “Ugh! Another todo list example?!”, this one is different! Honestly. Sort of. It’s using the new Rails (0.11.1) asynchronous AJAX tools. It’s using them a lot. Plus, you can download the source and play around with it.

It’s been tested on Safari and Mozilla blends (Firefox/Camino), but not too extensively on Windows/IE. So I’d appreciate a shout out if you find any issues there.

Links


25 comments

03.28.05 @ 23:30 n8 said...
very nice! i’m only just learning, but thanks for releasing the code. the demo rocks the casbah!
03.29.05 @ 00:13 Matt said...
Any docs for this?
03.29.05 @ 01:55 Jay said...
As a newbie, I was just reading about the Ajax in 0.11.1 and thinking to myself, “Man, I wish I had a starting point for examining this material.” And then I see you have released this. Thanks a ton! I look forward to learning from your code.
03.29.05 @ 03:09 Glenn said...
Just to echo the other comments, thanks so much for releasing this code. I find that studying actual apps is a great way to learn “the rails way” rather than piecing it together through the documentation.
03.29.05 @ 03:15 MarkC said...
Thanks for releasing this. I could repeat what the other people here just said. This is just what I’m looking for – a working example of the ajax stuff, ...
03.29.05 @ 05:34 nikola said...
nice… but :)

  • style buttons

  • change that #F0F0F0 background (text fields) in light light blue

  • find some nice icons

  • sharing?

  • rss?

03.29.05 @ 10:23 Wolfgang said...
Hi

Thanks for releasing it, but there’s some strange behaviour if you let the site alone for a while (logged in) and come back after some hours. If you then click on the “Completed” checkbox you get a login form that shifts down to the position where the completed item should sit ;-) looks cool, but I think that’s not intended, is it?
03.29.05 @ 20:17 Robby Russell said...
Nice, runs a little slow (development server?) Like the usage of ajax and its a clean and simple interface. Good work!
03.30.05 @ 01:05 misuba said...
Is there a license on this code?
03.30.05 @ 02:33 M@ said...
Thanks for the feedback! It’s great to hear when your work is appreciated!

Matt: There aren’t any docs, really. Are you interested in API docs, or installation docs, or something else? I do plan to write an article about taskthis! that focuses on it’s use of AJAX in the next few days.

Nikola: Sharing, RSS Feeds, Public Lists, and more are all on my ‘nice to have’ feature list. I’m debating how the public stuff should work… Can the ‘public’ add new tasks for you, and complete them?... Stuff like that. The RSS support will kinda depend on that decision. If anyone has any thoughts on that or further feature requests I’d be happy to hear them.

Wolfgang: Really? Heh… I wondered what would happen when the session timed-out. Thanks for pointing it out, I’ll have look at that.

Misuba: Thanks for asking, I forgot to include the license. Sorry about that. It’s a form of GPL, you can find it here.
03.30.05 @ 14:36 ironjazz said...
downloaded the code, and i’ve mysql ruby rails etc.

how do i start the taskthis app?
04.03.05 @ 17:45 M@ said...
Basically, like any other Rails app.

1) Make sure you have created the database using one of the db/schema-[dbtype].sql scripts.
2) Update the config/database.yml to point to your database instance.
3) run ruby script/server from the root project directory.
04.04.05 @ 01:17 ironjazz said...
Hi,

Thanks for the tip.. Got it working and the code is great for a ruby/rails newbie to fiddle with.

Cheers
04.04.05 @ 11:05 Raymond said...
Brilliant!
04.05.05 @ 04:49 Brad said...
I’m fairly new to this, but I’m liking your application.

Am I missing something? How do you get this to work with Apache? If at all?
04.05.05 @ 04:51 Brad said...
Actually, sorry.

That’s not my issue anymore. I’m getting the following error when trying to add a new task list:

NameError in Tasks#new

uninitialized constant RedCloth

/app/models/tasklist.rb:20:in `create_html’
app/controllers/tasks_controller.rb:35:in `new’
script/server:48
04.05.05 @ 09:41 M@ said...
Oh, yeah… You’ll need to install RedCloth. It should be as simple as running:

gem install RedCloth

or, if on a Mac:

sudo gem install RedCloth
04.05.05 @ 20:08 glucosamine said...
I got this up and running with postgres, but trying to use rake and the Rakefile is not working. a quick glance at the Rakefile looks like you are grabbing the wrong postgres username during the dump. it is dumping all the postgres system tables. in anycase if I don’t rake it seems to work ok.
04.05.05 @ 21:17 M@ said...
That’s good to know. It probably should be brought up to the ActiveRecord guys — I don’t use postgres. Whatever’s in the rakefile is what Rails spits out by default.
04.20.05 @ 08:06 Erik Kallevig said...
Cool stuff, much better than TaDa except for one feature – the ability to reorder list items. Kudos.
05.14.05 @ 11:44 Rod Schmidt said...
I’ve installed this on OS X Tiger. I created the databases using sqlite3. I’ve started the server using script/server. When I enter localhost:3000 in my browser I get ‘/’ not found. Anything else I need to configure?
05.25.05 @ 11:49 M@ said...
Rod: Nothing that comes to mind. However, I do recall having problems with sqlite3 — I wound up having to use sqlite 2.8.16.
04.06.06 @ 01:25 Christer said...
Seems the demo and source for this is unavailable…
04.06.06 @ 13:06 M@ said...
Christer: Sorry about that, some URL’s changed… I’ve updated the post to reflect the changes.
04.22.10 @ 08:24 ForemanLILIAN28 said...
I think that to receive the loans from banks you ought to present a firm motivation. Nevertheless, once I’ve got a term loan, just because I wanted to buy a building.

No trackbacks

Trackback link:

Please enable javascript to generate a trackback url


You may use Textile, or simple html tags (B,I). Feel free to use Emoticons too. Oh, and please limit yourself to only five links per comment. Anything more and you'll probably get detained by the spam police.