Welcome, Guest. Please login or register.
Did you miss your activation email?


Login with username, password and session length

Search

 
Advanced search

8043 Posts in 1856 Topics- by 2099 Members - Latest Member: roi
Pages: [1]   Go Down
Print
Author Topic: A small change to ssi.html  (Read 282 times)
0 Members and 1 Guest are viewing this topic.
ooccl
New Member
*

Karma: 0
Offline Offline

Posts: 0


WWW
« on: June 26, 2004, 02:40:00 PM »

For a couple of days I've been working on displaying a short list of calendar script events on my index.php page.  I finally got the syntax worked out to call the ssi script from a php page; (that was a real head banger).  Now I just need to tweak the output from the ssi.html a little.

The event list is going into a 150 pixel wide column, so I don't have a lot of space.  The default output places five spacea "a tab" followed by a bullet in front of the event title.  I'd to get rid of tab, but keep the bullet.  I also removed the code for the time stamp.

This has to be really simple, but I don't know perl.  Something in the below middle two lines of code from the calendar script 3.2 ssi.html file generates a tab in front of the bullet.  Can anyone tell what to change to remove the five space tab, but keep the bullet?

<%FOREACH EVENT%>
<% if ($_SHOW_GRID_EVENT_BULLET) {%>•
<%}%>
<%= $EVENT->{'details'}->{'title'} %><BR>

What I actually want to accomplish is to list the next five events regardless of which month the event falls in.  The included ssi.html file allows me to successfully list 30 days of events and this will will work for now.  I know there is another template to list x-number of events, but it only works within the current month.  Has anyone else solved this problem?

Thanks
/Roger

Logged
DanO
Moderator
Full Member
*****

Karma: 13
Offline Offline

Posts: 230

Please don't PM me. Post in the open forum.


WWW
« Reply #1 on: June 26, 2004, 05:29:00 PM »

** The default output places five spacea "a tab" followed by a bullet in front of the event title. **

"Tabs" do not display in HTML pages. Also, multiple spaces together will be displayed as a single space within an HTML page's output so I don't know where your formatting problem is unless it is the spacing caused by the <DT> and <DD> HTML tags (if you haven't edited them out). If so, they can probably be removed or their spacing adjust using CSS code.

** What I actually want to accomplish is to list the next five events regardless of which month the event falls in. **

You'd have to get a set numbers of day's events then set up a counter to stop the display of those events once the number of events you want displayed was reached.

A counter is already used in the template so all you should have to do is add one line right after the <%FOREACH EVENTLIST%> line to exit the loop once the target number is reached. Eg.

<%FOREACH EVENTLIST%>
<% last if ($total_events == 5); %>

Dan O.


[This message has been edited by DanO (edited June 26, 2004).]

Logged
Pages: [1]   Go Up
Print
Jump to: