[PHP-DB] Trying to pull a weeks worth of data of a DATE entry

2001-05-15 Thread Marc Johnson

I am trying to pull a weeks worth of data from MySQL from a DATE var field.
Which in turn I can seperate to each days 'entries' sorted by date AND time.
Basically trying to set up a page to pull 'news entry date' sorted by date
and time, with each
day having its own header (like you see on so many websites) and having that
header appear
only once per days worth of 'news'.

Not really sure where to start considering I have only been at this for two
days. My scripting skills
are limited so far so I am sure that the approach I am taking is the hard
way.

Can anyone provide me with a link to examples of this code (the actual code)
so I can see how it has been done?
Or perhaps if its a easy solution (i.e. SELECT date "(from date to date)"
type command). I have seen examples of
sorting by date and munipulation of the date via SELECT, but cant seem to
pinpoint how to extract only from-to dates.
Even if I can use a SELECT command where date = x would work.

Any help, or pointing in the right direction would be greatly appreciated
(and probably save money on my Rogain bills).

Thanks,

Seriously Confused in Seattle,
Marc



I have tried multiple attempts at some variation of:

   $week_var = 7;
   $tdate = getdate();
   $yday_var = $tdate['yday'];
   $wdate = $yday + $week_var;


Granted



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] newbie: showing records from SQL

2001-05-15 Thread Marc Johnson

I am a newbie also.

Here is the link that got me started (I use MySQL, but I am certain the call
tags should be the same, if not, very similar).

http://www.webmasterbase.com/article.php?aid=228

A little tutorial ranging from installation notes - creating and entering
data - pulling data to webpages.

Hope this helps.

Marc

"Jason Stechschulte" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> On Sat, Apr 28, 2001 at 07:06:31PM +0200, twopeak wrote:
> > I managed to find out how to add records in my table, but I can't find
out
> > how to show records...
> > Are there manuals on the web that are specific to php & sql?
> > I've found manuals for both, but they both give only a little bit of
> > information, and refer to the other website for more information...
>
> Have you even tried looking yourself??  The page below has many links to
> examples, tutorials, and many other useful things.
>
> http://www.php.net/links.php
> --
> Jason Stechschulte
> [EMAIL PROTECTED]
> --
> The way these things go, there are probably 6 or 8 kludgey ways to do
> it, and a better way that involves rethinking something that hasn't
> been rethunk yet.
>  -- Larry Wall in <[EMAIL PROTECTED]>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]