List Info

Thread: Monthly Archives on OS 10.4.8




Monthly Archives on OS 10.4.8
user name
2006-11-01 13:38:22

I think we are getting somewhere, but it’s not working yet. J The monthly archives are now displayed, but when I click on any of the links (let’;s use October as an example) the URL is http://servername.montclair.edu/weblog/blog-id/#BlogURL()2006/10/ and it doesn̵7;t go anywhere as this #Blog() part is not what it should look like I assume? Any suggestions, as it seems as if it is a simple change which I am not seeing.

 

Thanks,

 

Milos

-
--

 

"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former." - Albert Einstein.


From: blojsom-users-bounceslists.sourceforge.net [mailto:blojsom-users-bounceslists.sourceforge.net] On Behalf Of David Czarnecki
Sent: Tuesday, October 31, 2006 3:58 PM
To: blojsom-users
Subject: Re: [Blojsom-users] Monthly Archives on OS 10.4.8

 

Right, that’;s just defining the macro. But, if that works when placed at the top of one of your templates, you should be able to use, for example:

    #MonthlyArchive(1 2006)

 at some place later in the page to have it print the archive list.


On 10/31/06 3:53 PM, "Milos Topic"; <topicmmail.montclair.edu&gt; wrote:

Now, the code
&nbsp;
#macro(MonthlyArchive $startingMonth $startingYear)
<ul>
&nbsp; &nbsp; #set ($currentMonth = $BLOJSOM_CALENDAR.getCurrentMonth() + 1)
   ; #set ($totalMonths = 12)
 ; &nbsp; #set ($currentYear = $BLOJSOM_CALENDAR.getCurrentYear())
&nbsp; &nbsp; #set ($padding = 0)
   ; #foreach ($year in [$currentYear..$startingYear])
  ; &nbsp; &nbsp; &nbsp;#set ($monthIndex = 1)
   ; &nbsp; &nbsp; #if ($year == $startingYear)
 ; &nbsp; &nbsp; &nbsp; &nbsp;   ;#set($monthIndex = $startingMonth)
&nbsp; &nbsp; &nbsp; &nbsp; #end
 ; &nbsp; &nbsp; &nbsp; #if ($year == $currentYear)
   ; &nbsp; &nbsp; &nbsp; &nbsp; #set($totalMonths = $currentMonth)
 ; &nbsp; &nbsp; &nbsp; #else
 ; &nbsp; &nbsp; &nbsp; &nbsp;   ;#set ($totalMonths = 12)
 ; &nbsp; &nbsp; &nbsp; #end
   ; &nbsp; &nbsp; #foreach ($month in [$totalMonths..$monthIndex])
 &nbsp; &nbsp; &nbsp; &nbsp;   ; #set ($calMonth = $month - 1)
   ; <li><a href=";#BlogURL()$year/#if($month < 10)$padding#end$month/">$BLOJSOM_CALENDAR.getMonthName($calMonth) $year</a&gt;</li&gt;
 &nbsp;   ; &nbsp; #end
 &nbsp; &nbsp;#end
</ul>
#end
&nbsp;
Doesn&#8217;t do anything, it doesn̵7;t interfere with the blog, but it doesn&#8217;t display anything new at all. Very strange.


Thanks,

Milos
--
-
http://newton.montclair.edu/weblog/topicm/
-
--


"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.&quot; - Albert Einstein.


From: blojsom-users-bounceslists.sourceforge.net [lists.sourceforge.net%5d">mailto:blojsom-users-bounceslists.sourceforge.net] On Behalf Of David Czarnecki
Sent: Tuesday, October 31, 2006 11:24 AM
To: blojsom-users
Subject: Re: [Blojsom-users] Monthly Archives on OS 10.4.8

The only thing I can think is that one of the calendar methods below isn’t present on the calendar object for the version of blojsom that’;s included. Though, that doesn̵7;t seem likely. You could try adding the lines in one-by-one (or as a group in the case of the if statements) to see if it̵7;s an error in the syntax, though I tried that on a local install and it the macro was OK.


On 10/30/06 10:04 PM, "Milos Topic"; <topicmmail.montclair.edu&gt; wrote:
It didn’;t work, it actually displayed #MonthlyArchive(1 2006)” as a plain text on the page where I have added it. Nothing in the log file (literally, when I go to /Library/Tomcat/logs – there’s nothing there). On the other hand, when I go to /Library/Tomcat/blojsom_root/logs the last log file is localhost_log.2006-10-23.txt with no errors in it.
 ;

Thanks,

Milos
-
--


"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former." - Albert Einstein.



From: blojsom-users-bounceslists.sourceforge.net [lists.sourceforge.net%5d">mailto:blojsom-users-bounceslists.sourceforge.net] blojsom-users-bounceslists.sourceforge.net%5d"><mailto:blojsom-users-bounceslists.sourceforge.net%5d> On Behalf Of David Czarnecki
Sent: Monday, October 30, 2006 9:01 PM
To: blojsom-users
Subject: Re: [Blojsom-users] Monthly Archives on OS 10.4.8

Hmmmm, that’;s the macro that’;s in the page macros included with blojsom. Are you able to use the following in a page?

#MonthlyArchive(1 2006)

If not, what gets printed in the Tomcat log file?


On 10/30/06 8:16 PM, "Milos Topic"; <topicmmail.montclair.edu&gt; wrote:
Does anyone know how to setup MonthlyArchive on entries on Apple̵7;s rendition of Blojsom?
 
I have used the below code as found on one of the Apple̵7;s open source sites, but it doesn̵7;t work…;it actually prevents the blogs from loading completely.
 
#macro(MonthlyArchive $startingMonth $startingYear)
<ul>
&nbsp; &nbsp; #set ($currentMonth = $BLOJSOM_CALENDAR.getCurrentMonth() + 1)
   ; #set ($totalMonths = 12)
 ; &nbsp; #set ($currentYear = $BLOJSOM_CALENDAR.getCurrentYear())
&nbsp; &nbsp; #set ($padding = 0)
   ; #foreach ($year in [$currentYear..$startingYear])
  ; &nbsp; &nbsp; &nbsp;#set ($monthIndex = 1)
   ; &nbsp; &nbsp; #if ($year == $startingYear)
 ; &nbsp; &nbsp; &nbsp; &nbsp;   ;#set($monthIndex = $startingMonth)
&nbsp; &nbsp; &nbsp; &nbsp; #end
 ; &nbsp; &nbsp; &nbsp; #if ($year == $currentYear)
   ; &nbsp; &nbsp; &nbsp; &nbsp; #set($totalMonths = $currentMonth)
 ; &nbsp; &nbsp; &nbsp; #else
 ; &nbsp; &nbsp; &nbsp; &nbsp;   ;#set ($totalMonths = 12)
 ; &nbsp; &nbsp; &nbsp; #end
   ; &nbsp; &nbsp; #foreach ($month in [$totalMonths..$monthIndex])
 &nbsp; &nbsp; &nbsp; &nbsp;   ; #set ($calMonth = $month - 1)
   ; <li><a href=";#BlogURL()$year/#if($month < 10)$padding#end$month/">$BLOJSOM_CALENDAR.getMonthName($calMonth) $year</a&gt;</li&gt;
 &nbsp;   ; &nbsp; #end
 &nbsp; &nbsp;#end
</ul>
#end
&nbsp;
I am sure that there has to be a simpler way or doing this that actually works.
&nbsp;
Thanks,

Milos
-
--


"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former.&quot; - Albert Einstein.


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&;kid=120709&bid=263057&dat=121642 <http://sel.as-us.falkag.net/sel?cmd=lnk&amp;amp;kid=120709&;amp;bid=263057&amp;dat=121642> <;http://sel.as-us.falkag.net/sel?cmd=lnk&;amp;kid=120709&amp;bid=263057&amp;dat=121642&gt;



_______________________________________________
Blojsom-users mailing list
Blojsom-userslists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/blojsom-users



--
David Czarnecki

http://www.blojsom.com/blog/ | http://blojsom.sf.net

[1]

about | contact  Other archives ( Real Estate discussion Medical topics )