Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

norman-disqus-api

Package Overview
Dependencies
Maintainers
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

norman-disqus-api

  • 0.2.0
  • Rubygems
  • Socket score

Version published
Maintainers
2
Created
Source

== Disqus Ruby Gem

The Disqus Gem helps you easily integrate the {Disqus}[http://disqus.com] commenting system into your website. It works for any site programmed in Ruby, and has view helpers for Rails and Merb.

Support for the Disqus Javascript widgets is stable. Disqus API support is "beta."

=== What is Disqus?

From the Disqus website:

"Disqus, pronounced "discuss", is a service and tool for web comments and discussions. The Disqus comment system can be plugged into any website, blog, or application. Disqus makes commenting easier and more interactive, while connecting websites and commenters across a thriving discussion community."

"Disqus is a free service to the general public with absolutely no inline advertisements."

=== Get it

==== Stable release (does not yet include API):

gem install disqus

==== Bleeding Edge (includes API):

gem install norman-disqus --source http://gems.github.com

=== Use it:

==== Configure it:

===== Generic example:

Disqus::defaults[:account] = "my_disqus_account"

Optional, only if you're using the API

Disqus::defaults[:api_key] = "my_disqus_api_key"

===== Rails-specific example:

in config/development.rb (or production.rb, test.rb, etc.)

config.after_initialize do Disqus::defaults[:account] = "my_disqus_account" # Optional, only if you're using the API Disqus::defaults[:api_key] = "my_disqus_api_key" end

Note that here the "after initialize" is necessary, otherwise your settings won't be set properly.

==== Show the comment threads widget on a post page:

Loads the commenting system

disqus_thread

Or if you're not using Rails/Merb:

Disqus::Widget::thread

have the anchor "disqus_thread". For example, "View Comments" below would

be replaced by "1 comment" or "23 comments" etc.

View Comments

View Comments

disqus_comment_counts

Or if you're not using Rails/Merb:

Disqus::Widget::comment_counts

==== Show the combo widget on a post page:

disqus_combo(:color => "blue", :hide_mods => false, :num_items => 20)

Or for non-Rails/Merb:

Disqus::Widget::combo(:color => "blue", :hide_mods => false, :num_items => 20)

==== Show the comment count on a permalink:

link_to("Permalink", post_path(@post, :anchor => "disqus_thread")) ... disqus_comment_counts

Or for non-Rails/Merb:

Disqus::Widget::comment_counts

==== Work with the Disqus API:

See the Disqus::Api class for more info on the Disqus API. You can also read the {Disqus developer info here}[http://disqus.com/docs/api/].

=== Hack it:

Github repository:

http://github.com/norman/disqus

=== Submit bug reports:

Please use our {Lighthouse}[http://randomba.lighthouseapp.com/projects/16065-disqus/].

=== Learn more about Disqus:

{http://disqus.com}[http://disqus.com]

=== Thanks to the following contributors:

=== Legal Stuff

The Disqus Ruby gem was not created by, nor is officially supported by Disqus.com or Big Head Labs, Inc. Use it at your own risk and your own responsibility under the terms of the MIT License.

Copyright (c) 2008 {Norman Clarke}[mailto:norman@randomba.org], released under the MIT license

FAQs

Package last updated on 10 Aug 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc