Email address obfuscation in effect -- please
click here to turn it off.
[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
- To: "MLUG Members" <EMAIL:PROTECTED>
- Subject: RE: [MLUG] Up against the wall with LAMP...
- From: "Davis, Jared Scott" <EMAIL:PROTECTED>
- Date: Tue, 28 Mar 2006 16:17:12 -0600
- Delivery-date: Tue, 28 Mar 2006 17:06:08 -0600
- Envelope-to: EMAIL:PROTECTED
- Reply-to: MLUG Members <EMAIL:PROTECTED>
- Sender: EMAIL:PROTECTED
- Thread-index: AcZSrk1Avu0l3wo6TsmOD9T73H8BzwABt9/w
- Thread-topic: [MLUG] Up against the wall with LAMP...
Make sure you have the php-mysql package installed. Mine is
php-mysql-4.3.9-3.9
This allows php and mysql to talk to each other.
Jared Davis
Internet Administrator
Residential Life
University of Missouri-Columbia
100 Pershing Hall
(573) 884-3616
> -----Original Message-----
> From: EMAIL:PROTECTED [mailto:members-
> EMAIL:PROTECTED] On Behalf Of Mike Pepper
> Sent: Tuesday, March 28, 2006 3:27 PM
> To: EMAIL:PROTECTED; Calton, Carolyn K.
> Subject: [MLUG] Up against the wall with LAMP...
>
> I have been working on this forever, and it's time to get rolling.
> I bought Paul DuBois's MySQL third edition to assist in learning
MySQL.
> I have MySQL installed, apache2 installed, php4 installed, and the
pear
> package. I can connect to the MySQL program both locally and remotely.
> All is well up until it's time to bring the web into play.
> I can display simple php scripts without a problem.
>
> Both of these simple scripts work...
>
> <html>
> <body>
> <p>Hello World!</p>
> </body>
> </html>
>
> and
>
> <html>
> <body>
> <p><?php print ("Hello World!"); ?></p>
> </body>
> </html>
>
> Both display Hello World! in the browser as expected.
>
> Deeper into the tutorial he wants to use the c api which should be
> included in
> the packages that I am using.
>
> The package and version list follows.
>
> SuSE 9.3 Professional
>
> mysql Ver 14.7 Distrib 4.1.10a, for suse-linux (i686)
>
> PHP 4.3.10 (cli) (built: Mar 22 2005 19:34:44)
> Copyright (c) 1997-2004 The PHP Group
> Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies
>
> pear:
> Configuration:
> ==============
> PEAR executables directory bin_dir /usr/bin
> PEAR documentation directory doc_dir /usr/share/php/doc
> PHP extension directory ext_dir /usr/lib/php/extensions
> PEAR directory php_dir /usr/share/php
> PEAR Installer cache directory cache_dir /tmp/pear/cache
> PEAR data directory data_dir /usr/share/php/data
> PHP CLI/CGI binary php_bin /usr/bin/php
> PEAR test directory test_dir /usr/share/php/test
> Cache TimeToLive cache_ttl 3600
> Preferred Package State preferred_state stable
> Unix file mask umask 22
> Debug Log Level verbose 1
> HTTP Proxy Server Address http_proxy <not set>
> PEAR server master_server pear.php.net
> PEAR password (for password <not set>
> maintainers)
> Signature Handling Program sig_bin /usr/local/bin/gpg
> Signature Key Directory sig_keydir /etc/pearkeys
> Signature Key Id sig_keyid <not set>
> Package Signature Type sig_type gpg
> PEAR username (for username <not set>
> maintainers)
>
> The program that I am attempting to run is:
>
> <html>
> <head>
> <title>U.S. Historical League</title>
> </head>
> <body bgcolor="grey">
> <p>Welsome to the U.S. Historical League Web Site.</p>
> <?php
> # USHL home page
>
> require_once "/usr/share/php/DB.php"
>
> $conn =& DB::connect ("mysql://sampadm:EMAIL:PROTECTED");
> if (DB::isError ($conn))
> exit ();
> $result =& $conn->query ("SELECT COUNT(*) FROM member");
> if (DB::isError ($result))
> exit ();
> if ($row =& $result->fetchrow ())
> print ("<p>The League currently has " . $row[0] . "
members.</p>");
> $result->free ();
> $conn->disconnect ();
> ?>
> </body>
> </html>
>
> The error that I get is:
> Parse error: parse error, unexpected T_Variable
> in /home/mike/public_html/test.php on line 12
>
> Feel free to run it for your self.
> http://procurement.missouri.edu/~mike/test.php
>
> I really would like for this to work so that I can follow the
tutorials in
> the
> book, and eventually build a form on the web that will access the
> database.
>
> At this point I am so frustrated that I can't see straight.
> cursing loudly, has not helped at all.
>
> Thanks for your time in advance.
>
> Mike
>
> _______________________________________________
> members mailing list
> EMAIL:PROTECTED
> http://mlug.missouri.edu/mailman/listinfo/members
_______________________________________________
members mailing list
EMAIL:PROTECTED
http://mlug.missouri.edu/mailman/listinfo/members