Re: [css-d] UL based Event Calendar CSS

2008-06-25 Thread Sohail Aboobaker
Thanks Luc,

This looks great and exactly what we were looking for. One Quick thing; How
do we handle events that span multiple days? 

Sohail

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Luc
Sent: June-25-08 12:00 AM
To: Sohail on css-discuss
Subject: Re: [css-d] UL based Event Calendar CSS

Hello Sohail, 
It was foretold that on 25/06/2008 @ 23:32:08 GMT-0400 (which was
00:32:08 where I live) Sohail Aboobaker would write:

snipped a bit

 We are looking for example event calendar CSS that outputs event in
calendar
 format. The html contains an unordered list of days with events as a
 sub-line wherever applicable.

Something like this?

http://www.cssnewbie.com/list-based-css-calendar/


 
-- 
Best regards,
 Luc
_

http://www.dzinelabs.com

Using the best e-mail client: The Bat! version 4.0.18 with Windows XP
(build 2600), version 5.1 Service Pack 2 and using the best browser:
Opera.

Doctors automatically know what's wrong with you. They have a sick
sense. - Beau M., age 10. 


__
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

__
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] UL based Event Calendar CSS

2008-06-25 Thread Christian Heilmann
Sohail Aboobaker wrote:
 Thanks Luc,

 This looks great and exactly what we were looking for. One Quick thing; How
 do we handle events that span multiple days? 
   
Use a table, that's what they are for?

__
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] UL based Event Calendar CSS

2008-06-25 Thread Bill Brown
Christian Heilmann wrote:
 Sohail Aboobaker wrote:
 Thanks Luc,

 This looks great and exactly what we were looking for. One Quick thing; How
 do we handle events that span multiple days? 
   
 Use a table, that's what they are for?

Well put, Christian. I'm speaking at a conference in September on
Advanced CSS (same conference as Zoe Gillenwater) and one section in my
presentation is called Why Tables Aren't Evil.

I think that some people mistook the message we were all transmitting
over the past few years and they overlook the fact that sometimes, a
table is exactly the right answer.

Anyway, well said. Love your books (and your sites), by the way.

Bill Brown
TheHolierGrail.com
__
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/


Re: [css-d] UL based Event Calendar CSS

2008-06-25 Thread Bill Brown
Sohail Aboobaker wrote:
 The problem that I see using tables is that in order to make changes to
 the presentation, you will need to change the HTML code as opposed to
 changing the CSS. In dynamic applications, the HTML code is ideally
 generated through some sort of application engine (ASP, JAVA etc.). In
 order to change HTML, we will need a developer while in order to change
 CSS, we will only need a UI designer.

 Since, the appearance is part of UI designer's responsibility, we would
 like to avoid having to make changes to ASP or JSP code in order to
 refine / change presentation.

 Sohail

Sohail,

I understand your issue, but the problem has a different fundamental
problem at its core. I've cc'd the list again on this because I think
it's an important point. My apologies to everyone for this lengthy email.

The problem is that in your example, your changes SHOULD be made to the
HTML...they are, in fact, changes which belong in the source and not in
the CSS.

Take for example, a one hour event in a table inside a tbody inside a tr
inside a td. The rowspan for this event would be equivalent to the
hourly length of the event (one for hourly intervals, two for half hour
intervals, four for fifteen minute intervals). This is easily calculated
using either PHP, JSP, ASP or even Javascript if you'd rather do it
client-side.

I've included two examples (included below) which might better
illustrate the problems you'd encounter trying to build a calendar
without tables. In the first example [1], the table, you can see that
all a developer would need to do is provide you with a variable. In the
dynamic applications you speak of, this should be a piece of cake. CSS
is then applied in whatever skin/theme/what-have-you that you'd like to
control the appearance of the site. Its functionality is properly
handled through scripting.

Now, we have a look at the CSS-only method [2]. In this case, I've built
an example of what I think you might be looking for. As you can see,
we'd still need the duration variable, which we would then apply via a
CSS class. Our problems really begin when we have more than one event
occurring during a time when another event is already occurring. This
slides the event past (to the right) of the earlier event, creating a
cascade to the right, widening our calendar. Of course, in a known
environment (tricky with dynamic builds), you could work around this by
assigning a width to the event or if you wanted to go nuts trying, you
could attempt to style it with absolutely positioning (NOT recommended).

In summation, sometimes a table is the right tool for the job. And if
your programmer cannot provide you (quickly) with a variable which can
dropped in where it needs to go in a calendar application...well, not to
be rude, but you might want to find another programmer. The real truth
of the matter is that CSS isn't designed for calculating, which would be
required for this type of application.

CSS is literally a properties-ONLY language. If you think of it from a
programmer's point of view, the syntax is even similar:
For example, in Javascript:
obj = {
  property : value,
  method   : function () {}
}
And in CSS:
obj {
  property : value;
}
There's just no methods (let's not go into CSS expressions).

Anyway, I've included the examples...hopefully they'll help clarify what
is already a long-winded explanation.

I hope it helps.
Bill Brown
TheHolierGrail.com


///
[1] Tabled Calendar
///
table border=1
  thead
trth colspan=0Daily Calendar/th/tr
  /thead
  tfoot
trtd colspan=02 events scheduled/td/tr
  /tfoot
  tbody
tr
  td8:00 AM/td
  td rowspan=2Event One (8:00 AM - 10:00 AM/td
  td rowspan=4Event Two (8:00 AM - 12:00 AM/td
/tr
tr
  td9:00 AM/td
  td rowspan=2Event Three (9:00 AM - 11:00 AM/td
/tr
trtd10:00 AM/td/tr
trtd11:00 AM/td/tr
trtd12:00 PM/td/tr
  /tbody
/table

///
[2] CSS-ed Calendar
///
style type=text/css
div.calendarShell {
  background-color:  #f2f2f2;
  border:2px solid #00;
  margin:0 20px;
  }
ul.calendar * {
  line-height:   1;
  }
ul.calendar {
  font-size: 16px;
  list-style:none;
  margin:0 0 0 5em;
  padding:   0;
  position:  relative;
  z-index:   1;
  }
ul.calendar ul {
  list-style:none;
  margin:0;
  padding:   0;
  }
ul.calendar li {
  list-style:none;
  margin:0;
  padding:   0;
  }
ul.calendar li li {
  position:  relative;
  }
ul.calendar li li.odd {
  background-color:  #f1f1f1;
  }
ul.calendar li li p {
  background:#dedede;
  float: left;
  margin:0;
  position:  relative;
  

Re: [css-d] UL based Event Calendar CSS

2008-06-24 Thread Luc
Hello Sohail, 
It was foretold that on 25/06/2008 @ 23:32:08 GMT-0400 (which was
00:32:08 where I live) Sohail Aboobaker would write:

snipped a bit

 We are looking for example event calendar CSS that outputs event in calendar
 format. The html contains an unordered list of days with events as a
 sub-line wherever applicable.

Something like this?

http://www.cssnewbie.com/list-based-css-calendar/


 
-- 
Best regards,
 Luc
_

http://www.dzinelabs.com

Using the best e-mail client: The Bat! version 4.0.18 with Windows XP
(build 2600), version 5.1 Service Pack 2 and using the best browser:
Opera.

Doctors automatically know what's wrong with you. They have a sick
sense. - Beau M., age 10. 


__
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/