Hi Cj
I don't think anyone answered your question, so here's a quick reply.
Since you said "I'm not sure I understand what models do" I presume
you're a beginner, so this states what may already be obvious! I'm
still a noob at heart too.
You don't really need a models module to do what your little app does
- there's not enough data to warrant it. Here's the Camping intro to
models:
http://camping.io/Book/-Getting-Started#Modeling-the-world
Basically, you'd use models when constructing an app that needs a
database - take a look at the models module in the Camping blog
example (https://github.com/camping/camping/blob/master/examples/
blog.rb)
By default, models use ActiveRecord (with a Ruby-friendly syntax) to
create and manage the database (SQLite is the Camping default).
DaveE
Hello,
I'm new to ruby and camping. I'm learning ralis along with camping.
I like camping because the MVC is all on one page.
So, I'm wondering if you can help.
Here's my code.
I'm writing a little app that displays a random quote when you
refresh the page.
On line 30 and 31 I have an array and show the index page and sample
the array.
So, guide me on how to put this in the model module. But I'm not
sure I understand what models do. Told you I'm a noob!
Thanks in advance for your help.
Cj.
_______________________________________________
Camping-list mailing list
Camping-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/camping-list
_______________________________________________
Camping-list mailing list
Camping-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/camping-list