Parse error using localhost/webauction-0.3.5 as adress

A place to discuss and receive support for the Web Auction application.

Parse error using localhost/webauction-0.3.5 as adress

Postby jaspern89 » Wed Mar 17, 2010 6:04 am

Parse error: syntax error, unexpected ':' in C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Application.php on line 216

This is the error I get when I try in my web browser.

This is what I got in my "Application.php" under line 216:

function Dataface_Application($conf = null){
$this->_baseUrl = $_SERVER['PHP_SELF'];
if ( !is_array($conf) ) $conf = array();
if ( is_readable(DATAFACE_SITE_PATH.'/conf.ini') ){
$conf = array_merge(parse_ini_file(C:\xampp\htdocs\webauction-0.3.5.'/conf.ini', true), $conf);
}

Have I typed in the wrong path to the database conf.ini file?
I've configured everything in the Install.php instructions, but I'm unsure what I have to type as path under line 216.

I'm using MySQL client version: 5.0.67

Any help would be appriciated.


Thanks
Jaspern
jaspern89
 
Posts: 11
Joined: Wed Mar 17, 2010 5:54 am

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby jaspern89 » Thu Mar 18, 2010 1:29 am

Now I have fixed the path, so it is now:

function Dataface_Application($conf = null){
$this->_baseUrl = $_SERVER['PHP_SELF'];
if ( !is_array($conf) ) $conf = array();
if ( is_readable(DATAFACE_SITE_PATH.'/conf.ini') ){
$conf = array_merge(parse_ini_file('C:\xampp\htdocs\webauction-0.3.5\conf.ini', true), $conf);
}

I now get the error:

Fatal error: Error performing mysql query to get column information from table 'products'. The mysql error returned was : 'Table 'jotronpcauction.products' doesn't exist'.
On line 467 of file C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Table.php in function printStackTrace()
On line 2206 of file C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Table.php in function Dataface_Table(products,Resource id #14,)
On line 766 of file C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Application.php in function loadTable(products)
On line 1441 of file C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Application.php in function handleRequest()
On line 23 of file C:\xampp\htdocs\webauction-0.3.5\index.php in function display()
in C:\xampp\htdocs\webauction-0.3.5\dataface\Dataface\Table.php on line 467

I've checked the dataface\Dataface\Table.php file under line 467 and this is what I get:

trigger_error("Error performing mysql query to get column information from table '".$this->tablename."'. The mysql error returned was : '".mysql_error($this->db)."'.\n<br>".Dataface_Error::printStackTrace(), E_USER_ERROR);
}

Do I have to create a table and how?
I'm kinda new at the scripting, and have never done this before, but trying :D


- Jaspern
jaspern89
 
Posts: 11
Joined: Wed Mar 17, 2010 5:54 am

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby shannah » Thu Mar 18, 2010 2:11 am

The error indicates that the products table is missing. You should probably check to make sure that the tables installed correctly.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby jaspern89 » Thu Mar 18, 2010 2:45 am

shannah wrote:The error indicates that the products table is missing. You should probably check to make sure that the tables installed correctly.
When I'm in PHPMyAdmin I can see 4 tables: Bids, Closed, Config and Dataface__version installed.

Can you tell me how I can install the products table or is it any file I must edit?
So my question is, do I have to edit something in the table.php? I have not touched the table.php file yet.


- Jaspern
jaspern89
 
Posts: 11
Joined: Wed Mar 17, 2010 5:54 am

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby shannah » Thu Mar 18, 2010 7:41 am

You don't have to edit any more files. Looks like there was a problem installing the database. Delete all of the tables. Then run the SQL contained in install/install.sql again in your database.
shannah
 
Posts: 4457
Joined: Wed Dec 31, 1969 5:00 pm

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby jaspern89 » Fri Mar 19, 2010 4:22 am

shannah wrote:You don't have to edit any more files. Looks like there was a problem installing the database. Delete all of the tables. Then run the SQL contained in install/install.sql again in your database.
Thanks for the tip!
Now I got these tables: jotronpcauction.bids, jotronpcauction.config, jotronpcauction.dataface__version, jotronpcauction.products, jotronpcauction.product_categories and jotronpcauction.users.

Now I get these error messages.

Code: Select all
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\include\functions.inc.php on line 204

Fatal error: Error performing mysql query to get column information from table 'config'. The mysql error returned was : 'Table 'jotronpcauction.config' doesn't exist'.
On line 467 of file C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\dataface\Dataface\Table.php in function printStackTrace()
On line 2206 of file C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\dataface\Dataface\Table.php in function Dataface_Table(config,Resource id #14,)
On line 192 of file C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\dataface\Dataface\Record.php in function loadTable(config)
On line 223 of file C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\dataface\dataface-public-api.php in function Dataface_Record(config,array())
On line 209 of file C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\include\functions.inc.php in function df_get_record(config,array())
On line 149 of f in C:\Documents and Settings\Jaspreet\My Documents\xampp\htdocs\jotronpcauction\dataface\Dataface\Table.php on line 467


I'm using XAMPP 1.7.1 wich have worked before.
Here is some info of wich system I am running:

Code: Select all
MySQL

    * Server: localhost via TCP/IP
    * Server version: 5.1.33-community
    * Protocol version: 10
    * User: root@localhost
    * MySQL charset: UTF-8 Unicode (utf8)

Web server

    * Apache/2.2.11 (Win32) DAV/2 mod_ssl/2.2.11 OpenSSL/0.9.8i PHP/5.2.9
    * MySQL client version: 5.0.51a
    * PHP extension: mysql

phpMyAdmin

    * Version information: 3.1.3.1
jaspern89
 
Posts: 11
Joined: Wed Mar 17, 2010 5:54 am

Re: Parse error using localhost/webauction-0.3.5 as adress

Postby jaspern89 » Fri Mar 19, 2010 4:43 am

Nevermind, I got it fixed by importing the original install.sql file now.

Thanks for all the help anyways.
If you had not told me to delete all the tables, I could not fix this :D


Thanks
Jaspern
jaspern89
 
Posts: 11
Joined: Wed Mar 17, 2010 5:54 am


Return to Web Auction Discussion

Who is online

Users browsing this forum: No registered users and 20 guests

cron
Powered by Dataface
© 2005-2007 Steve Hannah All rights reserved