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: Public/Private Events  (Read 491 times)
0 Members and 1 Guest are viewing this topic.
neno123
New Member
*

Karma: 0
Offline Offline

Posts: 0


WWW
« on: February 15, 2002, 12:49:00 AM »

Is there a way to add events to the calendar, and then designate them as either public or private.

I have a client that's a church, and they'd like to be able to use one calendar for both staff and church member events.

They'd like to have the staff to login, and upon login, they can see ALL events.  As a church member, you wouldn't be required to login, and therefore would only see the PUBLIC events.

Need this ASAP if possible.

Thanks...

Logged
Rufus
New Member
*

Karma: 0
Offline Offline

Posts: 0

Childrens Entertainer, Web Geek


WWW
« Reply #1 on: February 15, 2002, 09:10:00 AM »

Yep. BUT! It'll take some doing. I've been working on this, and here's the approach I've been taking. The assumptions I've been making are: 1) Public events are viewable by anyone, whether registered or not, and 2) Private events are viewable ONLY by the person who is registered. It doesn't really matter if adding events are restricted, but if an anonymous user adds a private event... you get the picture.

The steps I've done.
1. Add a field to the event (from the admin screens), EventType, making this a dropdown with Public and Private as options.

2. On the template pages, add some code (and if you want more details on this, rather than rough pseudocode... lemme know). The code should check for two things:

<% IF USER LOGGED IN %>
  ... Do the code to display event information, regardless of event type.

<% ELSE %>
  <% IF $EVENT->field{'EventType'} eq 'Public' %>
         (or something similar - I'm doing this with no code in front of me)
       ...Display the public Event info
   <% ELSE %>
       ... Either display a 'Private Event' message, or nothing at all - do they need to know that person X is doing SOMETHING? if not, do nada
   <%/IF %>
<%/IF %>

And that'd do it. PLEASE BEAR IN MIND - I don't have the syntax for getting the event details in front of me, so I just winged it as best I could - but that's the logic you want, and this should be on your template doc. If you're using the default template, this would go in default.html where each event is displayed.

Regards, and hope this helps!
-TOby

------------------
If I can count on my friends, why did God  give me fingers?

- W. T. Pooh

Logged

If I can count on my friends, why did God  give me fingers?

- W. T. Pooh


maddy
Guest
« Reply #2 on: April 28, 2002, 07:44:00 PM »

I'd like to be emailed as soon as a full code spec or plugin for this is available! or if anyone has incorporated this and can send the complete snippet + instructions my way!

maddness@maddness.org

Logged
ljost
New Member
*

Karma: 0
Offline Offline

Posts: 0


WWW
« Reply #3 on: November 09, 2003, 08:09:00 AM »

Has anyone reesolved this issue and been able to get code working to enable private and public postings?  Can you share the code?

------------------
Larry

Logged

Larry
DanO
Moderator
Full Member
*****

Karma: 13
Offline Offline

Posts: 230

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


WWW
« Reply #4 on: November 09, 2003, 03:43:00 PM »

As I replied to your other message on the same subject:

** Has anyone actually gotten the Private / Public capability to work? **

There are numerous way to achieve it, try searching the forums for "private" (without the quotes) to read what has been discussed on the subject previously. One such message is: "First attempt at customization".

There is also a plug-in titled "Private Events" at the Unofficial CalendarScript - Mods and Plugins site which if it doesn't do exactly what you want right now, may be able to be modified to your purpose.

Dan O.

------------------

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