API CHANGE Changed BlogEntry->Tags() to TagsCollection() to avoid confusion with the property "Tags" which is of DBField type "Text" (not DataObjectSet) - necessary to adjust to changed DataObject-write() behaviour of using DBField instances to write the value (rather than directly editing the SQL manipulation). See r52927 for details.

This commit is contained in:
Ingo Schommer 2008-07-20 07:45:55 +00:00
parent 0f0e473c7f
commit 359446212a
4 changed files with 6 additions and 6 deletions

View File

@ -83,7 +83,7 @@ class BlogEntry extends Page {
/**
* Returns the tags added to this blog entry
*/
function Tags() {
function TagsCollection() {
$theseTags = split(" *, *", trim($this->Tags));
$output = new DataObjectSet();

View File

@ -1,10 +1,10 @@
<div class="blogSummary">
<h2><a href="$Link" title="<% _t('VIEWFULL', 'View full post titled -') %> '$Title'">$MenuTitle</a></h2>
<p class="authorDate"><% _t('POSTEDBY') %> $Author.XML <% _t('POSTEDON', 'on') %> $Date.Long | <a href="$Link#PageComments_holder" title="View Comments Posted">$Comments.Count <% _t('COMMENTS', 'Comments') %></a></p>
<% if Tags %>
<% if TagsCollection %>
<p class="tags">
Tags:
<% control Tags %>
<% control TagsCollection %>
<a href="$Link" title="View all posts tagged '$Tag'" rel="tag">$Tag</a><% if Last %><% else %>,<% end_if %>
<% end_control %>
</p>

View File

@ -5,10 +5,10 @@
<div class="blogEntry">
<h2>$Title</h2>
<p class="authorDate"><% _t('POSTEDBY', 'Posted by') %> $Author.XML <% _t('POSTEDON', 'on') %> $Date.Long | $Comments.Count <% _t('COMMENTS', 'Comments') %></p>
<% if Tags %>
<% if TagsCollection %>
<p class="tags">
<% _t('TAGS', 'Tags:') %>
<% control Tags %>
<% control TagsCollection %>
<a href="$Link" title="<% _t('VIEWALLPOSTTAGGED', 'View all posts tagged') %> '$Tag'" rel="tag">$Tag</a><% if Last %><% else %>,<% end_if %>
<% end_control %>
</p>

View File

@ -1,5 +1,5 @@
<p class="tagcloud">
<% control Tags %>
<% control TagsCollection %>
<a href="$Link" class="$Class">$Tag</a>
<% end_control %>
</p>