---------- Forwarded message ----------
From: Atsushi Shibata <[EMAIL PROTECTED]>
Date: Mar 25, 2006 4:14 PM
Subject: COREBlog2 portlet(was Re: quills portlet)
To: [EMAIL PROTECTED]
Cc: michael nt milne <[EMAIL PROTECTED] >

Hi :-).

On Sat, 25 Mar 2006 14:46:51 +0000, wrote:
> I've tried copying across portlet_recent_entry.pt and
> portlet_recent_comment.pt into the Plone portlets folder and adding
>
> here/portlet_recent_entry/macros/portlet
> here/portlet_recent_comment/macros/portlet
>
>  to the slots but nothing is showing as yet. Will investigate further

These portlets works only under COREBlog2 folder. Outside the COREBlog2 folder,
portlets fail to find COREBlog2 specific method and portlet won't be displayed.

Please try following portlet.
You'll be happy to change portal_type to 'COREBlogComment' :-).

<div metal:define-macro="portlet"
     tal:define="results python:here.portal_catalog.searchResults(portal_type='COREBlogEntry',
                                                                  sort_on='Date',
                                                                  sort_order='reverse')[:5];"
     tal:condition="results">
    <dl class="portlet" id="portlet-global-recententry">
        <dt i18n:translate="box_recententry"
             class="portletHeader">
        Recent entries
        </dt>
        <tal:block tal:repeat="obj results">
        <dd tal:define="oddrow repeat/obj/odd"
            tal:attributes="class python:test(oddrow, 'portletItem even', 'portletItem odd')">
            <a href="">               tal:attributes="href obj/getURL;
                               title obj/Description">
                <span tal:replace="obj/pretty_title_or_id">
                Entry title
                </span>
            </a>
        <span class="portletItemDetails">
                <span class="portletItemDetails"
                      tal:content="python: here.toLocalizedTime(obj.Date)">May 5</span>
        </span>
        </dd>
        </tal:block>
    </dl>
</div>

Have fun :-).

----------------------------------------
Atsushi Shibata (Webcore Corp.)
[EMAIL PROTECTED]
http://www.webcore.co.jp/
----------------------------------------


--
michael
_______________________________________________
COREblog-en mailing list
[email protected]
http://postaria.com/cgi-bin/mailman/listinfo/coreblog-en
Unsubscription writing to [EMAIL PROTECTED]

Reply via email to