New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments for Rails Ecommerce with Spree: Customizing with Hooks Tutorial #252
Comments
Thanks for the tutorial. On the first step you wrote you put the hooks in the stephs_photos_hooks.rb. How did you created the file??? Thanks M. |
Hi, The extension_name_hooks.rb file is created when you create the extension with the 'script/generate extension ExtensionName' command. This file is only created in Spree Version 0.9.5. If you are running Spree from a gem, I'm not sure if the 0.9.5 gem is available yet. ~Steph |
hi there, i just noticed that the folowing lines didn't work for me: RAILS_ROOT/vendor/extensions/stephs_photos/stephs_photos_extension.rbdef activate thx |
Thanks xonic. It looks like the '/images/' location is added when the logo is included in the template with an image_tag. |
Just wanted to say I spent about 3 hours trying to figure out how to make a sidebar, and I'm sure I hacked it in. Basically I created shared/_taxonomies.erb and put in my html there. Most of my time was spent thinking that I could call my sidebar 'sidebar.erb' and then in the hook do replace :sidebar, 'shared/sidebar' but nope. |
Todd, the way to override / replace views before hooks were introduced was by placing files of the same name in the extension that would automatically override the core views. This should have worked as expected. You should also be able to replace / override the sidebar via hooks. Perhaps you should explain the details to the spree-user google group and you'll get more advice? |
This tutorial doesn't quite apply to the extension system used in Spree 0.30.0. However, I'd really like to work through it. If there is any way you could update it, or add a few notes for adapting to spree 0.30.0, I would really appreciate it. Thanks. |
Well I see that you already took care of explaining Spree 0.30 extensions here One quick note about something I had to fix to handle missing .gitignore Thanks |
Thanks for the nice tutorial! Is there a way to add CSS style to a custom logo? Thx! |
This is a great tutorial. |
Is there any way you can upload your code to GITHUB? |
Hi David, and Anonymous: There have been several updates on Spree since I wrote this article a year and a half ago. I haven't had time to update this to work on the latest version of Spree, which has pretty significant changes in the way it approaches theming. For now, I'd recommend looking through the Spree docs for Spree theming advice. |
Comments for https://www.endpointdev.com/blog/2010/01/rails-ecommerce-spree-hooks-tutorial/
By Steph Skardal
To enter a comment:
The text was updated successfully, but these errors were encountered: