Ruby on Rails Friday, March 6, 2015

On Thu, Mar 5, 2015 at 10:34 PM, Colin Law <clanlaw@gmail.com> wrote:
> You have not told us which is line 9 but presumably it is one of the
> above. Have a look in the log file to see what params is for the
> request and check that it has the contents referenced above
> (page_title and page_content and each of those has :value).

Yes, it worked I looked into log file and I found I forgot to add "id"
element in some tags + passing wrong "id" elements in others. Somehow
I'm able to make to it run but I encountered with another error. Error
is like this

I followed Railscast mercury tutorial to set up future stuff like link
for edit, saving edited content etc.

http://railscasts.com/episodes/296-mercury-editor?view=asciicast

I'm able to edit but not able to save. I google alot but not able to
find solution. Can please tell me where I'm doing wrong

mercury.js

$(window).bind('mercury:ready', function() {
var link = $('#mercury_iframe').contents().find('#edit_link');
Mercury.saveUrl = link.data('save-url');
link.hide();
});

$(window).on('mercury:saved', function() {
window.location.href = window.location.href.replace(/\/editor\//i,
'/');
});

Error.

ActionController::RoutingError (No route matches [PUT]
"/quotations/3/mercury_update"):
/home/deepak/.rvm/gems/ruby-2.2.0@global/gems/actionpack-4.2.0/lib/action_dispatch/middleware/debug_exceptions.rb:21:in
`call'
web-console (2.1.0) lib/web_console/middleware.rb:37:in `call'



--
Cheers!

Deepak Kumar Sharma
Blog: http://deekysharma.wordpress.com

" Mistakes are proof that you are trying "

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CALDHwN6ZkSgjS50-7u9BJkhWVatVcNkH%2BtsD8o8ZLKWQEPWS5Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment