Re: [PHP] Mac OSX !?!?!?
There is a utility called daemonic which is designed to deal with this as well, but works for more than just MySQL -- it's intended to be used for all server daemons. http://daemonic.sourceforge.net/ It is Mac OS X-specific at this time, but according to the web site is designed for future compatibility with any operating system. It can be installed via Fink (http://fink.sourceforge.net) very easily, and is in fact required by many Fink packages. I must confess that I do not know much about it. Erik On Wednesday, January 16, 2002, at 08:01 PM, Richard Baskett wrote: Although the MySQL warnings, I got those because MySQL does not automatically start in OSX, if you know it's started then Im not sure, but if not.. go here to get the autostart utility: http://www.entropy.ch/software/macosx/mysql/ -- PHP General 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] Mac OSX !?!?!?
Kind of hard to say without source code for the session part.. Although the MySQL warnings, I got those because MySQL does not automatically start in OSX, if you know it's started then Im not sure, but if not.. go here to get the autostart utility: http://www.entropy.ch/software/macosx/mysql/ This link will have information and a link of where you can download the utility. Rick The human mind is not capable of grasping the Universe. We are like a little child entering a huge library. The walls are covered to the ceilings with books in many different tongues. The child knows that someone must have written these books. It does not know who or how. It does not understand the languages in which they are written. But the child notes a definite plan in the arrangement of the books---a mysterious order which it does not comprehend, but only dimly suspects. - Albert Einstein From: René Fournier [EMAIL PROTECTED] Date: Wed, 16 Jan 2002 17:50:06 -0700 To: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: [PHP] Mac OSX !?!?!? Can someone PLEASE explain why I get the following error message under OSX (PHP+MySQL), but not under Windows ME or Linux? Warning: Cannot send session cache limiter - headers already sent (output started at /Users/rene/Sites/smartslitters/jupiter/europa/header.inc:6) in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 19 Warning: Unable to save MySQL query result in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 44 Warning: Supplied argument is not a valid MySQL result resource in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 45 --- After these lines, the pages load fine. I'm using PHP Session ID variables (or trying to)--they work fine as I said under other OSes, but now break under OSX. ...Rene --- René Fournier [EMAIL PROTECTED] -- PHP General 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 General 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] Mac OSX !?!?!?
Somebody suggested I post the source--good idea! So here it is... The header.inc file, in its entirety: html head titleSite :: Jupiter :: Europa/title meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 link rel=stylesheet href=../../common/styles.css type=text/css ?php // DETERMINE THE LANGUAGE FROM THE PARENT DIRECTORY // GENERATE VARIABLES FOR LANGUAGE, FILENAME AND NAME $path = explode(/,$PHP_SELF); if (!$lang) { $lang = $path[sizeof($path)-2]; } $file = $path[sizeof($path)-1]; $prename = explode(.,$file); $name = $prename[sizeof($prename)-2]; // SECURITY CHECK session_start(); if (!$PHPSESSID) { die; } elseif (!$auth) { die; } elseif ($auth != $path[sizeof($path)-2]) { die; } $language = All Languages; if ($lang == en) { $language = English; } if ($lang == fr) { $language = FranÁais; } if ($lang == es) { $language = EspaÒol; } if ($lang == de) { $language = Deutsch; } if ($lang == it) { $language = Italiano; } $priv = 2; // CONNECT TO DATABASE $db = mysql_connect(localhost,database,password); mysql_select_db(database,$db); // FETCH TABLE NAMES $listtables = mysql_list_tables(database,$db); // FETCH SELECTED TABLE DATA $fields = mysql_list_fields(database, $table, $db); $columns = mysql_num_fields($fields); ? script language=JavaScript !-- function GP_popupConfirmMsg(msg) { //v1.0 document.MM_returnValue = confirm(msg); } //-- /script /head body bgcolor=#FF text=#00 link=#00 vlink=#00 alink=#00 leftmargin=20 topmargin=20 marginwidth=0 marginheight=0 background=../../common/bg.gif ?php if ($language) { echo span class=adminnormalgreya href=../index.php4Europa/a/span; } if ($table) { echo span class=adminnormalgrey : /spanspan class=adminnormalgreya href=tables.php4Tables/a/span; } ? pnbsp; On Wednesday, January 16, 2002, at 06:01 PM, Richard Baskett wrote: Kind of hard to say without source code for the session part.. Although the MySQL warnings, I got those because MySQL does not automatically start in OSX, if you know it's started then Im not sure, but if not.. go here to get the autostart utility: http://www.entropy.ch/software/macosx/mysql/ This link will have information and a link of where you can download the utility. Rick The human mind is not capable of grasping the Universe. We are like a little child entering a huge library. The walls are covered to the ceilings with books in many different tongues. The child knows that someone must have written these books. It does not know who or how. It does not understand the languages in which they are written. But the child notes a definite plan in the arrangement of the books---a mysterious order which it does not comprehend, but only dimly suspects. - Albert Einstein From: René Fournier [EMAIL PROTECTED] Date: Wed, 16 Jan 2002 17:50:06 -0700 To: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: [PHP] Mac OSX !?!?!? Can someone PLEASE explain why I get the following error message under OSX (PHP+MySQL), but not under Windows ME or Linux? Warning: Cannot send session cache limiter - headers already sent (output started at /Users/rene/Sites/smartslitters/jupiter/europa/header.inc:6) in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 19 Warning: Unable to save MySQL query result in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 44 Warning: Supplied argument is not a valid MySQL result resource in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 45 --- After these lines, the pages load fine. I'm using PHP Session ID variables (or trying to)--they work fine as I said under other OSes, but now break under OSX. ...Rene --- René Fournier [EMAIL PROTECTED] -- PHP General 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: php-list- [EMAIL PROTECTED] - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail mysql-unsubscribe- [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php -- PHP General 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] Mac OSX !?!?!?
Somebody suggested I post the source--good idea! So here it is... The header.inc file, in its entirety: html head titleSite :: Jupiter :: Europa/title meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 link rel=stylesheet href=../../common/styles.css type=text/css ?php // DETERMINE THE LANGUAGE FROM THE PARENT DIRECTORY // GENERATE VARIABLES FOR LANGUAGE, FILENAME AND NAME $path = explode(/,$PHP_SELF); if (!$lang) { $lang = $path[sizeof($path)-2]; } $file = $path[sizeof($path)-1]; $prename = explode(.,$file); $name = $prename[sizeof($prename)-2]; // SECURITY CHECK session_start(); if (!$PHPSESSID) { die; } elseif (!$auth) { die; } elseif ($auth != $path[sizeof($path)-2]) { die; } $language = All Languages; if ($lang == en) { $language = English; } if ($lang == fr) { $language = FranÁais; } if ($lang == es) { $language = EspaÒol; } if ($lang == de) { $language = Deutsch; } if ($lang == it) { $language = Italiano; } $priv = 2; // CONNECT TO DATABASE $db = mysql_connect(localhost,database,password); mysql_select_db(database,$db); // FETCH TABLE NAMES $listtables = mysql_list_tables(database,$db); // FETCH SELECTED TABLE DATA $fields = mysql_list_fields(database, $table, $db); $columns = mysql_num_fields($fields); ? script language=JavaScript !-- function GP_popupConfirmMsg(msg) { //v1.0 document.MM_returnValue = confirm(msg); } //-- /script /head body bgcolor=#FF text=#00 link=#00 vlink=#00 alink=#00 leftmargin=20 topmargin=20 marginwidth=0 marginheight=0 background=../../common/bg.gif ?php if ($language) { echo span class=adminnormalgreya href=../index.php4Europa/a/span; } if ($table) { echo span class=adminnormalgrey : /spanspan class=adminnormalgreya href=tables.php4Tables/a/span; } ? pnbsp; On Wednesday, January 16, 2002, at 06:01 PM, Richard Baskett wrote: Kind of hard to say without source code for the session part.. Although the MySQL warnings, I got those because MySQL does not automatically start in OSX, if you know it's started then Im not sure, but if not.. go here to get the autostart utility: http://www.entropy.ch/software/macosx/mysql/ This link will have information and a link of where you can download the utility. Rick The human mind is not capable of grasping the Universe. We are like a little child entering a huge library. The walls are covered to the ceilings with books in many different tongues. The child knows that someone must have written these books. It does not know who or how. It does not understand the languages in which they are written. But the child notes a definite plan in the arrangement of the books---a mysterious order which it does not comprehend, but only dimly suspects. - Albert Einstein From: René Fournier [EMAIL PROTECTED] Date: Wed, 16 Jan 2002 17:50:06 -0700 To: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: [PHP] Mac OSX !?!?!? Can someone PLEASE explain why I get the following error message under OSX (PHP+MySQL), but not under Windows ME or Linux? Warning: Cannot send session cache limiter - headers already sent (output started at /Users/rene/Sites/smartslitters/jupiter/europa/header.inc:6) in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 19 Warning: Unable to save MySQL query result in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 44 Warning: Supplied argument is not a valid MySQL result resource in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 45 --- After these lines, the pages load fine. I'm using PHP Session ID variables (or trying to)--they work fine as I said under other OSes, but now break under OSX. ...Rene --- René Fournier [EMAIL PROTECTED] -- PHP General 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: php-list- [EMAIL PROTECTED] - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail mysql-unsubscribe- [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php -- PHP General 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] Mac OSX !?!?!?
try calling session_start() as the very first thing in your php script. - Original Message - From: René Fournier [EMAIL PROTECTED] To: PHP General [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, January 16, 2002 7:41 PM Subject: Re: [PHP] Mac OSX !?!?!? Somebody suggested I post the source--good idea! So here it is... The header.inc file, in its entirety: html head titleSite :: Jupiter :: Europa/title meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 link rel=stylesheet href=../../common/styles.css type=text/css ?php // DETERMINE THE LANGUAGE FROM THE PARENT DIRECTORY // GENERATE VARIABLES FOR LANGUAGE, FILENAME AND NAME $path = explode(/,$PHP_SELF); if (!$lang) { $lang = $path[sizeof($path)-2]; } $file = $path[sizeof($path)-1]; $prename = explode(.,$file); $name = $prename[sizeof($prename)-2]; // SECURITY CHECK session_start(); if (!$PHPSESSID) { die; } elseif (!$auth) { die; } elseif ($auth != $path[sizeof($path)-2]) { die; } $language = All Languages; if ($lang == en) { $language = English; } if ($lang == fr) { $language = FranÁais; } if ($lang == es) { $language = EspaÒol; } if ($lang == de) { $language = Deutsch; } if ($lang == it) { $language = Italiano; } $priv = 2; // CONNECT TO DATABASE $db = mysql_connect(localhost,database,password); mysql_select_db(database,$db); // FETCH TABLE NAMES $listtables = mysql_list_tables(database,$db); // FETCH SELECTED TABLE DATA $fields = mysql_list_fields(database, $table, $db); $columns = mysql_num_fields($fields); ? script language=JavaScript !-- function GP_popupConfirmMsg(msg) { //v1.0 document.MM_returnValue = confirm(msg); } //-- /script /head body bgcolor=#FF text=#00 link=#00 vlink=#00 alink=#00 leftmargin=20 topmargin=20 marginwidth=0 marginheight=0 background=../../common/bg.gif ?php if ($language) { echo span class=adminnormalgreya href=../index.php4Europa/a/span; } if ($table) { echo span class=adminnormalgrey : /spanspan class=adminnormalgreya href=tables.php4Tables/a/span; } ? pnbsp; On Wednesday, January 16, 2002, at 06:01 PM, Richard Baskett wrote: Kind of hard to say without source code for the session part.. Although the MySQL warnings, I got those because MySQL does not automatically start in OSX, if you know it's started then Im not sure, but if not.. go here to get the autostart utility: http://www.entropy.ch/software/macosx/mysql/ This link will have information and a link of where you can download the utility. Rick The human mind is not capable of grasping the Universe. We are like a little child entering a huge library. The walls are covered to the ceilings with books in many different tongues. The child knows that someone must have written these books. It does not know who or how. It does not understand the languages in which they are written. But the child notes a definite plan in the arrangement of the books---a mysterious order which it does not comprehend, but only dimly suspects. - Albert Einstein From: René Fournier [EMAIL PROTECTED] Date: Wed, 16 Jan 2002 17:50:06 -0700 To: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: [PHP] Mac OSX !?!?!? Can someone PLEASE explain why I get the following error message under OSX (PHP+MySQL), but not under Windows ME or Linux? Warning: Cannot send session cache limiter - headers already sent (output started at /Users/rene/Sites/smartslitters/jupiter/europa/header.inc:6) in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 19 Warning: Unable to save MySQL query result in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 44 Warning: Supplied argument is not a valid MySQL result resource in /Users/rene/Sites/smartslitters/jupiter/europa/header.inc on line 45 --- After these lines, the pages load fine. I'm using PHP Session ID variables (or trying to)--they work fine as I said under other OSes, but now break under OSX. ...Rene --- René Fournier [EMAIL PROTECTED] -- PHP General 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: php-list- [EMAIL PROTECTED] - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail mysql-unsubscribe- [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive
Re: [PHP] Mac OSX and MySQL
As soon as the mysqld is running (and PHP also of course), you can use phpMyAdmin to set up new tables. If you are not experienced in CLI it's a nice way to go avoiding the CLI as far as possible (IMHO). Get a look at those pages: www.macosx.org www.stepwise.com best regards Stefan Rusterholz, [EMAIL PROTECTED] -- interaktion gmbh Stefan Rusterholz Zürichbergstrasse 17 8032 Zürich -- T. +41 1 253 19 55 F. +41 1 253 19 56 W3 www.interaktion.ch -- - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Wednesday, December 05, 2001 6:24 AM Subject: [PHP] Mac OSX and MySQL The migration continues... Now I have to get my mysql database running under MySQL 3.23.46 on OSX 10.1.1. I've dumped the structure and contents of the database (on Windows) into a text file, and now I'd like to recreate it in the new enivronment. I think I can use the mysql admin tools via command line (but really, what is the syntax for piping a 'dumped' database into a new database? mysqladmin create database dumpeddb.sql??), but one question about users... I have to create a MySQL for my PHP scripts. How do I do this in Mac OSX? There are a bunch of command line tools, but I'm not sure which one[s] to use. Thanks. ...Rene --- René Fournier [EMAIL PROTECTED] -- PHP General 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 General 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] Mac OSX and MySQL
On Wednesday, December 5, 2001, at 12:24 AM, René Fournier wrote: I have to create a MySQL for my PHP scripts. How do I do this in Mac OSX? There are a bunch of command line tools, but I'm not sure which one[s] to use. Well, if you already have MySQL installed, then just use them as normal. Just remember that Unix syntax is different from DOS (lets you do more, actually). If you need to install MySQL, try these: http://developer.apple.com/internet/macosx/osdb.html the above link is for Apple's own recommendations for installing MySQL on Darwin. Just make sure that you use the source code for 3.23.45, not 3.43.44 (because the .44 doesn't shut down properly in Darwin). I used this technique (not the binary) and it works great. http://fink.sourceforge.net if you use Fink (debian-style package installer) you can have it install MySQL for you (as well as PHP and Apache) but I didn't go this route because I wanted more control over the install process. http://www.stepwise.com/Articles/Workbench/2001-10-11.01.html the above link isn't for MySQL at all, it's for PHP, but it's a useful article. Remember to add the --with-mysql configure option because this tutorial doesn't assume that you want to install MySQL. Any questions, email me. Erik -- PHP General 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] Mac OSX and MySQL
On Wed, 5 Dec 2001 15:54, René Fournier wrote: The migration continues... Now I have to get my mysql database running under MySQL 3.23.46 on OSX 10.1.1. I've dumped the structure and contents of the database (on Windows) into a text file, and now I'd like to recreate it in the new enivronment. I think I can use the mysql admin tools via command line (but really, what is the syntax for piping a 'dumped' database into a new database? mysqladmin create database dumpeddb.sql??), but one question about users... Two steps involved - create the database, then dump the data into it. mysqladmin create database mysql database dumpeddb.sql ObNitpick - that is a redirect, not a pipe. I have to create a MySQL for my PHP scripts. How do I do this in Mac OSX? There are a bunch of command line tools, but I'm not sure which one[s] to use. I don't understand? -- David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA Friends come and go, enemies accumulate. -- PHP General 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]