For a friend, on a Saturday afternoon: Michael Steinberg, who writes and publishes books as Black Rain Press.

- Install Drupal. This specific site is in 5; normally I would do 6, but it was in a folder with other friends' sites that I didn't want to upgrade at the time.
- Enable the following modules:
- Install the Zen theme, and create a quick subtheme with their instructions (or for Drupal 6) (you can grab zpress.css if you need to see how that's customized)
- Create the following content types & fields:
- Book (not to be confused with the Book module in core; if you also need that content type, then call this type something else so they don't conflict), with a Book Cover (an ImageField with default settings)
- Excerpt, with a Node Reference to Book (default settings, but select the type as the above 'Book' content type)
- Create an ImageCache preset named 'book_front' with Scale And Crop: width: 150, height: 231.
- Create a view like this:
- Basic info: Name: books
- Page: check 'provide page'; URL is 'books'; View Type is 'List View'; Title is 'Books'; check 'Use pager'; leave at 10 nodes
- Fields: Image: Cover, with an option to 'book_front as link to node'; Node: Title
- Filters: Node Type is one of 'book'; Node: Published Equals Yes
- Sort by Node Title Ascending
- Create another view:
- Basic info: Name: excerpts
- Block: check 'provide block'; View Type: 'List View', Title: 'Book Excerpts'; Uncheck 'More' Link
- Fields: Node: Title; Node: Body as Teaser; Node: View Link with option of 'Read more...'
- Arguments: Node Reference: Book (field_book) with Option of 'Book Excerpts from %1'; Argument Handling Code: "
if (arg(1) && is_numeric(arg(1))) { return array(arg(1)); }"
- Filters: Node Type is one of excerpt; Node Published equals Yes
- Sort by Node: Created Type (Descending)
- Configure some blocks:
- Content Top: a custom 'Ordering Info' block, with some static HTML with the basic ordering info that you see on the site. Shows up on book* and cart*.
- Left Sidebar: Navigation menu; Recent blog posts; Recent comments; User login
- Right Sidebar: Excerpts (we created a view for that, remember?)
- Site Info: The regular (Name, e-mail, etc). Most of this is set up during installation, but we also want to set the front page to 'books', so our fancy new View goes on the home page.
- Ubercart configuration for E-Commerce:
- Store administration > Products > Manage classes: Add a class of ID: book, Name: Book, which seems to turn on product info for our Book content type. I really don't know Ubercart, but that's literally all I had to do besides
- Store administration > Configuration > Payment settings -- set up a Payment method for PayPal, where you enter the required PayPal information.
- Set up the contact page
- Make sure the Navigation menu has what you want
- Make sure you have all the Print, AddToAny, and any other settings you want configured
- Set up the PathAuto settings to turn your ugly node/123 URLs into pretty book/[title-raw] or what-have-you.
- (Optional): Migrate your content, if this is coming from WordPress or somewhere. In this case, it was actually just the books and about a dozen e-mail posts that were turned into blog entries; just a 20 minute cut & paste.
Hope that's useful to some folks! Let me know any questions or comments you have.
Thanks,
Aaron
PS: I did all the graphics for that, and even created the logo for him some years ago, when I fancied myself an artist...
Comments
API
I am building my new website using Drupal 6.6 and Godaddy shared hosting and i just realized that the Image API require PHP 5.2 +while godaddy shared hosting provide only PHP 5, is there any way to bypass this requirement from within drupal or godaddy ?
Yes, I agree with the last
Yes, I agree with the last person, you can give a better title.
Hey Aaron, glad you were able
Hey Aaron, glad you were able to use Ubercart with little headache. : )
You might mention to your friend to check his product prices, as they weren't all at $12 (i.e. at least one was at $0.00 when I looked ; ).
Ubercart was uber-easy!
Ubercart was uber-easy! (Though I could use a hint in how to 'turn off an individual product page' -- that $0.00 is because the book is no longer in print, and I didn't take too much time to figure that out.) Although Advomatic does work with it (and we always work with Ubercart for an e-commerce solution), it's always been other developers than myself on the team who have installed and configured it.
I figured I needed to bite the bullet and learn how to use Ubercart. The disappointing thing, actually, is that it was too easy -- I was relishing the chance to jump in there and learn how to wrestle with what, after experiences with the e-commerce module some years ago, I thought would be a beast.
Instead, I turned on the recommended modules, skimmed through the simple configuration screens, and next thing I knew, the whole thing just worked.
I decided to go play with my daughter at the park later that afternoon instead...
Title Misleading, Sorry
Hmmm... Just reread the title, and see it's not really that clear. Should have been something like "Creating a Book Publisher's Ecommerce Site with Drupal in 5 hours." But I'm sure you get the point. :)
Post new comment