catalyst2 community forums  

Go Back   catalyst2 community forums > catalyst2 Community > General Chit-Chat

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
Old 20-02-2006, 11:10 AM   #1 (permalink)
Al James-PianoEntertainer
 
aljames's Avatar
 
Join Date: Apr 2003
Posts: 159
Can this be done

Hi everyone. Just have a question which maybe someone can help with?

One of the websites I have built (using the CAT2 servers) has a page where the data could potentially change according to what day of the week it is. e.g. it is for a pianobar where they are closed on Mondays so I'd like a hidden layer to appear on Mondays that contains text that says "Closed Mondays". Then come Tuesday, another hidden layer appears and displays text showing Tuesday's piano player (and the Monday layer auto hides). Is this the kind of thing that can be date driven? I am using dreamweaver MX2004.

Hope someone can offer advice.

Thanks
Al
__________________


Al James - Piano Entertainer
www.aljames.co.uk
aljames is offline   Reply With Quote
Old 20-02-2006, 11:13 AM   #2 (permalink)
Administrator
 
Jacob's Avatar
 
Join Date: May 2003
Posts: 1,299
Hi Al,

You could do this using pretty much any language, javascript or ASP would certainly do the trick.

Regards,

Jacob
Jacob is offline   Reply With Quote
Old 20-02-2006, 11:51 AM   #3 (permalink)
Al James-PianoEntertainer
 
aljames's Avatar
 
Join Date: Apr 2003
Posts: 159
Thanks Jacob. Can you point me to any resources on the web that will give me a tutorial on how to achieve it?

Cheers
Al
__________________


Al James - Piano Entertainer
www.aljames.co.uk
aljames is offline   Reply With Quote
Old 20-02-2006, 11:52 AM   #4 (permalink)
Administrator
 
Jacob's Avatar
 
Join Date: May 2003
Posts: 1,299
Hi Al,

Have you used any particular languages before?

Regards,

Jacob
Jacob is offline   Reply With Quote
Old 23-02-2006, 08:47 PM   #5 (permalink)
Registered User
 
adam's Avatar
 
Join Date: Jan 2003
Location: UK
Posts: 181
in ASP:

<% if WeekdayName(weekday(date)) = "monday" then %>
<html code>
<% end if%>
<% if WeekdayName(weekday(date)) = "tuesday" then %>
<html code>
<% end if%>

There are better ways of doing it but I think the above way is easier to understand without me explaining it.
adam is offline   Reply With Quote
Old 26-02-2006, 10:08 PM   #6 (permalink)
Al James-PianoEntertainer
 
aljames's Avatar
 
Join Date: Apr 2003
Posts: 159
I use DWmx2004 wysiwyg, keen to learn other languages.

That code you psoted Adam, do I just paste it into the code section of my page? Is there a tutorial or somethin gthat I can get step by step?

Thanks all
Al
__________________


Al James - Piano Entertainer
www.aljames.co.uk
aljames is offline   Reply With Quote
Old 26-02-2006, 10:39 PM   #7 (permalink)
Registered User
 
adam's Avatar
 
Join Date: Jan 2003
Location: UK
Posts: 181
Sorry I didn't test that code, but here is how it works:
http://www.macrodemon.com/day.asp

This is a good site if you are wanting to learn ASP
http://www.w3schools.com/asp/default.asp

If you are wanting to connect a database to the site the you also need to know ADO and SQL. Dreamweaver (I guess thats what you are using) is a very useful tool for generating database driven websites once you've learnt how to use it.
adam is offline   Reply With Quote
Old 27-02-2006, 01:03 PM   #8 (permalink)
Al James-PianoEntertainer
 
aljames's Avatar
 
Join Date: Apr 2003
Posts: 159
THanks Adam, it's a bit complex so I'll just stick to manual updates until I can get my head around this.

CHeers
Al
__________________


Al James - Piano Entertainer
www.aljames.co.uk
aljames is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 10:36 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.