Changeset 555 in products
- Timestamp:
- Sep 29, 2006 3:53:51 PM (20 years ago)
- Location:
- SimpleBlog/branches/plone-2.1-Blogging-APIs
- Files:
-
- 5 added
- 3 edited
-
config.py (modified) (2 diffs, 1 prop)
-
skins/SimpleBlog/SimpleBlog_macros.pt (modified) (10 diffs)
-
skins/SimpleBlog/delicious.gif (added)
-
skins/SimpleBlog/digg.gif (added)
-
skins/SimpleBlog/google.gif (added)
-
skins/SimpleBlog/spurl.gif (added)
-
skins/SimpleBlog/yahoo.gif (added)
-
util.py (modified) (1 prop)
Legend:
- Unmodified
- Added
- Removed
-
SimpleBlog/branches/plone-2.1-Blogging-APIs/config.py
- Property svn:eol-style deleted
r28 r555 1 from Permissions import * 1 2 from Products.Archetypes.public import DisplayList 2 3 … … 5 6 6 7 GLOBALS = globals() 7 ENABLE_ADSENSE = 18 8 9 # deprecated, just here for compatability10 9 DISPLAY_MODE = DisplayList(( 11 ('full', 'Full'), ('descriptionOnly', 'Description only'), ('titleOnly', 'Title only') )) 12 13 14 # set to 0 if you don't want entries to be folderish 15 # use at your own risk. this is not fully tested 16 ENTRY_IS_FOLDERISH = 1 17 10 ('full', 'Full', 'display_full'), 11 ('descriptionOnly', 'Description only', 'display_description_only'), 12 ('titleOnly', 'Title only', 'display_title_only') )) 18 13 19 14 DIGG_TOPICS = DisplayList(( \ -
SimpleBlog/branches/plone-2.1-Blogging-APIs/skins/SimpleBlog/SimpleBlog_macros.pt
r211 r555 4 4 <body> 5 5 6 <div metal:define-macro="blogGlobals" 7 tal:define="global fp python:here.simpleblog_tool.getFrontPage(here); 8 global isDeliciousEnaled fp/isDeliciousEnabled; 9 global isDiggEnabled fp/isDiggEnabled; 10 global isYahooEnabled fp/isYahooEnabled; 11 global isGoogleEnabled fp/isGoogleEnabled; 12 global isSpurlEnabled fp/isSpurlEnabled; 13 global isTagsEnabled fp/isTagsEnabled; 14 global isAllowTrackback fp/getAllowTrackback" 15 tal:omit-tag=""> 16 </div> 17 6 18 <div metal:define-macro="full" tal:define="showReadMore python:0" class="simpleBlogEntry"> 19 <div metal:use-macro="obj/SimpleBlog_macros/macros/blogGlobals"/> 7 20 <div tal:define="size headerSize | python:1;title obj/title_or_id; 8 showIcons obj/simpleblog_tool/getShowIcons"21 showIcons fp/simpleblog_tool/getShowIcons" 9 22 class="simpleBlogTitle"> 10 23 <tal:x replace='structure string:<h${size} class="noMargin">'/> … … 25 38 26 39 <div metal:define-macro="descriptionOnly" tal:define="showReadMore python:1" class="simpleBlogEntry"> 40 <div metal:use-macro="obj/SimpleBlog_macros/macros/blogGlobals"/> 27 41 <div tal:define="size headerSize | python:1;title obj/title_or_id; 28 showIcons obj/simpleblog_tool/getShowIcons"42 showIcons fp/simpleblog_tool/getShowIcons" 29 43 class="simpleBlogTitle"> 30 44 <tal:x replace='structure string:<h${size} class="noMargin">'/> … … 44 58 45 59 <div metal:define-macro="titleOnly" tal:define="showReadMore python:1" class="simpleBlogTitle"> 60 <div metal:use-macro="obj/SimpleBlog_macros/macros/blogGlobals"/> 46 61 <tal:block tal:define="size headerSize | python:1;title obj/title_or_id; 47 showIcons obj/simpleblog_tool/getShowIcons">62 showIcons fp/simpleblog_tool/getShowIcons"> 48 63 <tal:x replace='structure string:<h${size} class="noMargin">'/> 49 64 <a href="" tal:attributes="href obj/absolute_url" style="cursor:pointer;"> … … 58 73 </div> 59 74 60 <div metal:define-macro="ByLine" class="BlogByLine"> 75 <div metal:define-macro="ByLine" class="BlogByLine" 76 tal:define="fp nocall:fp | python:here.simpleblog_tool.getFrontPage(here);"> 61 77 <span i18n:translate="blog_by_line"> 62 78 Submitted by … … 71 87 <strong><a href="#" 72 88 tal:define="quotedCat python:pss.url_quote(cat)" 73 tal:attributes="href string:${ here/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}"89 tal:attributes="href string:${fp/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}" 74 90 title="category"><span tal:omit-tag="" tal:content="cat"/></a></strong> 75 91 </tal:categories> … … 79 95 80 96 <div metal:define-macro="technoratiTags" 81 tal:define="cats python:obj.EntryTag();" 82 tal:condition="python:here.isTagsEnabled() and cats" 97 tal:define="cats python:obj.EntryTag(); 98 isTagsEnabled isTagsEnabled | here/isTagsEnabled" 99 tal:condition="python:isTagsEnabled and cats" 83 100 tal:omit-tag=""> 84 101 _____<br/> … … 97 114 <tal:x define="allowed python:obj.portal_discussion.isDiscussionAllowedFor(obj); 98 115 ccount python:allowed and obj.portal_discussion.getDiscussionFor(obj).replyCount(obj); 99 tballowed python:here.getAllowTrackback(); 100 tbcount python:len(obj.getTrackbacks())"> 116 tballowed isAllowTrackback | here/getAllowTrackback; 117 tbcount python:len(obj.getTrackbacks()); 118 fp nocall:fp | python:here.simpleblog_tool.getFrontPage(here)"> 101 119 <span i18n:translate="blog_by_line"> 102 120 <span tal:define="edate python:obj.simpleblog_tool.getEntryDate(obj)" … … 111 129 <strong><a href="#" 112 130 tal:define="quotedCat python:pss.url_quote(cat)" 113 tal:attributes="href string:${ here/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}"131 tal:attributes="href string:${fp/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}" 114 132 title="category"><span tal:omit-tag="" tal:content="cat"/></a></strong> 115 133 </tal:categories> … … 128 146 <div tal:condition="tballowed"> trackback URL: 129 147 <tal:x replace="string:${obj/absolute_url}/sbtrackback"/> 148 </div> 149 <div tal:define="entryURL obj/absolute_url; 150 entryTitle obj/Title; 151 entryDescription obj/Description; 152 entryDiggTopic obj/getDiggTopic; 153 encodeURLData python:modules['Products.SimpleBlog.util'].encodeURLData;" 154 tal:omit-tag=""> 155 <span tal:condition="isDeliciousEnaled | obj/isDeliciousEnabled"> 156 <a href="" 157 title="" 158 tal:define="url_data python:encodeURLData({'url':entryURL,'title':entryTitle});" 159 tal:attributes="href string:http://del.icio.us/post?${url_data}; 160 title string:del.icio.us: ${entryTitle}"> 161 <img src="" 162 alt="del.icio.us" 163 tal:attributes="src string:$portal_url/delicious.gif;" /></a> 164 </span> <span tal:condition="isDiggEnabled | obj/isDiggEnabled"> 165 <a href="" 166 title="" 167 tal:define="url_data python:encodeURLData({'phase':'2','url':entryURL,'title':entryTitle,'bodytext':entryDescription,'topic':entryDiggTopic});" 168 tal:attributes="href string:http://digg.com/submit?${url_data}; 169 title string:Digg: ${entryTitle}"> 170 <img src="" 171 alt="Digg" 172 tal:attributes="src string:$portal_url/digg.gif;" /></a> 173 </span> <span tal:condition="isYahooEnabled | obj/isYahooEnabled"> 174 <a href="" 175 title="" 176 tal:define="url_data python:encodeURLData({'u':entryURL,'t':entryTitle});" 177 tal:attributes="href string:http://myweb2.search.yahoo.com/myresults/bookmarklet?${url_data}; 178 title string:Yahoo: ${entryTitle}"> 179 <img src="" 180 alt="Yahoo" 181 tal:attributes="src string:$portal_url/yahoo.gif;" /></a> 182 </span> <span tal:condition="isGoogleEnabled | obj/isGoogleEnabled"> 183 <a href="" 184 title="" 185 tal:define="url_data python:encodeURLData({'op':'edit','output':'popup','bkmk':entryURL,'title':entryTitle});" 186 tal:attributes="href string:http://www.google.com/bookmarks/mark?${url_data}; 187 title string:Google: ${entryTitle}"> 188 <img src="" 189 alt="Google" 190 tal:attributes="src string:$portal_url/google.gif;" /></a> 191 </span> <span tal:condition="isSpurlEnabled | obj/isSpurlEnabled"> 192 <a href="" 193 title="" 194 tal:define="url_data python:encodeURLData({'url':entryURL,'title':entryTitle});" 195 tal:attributes="href string:http://www.spurl.net/spurl.php?${url_data}; 196 title string:Spurl: ${entryTitle}"> 197 <img src="" 198 alt="Spurl" 199 tal:attributes="src string:$portal_url/spurl.gif;" /></a> 200 </span> 130 201 </div> 131 202 … … 205 276 <tal:cats tal:repeat="cat python:here.simpleblog_tool.getSortedKeys(cats)"> 206 277 <dd tal:define="pss modules/Products.PythonScripts.standard; 278 fp nocall:fp | python:here.simpleblog_tool.getFrontPage(here); 207 279 quotedCat python:pss.url_quote(cat); 208 280 category python:'%s (%s)' %(cat,cats[cat])" 281 tal:condition="python:cats[cat]>0" 209 282 tal:attributes="class python:test(toggle, 'portletItem even', 'portletItem odd')"> 210 <a tal:condition="python:cats[cat]>0" href="#" 211 tal:attributes="href string:${here/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}; 212 title cat"><span tal:content="category"/></a> 213 <span tal:condition="python:cats[cat]==0" tal:content="category"/> 283 <a href="#" 284 tal:attributes="href string:${fp/absolute_url}/SimpleBlogCatSearch?category=${quotedCat}; 285 title cat"><span tal:content="category"/></a> 214 286 <tal:toggle tal:define="global toggle python:test(toggle==1,0,1)"/> 215 287 </dd> -
SimpleBlog/branches/plone-2.1-Blogging-APIs/util.py
- Property svn:eol-style deleted
Note: See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/trac/chrome/common/qtrac_logo.png)