What is an RSS Feed?its RSS FeedAll Feeds

Home . Ministries . ITS . CMSOverview . CMSPageComments

Login


EducationMinisterialFinancial ServicesCamp MiVoden

Comments

imageReview /Development/Brewster-Omak#comment (as of 11.8.2007) to see an example of combining a webform, dbquery, and dbreport together to solicit comments that display on your page.

Please review your comments regularly as they are prone to abuse and XSS attacks.

Comments are not available from RSS, nor do they change the edit timestamp of a page, so an /edit rss feed will not demonstrate if comments have recently been submitted to a page.

image

  1. Build a form (in this example, _dev1comment) that solicits a _Name, _Comment, and _Email fields with appropriate validation rules and default values from the user's profile.
  2. Edit the page you want to solicit comments and display them and add a dbreport placeholder showing the comments received in the right order; SQL query would be: SELECT '<div class="calloutbox">' + CONVERT(CHAR(19), CreatedTime, 100) + ' ' + _name + ' wrote <br/>&nbsp;&nbsp; ' + _comment + '<div>' AS Test FROM _dev1comment Order By Entry_ID asc
  3. Place a dbquery placeholder where you'd like a 'count' of the comments to be displayed; SQL query would be: SELECT COUNT(*) FROM _dev1comment
  4. Insert the form placeholder where you wish to solicit comments and bind it to the _dev1comment form.

Cut-and-paste the below into your pages XML if you wish to review the above example:

<hr />
<h3><a href="/" id="comment"></a><placeholder_dbquery query="SELECT COUNT(*) FROM _dev1comment" /> Comments</h3>
<p><placeholder_dbreport combinecol1col2link="false" query="SELECT '&lt;div class=&quot;calloutbox&quot;&gt;' + CONVERT(CHAR(19), CreatedTime, 100) + ' ' + _name + ' wrote &lt;br/&gt;&amp;nbsp;&amp;nbsp; ' + _comment + '&lt;div&gt;' AS Test FROM _dev1comment Order By Entry_ID asc" showcoltitles="false" tableborder="false" tablesummary="summary" /></p>
<p> </p>
<p><placeholder_form formname="_dev1comment" title="Form" /></p>