#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2000
    Posts
    13
    Rep Power
    0
    i'm trying to build a database for the local music scene. music listings are put in the database with musicians name, date (yyyy-mm-dd format), where to, etc.

    question 1: is there a way to grab entries sorted by thier first letter? for example, having links a,b,c,...,z, and by clicking on the "a" link you get only the musician's whose names start with a.

    question 2: is there a way to get future dates? for example $today = date("Y-m-d");
    will get you todays date, is there a way to get tomorrows date. day after tomorrow, and the day after that, etc.? this is so i can show who's playing where on future dates.

    thanks, in advance.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 1999
    Location
    London
    Posts
    110
    Rep Power
    0
    q1. select * from <table> order by <column name>;
    q2. probably isnt the easiest way but hey it works

    <?
    $today = date("Y-m-d");
    $tomorrow=mktime(0,0,0,date("m"),date("d")+1,date("Y"));
    echo $today."<br>";
    $tomorrow2=date("Y-m-d",$tomorrow);
    echo $tomorrow2;
    ?>

    hth

    ------------------
    cheers
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2000
    Posts
    13
    Rep Power
    0
    great, thanx it worked!

Similar Threads

  1. couple of newb questions about input
    By lummy64 in forum C Programming
    Replies: 3
    Last Post: January 24th, 2004, 11:45 PM
  2. a Couple of questions!
    By Nik in forum Linux Help
    Replies: 0
    Last Post: January 21st, 2004, 12:32 PM
  3. Replies: 0
    Last Post: November 17th, 2003, 07:11 PM
  4. a Couple of questions!
    By Nik in forum Perl Programming
    Replies: 10
    Last Post: September 20th, 2003, 02:19 PM
  5. couple of dns questions
    By kubicon in forum DNS
    Replies: 3
    Last Post: August 7th, 2003, 09:28 PM

IMN logo majestic logo threadwatch logo seochat tools logo