Database Errors

Get help with installation and running phpwcms here. Please do not post bug reports or feature requests here.
Post Reply
master811
Posts: 8
Joined: Fri 24. Mar 2006, 11:17
Location: UK

Database Errors

Post by master811 »

I currently have the following errors at the top of one of the pages of my site and have no idea why or how they are there as its only on one page.

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\front.func.inc.php on line 659

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\front.func.inc.php on line 660

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\content.func.inc.php on line 126

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\front.func.inc.php on line 790

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\content.func.inc.php on line 256

Notice: Undefined offset: 22 in D:\Telstra\include\inc_front\content.func.inc.php on line 260


Anyone have any ideas what the errors mean or how I can fix them.

The page seems to be functioning ok apart from this, so not sure what it could be.

Thanks
User avatar
Klappstuhl28
Posts: 833
Joined: Fri 4. Mar 2005, 01:58
Location: Hamburg
Contact:

Post by Klappstuhl28 »

Have ever changed something in the front.... -file?
Maybe there´s something wrong with serverside settings
"D:\"

D:\Telstra\include\inc_front\front.func.inc.php on line 659

Have you checked the code in this lines?

Lars
Lars

Don't say you don't have enough time. You have exactly the same number of hours per day that were given to Helen Keller, Pasteur, Michaelangelo, Mother Teresa, Leonardo da Vinci, Thomas Jefferson, and Albert Einstein. - H. Jackson Brown -
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Post by DeXXus »

edit "php.ini" :wink:
to turn off NOTICEs:
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Error handling and logging ;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

; error_reporting is a bit-field. Or each number up to get desired error
; reporting level
; E_ALL - All errors and warnings (doesn't include E_STRICT)
; E_ERROR - fatal run-time errors
; E_WARNING - run-time warnings (non-fatal errors)
; E_PARSE - compile-time parse errors
; E_NOTICE - run-time notices (these are warnings which often result
; from a bug in your code, but it's possible that it was
; intentional (e.g., using an uninitialized variable and
; relying on the fact it's automatically initialized to an
; empty string)
; E_STRICT - run-time notices, enable to have PHP suggest changes
; to your code which will ensure the best interoperability
; and forward compatibility of your code
; E_CORE_ERROR - fatal errors that occur during PHP's initial startup
; E_CORE_WARNING - warnings (non-fatal errors) that occur during PHP's
; initial startup
; E_COMPILE_ERROR - fatal compile-time errors
; E_COMPILE_WARNING - compile-time warnings (non-fatal errors)
; E_USER_ERROR - user-generated error message
; E_USER_WARNING - user-generated warning message
; E_USER_NOTICE - user-generated notice message
;
; Examples:
;
; - Show all errors, except for notices and coding standards warnings
;
error_reporting = E_ALL & ~E_NOTICE
Nik2004
Posts: 132
Joined: Mon 9. Aug 2004, 14:31
Location: Athens,Greece

Post by Nik2004 »

If I don't have access to php.ini, what can I do to control reporting??
User avatar
DeXXus
Posts: 2168
Joined: Fri 28. Nov 2003, 06:20
Location: USA - Florida

Post by DeXXus »

Create a "php.ini" file in your phpWCMS root folder and add that as an entry in the file!
User avatar
Oliver Georgi
Site Admin
Posts: 9889
Joined: Fri 3. Oct 2003, 22:22
Contact:

Post by Oliver Georgi »

which version of phpwcms.

And check if you use link to menu which does not exist anymore.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
Nik2004
Posts: 132
Joined: Mon 9. Aug 2004, 14:31
Location: Athens,Greece

Post by Nik2004 »

Thank you for your replies. I am now using v1.3.3.

What I understand follows. Please confirm, because I am not sure: If my root folder is /httpdocs/siterootfolder I create a php.ini with a single entry (error_reporting = E_ERROR) and I place it in /httpdocs/siterootfolder . Right?

Can I put any other php.ini directives in there to override the default values? No reference in the phpwcms files is needed?

I am afraid I don't understand the hint "check if you use link to menu which does not exist anymore". Could you please make it clearer?
User avatar
Oliver Georgi
Site Admin
Posts: 9889
Joined: Fri 3. Oct 2003, 22:22
Contact:

Post by Oliver Georgi »

if you are really use 1.3.3 - you would not see any of such error message in the given line of front.func.inc.php. For me it looks like you have patched your system.

And you are using Windows - forget hints regarding php.ini at the moment. Be sure to have webserver setup well.

Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
Nik2004
Posts: 132
Joined: Mon 9. Aug 2004, 14:31
Location: Athens,Greece

Post by Nik2004 »

I hope you are not getting confused with the above messages. I am not getting such errors. I just found this thread and I thought I should continue it to find how to suppress error messages. My own errors have been resolved (see here: http://www.phpwcms.de/forum/viewtopic.php?t=14627) but I still want to be able to handle any possible future errors or warnings by proper error control.

The server is linux and 1.3.3 is working fine now. (I still have some problems, reported in other threads).
User avatar
Oliver Georgi
Site Admin
Posts: 9889
Joined: Fri 3. Oct 2003, 22:22
Contact:

Post by Oliver Georgi »

I was very confused...

You can always open default.inc.php and after:

Code: Select all

@ini_set( 'arg_separator.output' , '&' );
put in

Code: Select all

error_reporting(0);
More see here:
http://www.php.net/manual/function.error-reporting.php


Oliver
Oliver Georgi | phpwcms Developer | GitHub | LinkedIn | Систрон
Post Reply