Need help with PHP and mySQL

Discussion in 'Mac Help/Tips' started by G4scott, Oct 25, 2002.

  1. G4scott macrumors 68020


    Jan 9, 2002
    Austin, TX
    I installed mySQL on my G4 using the instructions in the November issue of MacAddict. Well, I think that something's wrong with it, because it doesn't want to work right. Is there a way to uninstall it? This is very screwed up...

    Then, is there an easy way to put up a PHP voting system using a mySQL server??? Every thing that I've seen requires compiling, extensive PHP knowledge, and tons of other crap... I need help...
  2. Choppaface macrumors 65816

    Jan 22, 2002
    try following the instructions at for installing his copy of PHP and mysql

    for the voting thingy, even if you find a package somewhere, you're going to need at least a little bit of knowledge to get things running. dunno where you'd find one though, sorry
  3. Beej macrumors 68020


    Jan 6, 2002
    Buffy's bedroom
    The software uses uses PHP and works nicely with mySQL. It's easy to set up and use, and it's free for non-commercial purposes. Grab it at

    I've used it before and it ran smoothly except for a few errors. I simply commented out the offending lines of code (the errors will tell you which ones (if you get any arrors)) and everything still managed to work very nicely.
  4. jvaska macrumors 6502

    Feb 18, 2002
    you can do it...if you got mysql setup on your can do it... - tutuorials, code, small forum for help q's... - LOTS of code...

    when i was teaching myself the in's and out's of php/mysql...i would go as far as i could...then search the web for any help info...then if i couldn't do what i needed to do...i would post a q on a forum...

    it went very fast...and i learned alot...jv
  5. G4scott thread starter macrumors 68020


    Jan 9, 2002
    Austin, TX
    thanks for your help guys. I have mySQL installed on my computer, and I think I got it running, but I'm not entirely sure...

    I downloaded the mySQL 3.23.52.pkg, and installed it from there. Then, I ran the MySQL installation script by typing (in the /usr/local/mysql directory):
    sudo ./scripts/mysql_install_db

    Then I changed the ownership of all the MySQL files by entering sudo chown -R mysql /usr/local/mysql/*

    Then I tried to launch MySQL by typing:
    sudo ./bin/safe_mysqld -user=mysql &

    and I got this result:
    [Dads-Computer:/usr/local/mysql] scott% Starting mysqld daemon with databases from /usr/local/mysql/data
    021027 08:24:06 mysqld ended

    and when I pushed enter, it gave me this:
    [1] Done sudo ./bin/safe_mysqld -user=mysql

    So, I'm not sure if I properly launched MySQL or what. When I tried to create a ne MySQL admin root password by typing this:
    ./bin/mysqladmin -u root password 'new password'

    I got this:
    ./bin/mysqladmin: connect to server at 'localhost' failed
    error: 'Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)'
    Check that mysqld is running and that the socket: '/tmp/mysql.sock' exists!

    Does anyone have any idea what i did wrong, or what I'm doing wrong? It worked perfectly before, and I had mySQL up and running with pMachine free, but now nothing seems to work...

    Help please :confused:
  6. jvaska macrumors 6502

    Feb 18, 2002
    i had some odd messages when i installed mysql on my computer...i also didn't think that it was working...

    the test...turn on your internet connection...figure out your IP number...and try to connect using your web browser...see what you get...

    also...when you boot up your might watch to see if it says that mysql is starting...until i saw this myself...i didn't think it was working...but then i gave the above a try...and i was in business (and i've learned ALOT about mysql and php since)...

    good luck!

  7. macktheknife macrumors 6502a


    Jan 24, 2002
    Go to this page. It has the installation packages and can help you answer your questions.

    Also, are you sure that MySQL isn't already running? Try starting MySQL (not mysqld but mysql):

    mysql -u root -p

Share This Page