Women in Technology

Hear us Roar



Article:
  Rolling with Ruby on Rails, Part 2
Subject:   "Showing recipes in a category" code
Date:   2005-03-04 16:56:48
From:   petercooper
Response to: "Showing recipes in a category" code

Not sure why there's a ? in there, as I copy and pasted from something I said on IRC :-) But anyway it should be something like:


@recipes = Category.find(@params['category']?).recipes


Main Topics Oldest First

Showing messages 1 through 2 of 2.

  • "Showing recipes in a category" code
    2005-03-20 14:27:35  garrowsmith [View]

    Can this technique be adapted... say I wanted to list all recipies but sort them alphabetically by category. Is there a neat way to do this?
  • "Showing recipes in a category" code
    2005-03-04 16:57:28  petercooper [View]

    Okay, I guess this system puts in random question marks for some reason. Sorry folks :)