2017 © Pedro Peláez
 

typo3-flow-package neos-disqus

Add Disqus discussions to your site

image

helmich/neos-disqus

Add Disqus discussions to your site

  • Thursday, April 16, 2015
  • by helmich
  • Repository
  • 1 Watchers
  • 1 Stars
  • 18 Installations
  • HTML
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Disqus integration for TYPO3 Neos

This is a TYPO3 Neos plugin that integrates Disqus discussions into your site (in case you're -- like me -- too lazy to implement your own commenting system in Neos)., (*1)

Setup

Requirements

Tested with TYPO3 Neos 1.2. Should work with other releases too, though., (*2)

Installation

Composer. Easy., (*3)

composer require helmich/disqus

Integration as individual content element

You can insert a Disqus discussion as an individual content element. It is listed under "Plugins" when inserting a new content element., (*4)

The "comment" content element is not inline-editable. There are two options you can change using the inspector, though:, (*5)

  • Site name. This is your short site name under which your site is registered at Disqus. When including more discussion elements, it might be a good idea to leave this empty and set this value via TypoScript (see below for that)., (*6)

  • Thread identifier. The identifier that is used for the comment thread. When left empty, the node identifier of the nearest document node will be used as a discussion identifier (which is a quite sensible default that should work in most cases)., (*7)

When integrating more than a few discussions, it will become tedious to configure your site name for each one individually. You can override the site name using TypoScript:, (*8)

page {
    prototype(Helmich.Disqus:Discussion) {
        shortname = 'your-site-name'
    }
}

Integrate Disqus on all pages

You can use this plugin to integrate Disqus discussions on all (or a subset) of all pages using TypoScript:, (*9)

page = TYPO3.Neos:Page {
    // Other definitions...

    body {
        parts {
            discussion = Helmich.Disqus:Discussion {
                // Override template if necessary:
                // templatePath = '...'

                // Override site name if necessary:
                // shortname = 'your-site-name'
            }
        }
    }
}

Inside your page fluid template, then simply render the content element:, (*10)

{parts.discussion -> f:format.raw()}

Integrate comment count

You can also integrate a comment count in overview pages. Simply insert an object of type Helmich.Disqus:Count anywhere in your page, and add an data-disqus-identifier attribute to your links., (*11)

page = TYPO3.Neos:Page {
    // Other definitions

    footer {
        disqusCount = Helmich.Disqus:Count {
            shortname = 'your-site-name'
        }
    }
}

In template:, (*12)

<a href="{neos:uri.node(node: myPage, section='disqus_thread'}" data-disqus-identifier="{myPage.identifier}">
    0 Comments
</a>

The Versions

16/04 2015

dev-master

9999999-dev

Add Disqus discussions to your site

  Sources   Download

MIT

The Requires

 

16/04 2015

v1.1.0

1.1.0.0

Add Disqus discussions to your site

  Sources   Download

MIT

The Requires

 

16/04 2015

v1.0.0

1.0.0.0

Add Disqus discussions to your site

  Sources   Download

MIT

The Requires