Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-24-2004, 11:43 AM   PM User | #1
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
Day

Can anyone write me a php script which says "Today is " followed by the day?
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Old 01-24-2004, 11:50 AM   PM User | #2
gammahelixx
New to the CF scene

 
Join Date: Jan 2004
Location: Florence, AL
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
gammahelixx is an unknown quantity at this point
http://www.php.net/manual/en/function.date.php

This will have what you need. This is one of my most frequently looked up pages on the manual, I can't seem to remember alot of the date function's arguments, even though I use them nearly daily
gammahelixx is offline   Reply With Quote
Old 01-24-2004, 12:02 PM   PM User | #3
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
I don't know any php but for what this is being used for it needs to be in php so can some write me a script.
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Old 01-24-2004, 12:04 PM   PM User | #4
gammahelixx
New to the CF scene

 
Join Date: Jan 2004
Location: Florence, AL
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
gammahelixx is an unknown quantity at this point
Example 1 and 2 have full working lines of code. Just pick which way you want it to look.
gammahelixx is offline   Reply With Quote
Old 01-24-2004, 12:30 PM   PM User | #5
Nightfire
Senior Coder

 
Nightfire's Avatar
 
Join Date: Jun 2002
Posts: 4,266
Thanks: 6
Thanked 48 Times in 48 Posts
Nightfire is on a distinguished road
Today is <?php echo date("l"); ?>
__________________
Blue Panda
Website Design | 1 Pound Ads | 'ow much? | Coding Geeks
Nightfire is offline   Reply With Quote
Old 01-24-2004, 12:35 PM   PM User | #6
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
Quote:
Originally posted by Nightfire
PHP Code:
Today is <?php echo date("l"); ?>
So I just put that in the .php page I take it.
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Old 01-24-2004, 12:43 PM   PM User | #7
Nightfire
Senior Coder

 
Nightfire's Avatar
 
Join Date: Jun 2002
Posts: 4,266
Thanks: 6
Thanked 48 Times in 48 Posts
Nightfire is on a distinguished road
Yeah, just put it wherever you want it to show
__________________
Blue Panda
Website Design | 1 Pound Ads | 'ow much? | Coding Geeks
Nightfire is offline   Reply With Quote
Old 01-24-2004, 02:50 PM   PM User | #8
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
Thanks
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Old 01-25-2004, 12:14 PM   PM User | #9
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
I have got this
Code:
<P><CENTER><FONT SIZE="+1" FACE="Arial">Today is <?php echo date("l"); ?> </FONT></CENTER></P>
but it is not working
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Old 01-25-2004, 12:29 PM   PM User | #10
gammahelixx
New to the CF scene

 
Join Date: Jan 2004
Location: Florence, AL
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
gammahelixx is an unknown quantity at this point
Did you name the file index.php or pagename.php (whatever your page is named) instead of pagename.html?
gammahelixx is offline   Reply With Quote
Old 01-25-2004, 01:09 PM   PM User | #11
Nightfire
Senior Coder

 
Nightfire's Avatar
 
Join Date: Jun 2002
Posts: 4,266
Thanks: 6
Thanked 48 Times in 48 Posts
Nightfire is on a distinguished road
And is php enabled on your server?
__________________
Blue Panda
Website Design | 1 Pound Ads | 'ow much? | Coding Geeks
Nightfire is offline   Reply With Quote
Old 01-25-2004, 03:03 PM   PM User | #12
me'
Senior Coder

 
Join Date: Nov 2002
Location: Warwickshire, England
Posts: 1,229
Thanks: 0
Thanked 0 Times in 0 Posts
me' is an unknown quantity at this point
And is it on a server, not being viewed locally?
__________________
David House - Perfect is achieved, not when there is nothing left to add, but when there is nothing left to take away. (Antoine de St. Exupery).
W3Schools | XHTML Validator | CSS Validator | Colours | Typography | HTML&CSS FAQ | Go get Mozilla Now | I blog!
me' is offline   Reply With Quote
Old 01-25-2004, 03:32 PM   PM User | #13
gsnedders
Senior Coder

 
gsnedders's Avatar
 
Join Date: Jan 2004
Posts: 2,340
Thanks: 1
Thanked 7 Times in 7 Posts
gsnedders will become famous soon enough
Quote:
Originally posted by gammahelixx
Did you name the file index.php or pagename.php (whatever your page is named) instead of pagename.html?
That's the problem, thanks!
__________________
Geoffrey Sneddon
gsnedders is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
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 On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 07:43 AM.


Advertisement
Log in to turn off these ads.