www.webdeveloper.com
Results 1 to 6 of 6

Thread: cannot get any php/mySQL results

  1. #1
    Join Date
    Feb 2004
    Location
    Manchester UK
    Posts
    89

    cannot get any php/mySQL results

    Can any gurus please help as I am relatively new to php/MySQL.

    I have a php page in which I wish to get a list of results from a certain date in a mySql database table.
    The database is built using PHP MyAdmin.

    The thing is that when I enter the criteria for date and type in the date I do not get any list on the results page.

    All my code is in the zip file I have sent, plus a screenshots of what I get on the results page and the actual database structure.
    On the results page on the mysql_connect I have put password where my password is just for this.

    The database is of music charts.
    Database name: charts50db
    Table name: uk
    Field names are: id lw tw wks title artist date.


    All help is very much appreciated
    I'm desperate to get this thing working.
    Attached Files Attached Files

  2. #2
    Join Date
    Sep 2004
    Posts
    80
    Sorry, I cant help you as I don't know what the script is.
    In the included zip file, I can't find where you are connecting to the script at.
    Why dont u use just:
    Code:
    <HTML>
    <HEAD>
    #Blah Blah Blah stuff here
    <style type="text/css">
     @import url($URL_WANTED);
    #Blah Blah Blah stuff here
    </style>
    </HEAD>
    </HTML>

  3. #3
    Join Date
    Aug 2003
    Location
    In my house
    Posts
    4,004
    I see from your screenshot that you are accessing the page via your C: drive — that is probably why the script is not working. In order for PHP files to be parsed by the PHP interpreter, you must access them through your webserver (e.g., http://localhost/).

  4. #4
    Join Date
    Feb 2004
    Location
    Manchester UK
    Posts
    89
    Many many thanks Paul Jr.

    It now works. I thought is would also work accessing it using the C: drive on my local machine. Obviously I am wrong.
    I use Apache as my local server.

    My pages are in the htdocs folder. What do I do if I want the pages in my webfolder addressed as C:\website\oldies folder with all my other website pages, images, styles etc.?

    Again many thanks for helping a complete newbie.

  5. #5
    Join Date
    Mar 2004
    Posts
    282
    Originally posted by charter
    Many many thanks Paul Jr.

    My pages are in the htdocs folder. What do I do if I want the pages in my webfolder addressed as C:\website\oldies folder with all my other website pages, images, styles etc.?

    in your apache config file just change "DocumentRoot" to "C:/websites/oldies/"

    it would look like this:

    Code:
    DocumentRoot "C:/websites/oldies/"
    you need the quotes and the slashes need to go that direction "/".
    Last edited by silent11; 10-01-2004 at 08:58 AM.

  6. #6
    Join Date
    Feb 2004
    Location
    Manchester UK
    Posts
    89
    Many thanks Silent11.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles