Monday 5 May 2014

Adding the Disqus comment system to a Rails 3 application

 step 1  
 gem install disqus  
 step2  
 add in application.rb(user should registered to consume service)  
 config.after_initialize do  
   Disqus::defaults[:account] = "youraccountname"  
   Disqus::defaults[:developer] = true  
   Disqus::defaults[:container_id] = "disqus_thread"  
   Disqus::defaults[:show_powered_by] = false  
   end  
  step3  
  add this to view file(example: show.html.erb)  
 <div id ="disqus_thread">  
 <% = raw disqus_thread %>  
 </div>  
 start the server and check.....   

3 comments:

  1. This comment has been removed by a blog administrator.

    ReplyDelete
  2. Thanks for sharing such a useful information with us. Cryptex Technologies is the best company for Ruby on Rails Development in India. If you are looking for such companies email us at: info@cryptextechnologies.com

    ReplyDelete