Wrox Programmer Forums
Go Back   Wrox Programmer Forums > PHP/MySQL > MySQL
|
MySQL General discussion about the MySQL database.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the MySQL section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 3rd, 2005, 04:36 PM
Registered User
 
Join Date: Nov 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Problems with php and mysql

I am trying to create a php frount end for MySQL using the PEAR php modules. I am able to connect and display information from the database, however I am having problems with setting $_SESSION variables.

I have the database information, the result of DB::connect saved in $db. I am trying to set $_SESSION['db'] = $db, which works. When I go to submit a form and pass the session id the object in $_SESSION gets cut short and I get the following error: PHP_Incomplete_Class Object and
Fatal error: Unknown(): The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition db_mysql of the object you are trying to operate on was loaded _before_ the session was started

Is there a better way to pass the db object between php pages after submitting a form?

-Jessica






Similar Threads
Thread Thread Starter Forum Replies Last Post
begin php & mysql - chapter 12, user_form.php jon_stubber Beginning PHP 1 March 9th, 2006 10:57 AM
MySQL Config Problems socoolbrewster MySQL 2 September 1st, 2005 06:09 PM
jsp, mysql, cocoon and many other problems ;o) elsylo JSP Basics 0 October 23rd, 2004 09:40 AM
problems installing php and mySQL mjmadick Beginning PHP 1 July 26th, 2004 02:46 AM
connect to mysql problems Deuce868 JSP Basics 1 March 7th, 2004 10:50 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.