The Cache: Technology Expert's Forum
 
*
Welcome, Guest. Please login or register. September 23, 2019, 06:06:26 AM

Login with username, password and session length


Pages: [1]
  Print  
Author Topic: PHP Notice: Undefined variable:  (Read 2448 times)
BlackSwan
n00b
*
Offline Offline

Posts: 6


View Profile
« on: June 25, 2010, 03:37:19 PM »

Ok guys, I have a madlib script I wrote myself.  It works at infinite levels deep and has as synonym replacer in conjunction.   It can also replace and switch out paragraphs. Back links and anchor text are pulled from a file.

I can't paste the entire code because it uses a bunch of includes and it is just to much shit to post in a forum.  If you want a place on the web where you can download the zip file, let me know. 

Where the problem comes in...When I initially wrote the program it worked perfect under the CLI of  HardyHeron.  I just upgraded to LucidLynx and now I'm getting errors when I try and run the program.

Examples of the errors:
Quote
noble@thinkpad:~$ cd PHP/madlib
noble@thinkpad:~/PHP/madlib$ ./working.php
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0

PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32

PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32

PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: sub in /home/noble/PHP/madlib/functions.inc.php on line 119
PHP Notice:  Undefined variable: sub2 in /home/noble/PHP/madlib/functions.inc.php on line 111
PHP Notice:  Undefined variable: atom in /home/noble/PHP/madlib/functions.inc.php on line 32


Now first of all I don't have any comments starting with "#" except for what I put on the top of the page to run the program from the CLI i.e. #!/usr/bin/php

And 2nd I thought you did not have to define variables before you use them as apposed to other languages. 

If it would help, I can post all of "functions.inc.php" or send it to you.

Thanks
« Last Edit: June 25, 2010, 03:46:25 PM by BlackSwan » Logged

No links in signatures please
BlackSwan
n00b
*
Offline Offline

Posts: 6


View Profile
« Reply #1 on: June 25, 2010, 03:43:25 PM »

I understand there are ways to suppress the errors in the php.ini file,  but I'd really like to know what is wrong with my code.

Thanks!
Logged

No links in signatures please
Phaėton
Lifer
*****
Offline Offline

Posts: 555


⎝⏠⏝⏠⎠


View Profile
« Reply #2 on: June 25, 2010, 07:15:13 PM »

Where can we download the file?

This happened to me on a server where i was doing something like:

$outstr.='append this to the varible';

but i hadnt done :

$outstr='';

first.


used to not throw an error in a different environment but now it does...
Logged

When I was your age we used to walk to the TV to change the channel....  _̴ı̴̴̡̡̡ ̡͌l̡̡̡ ̡͌l̡*̡̡ ̴̡ı̴̴̡ ̡̡͡|̲̲̲͡͡͡ ̲▫̲͡ ̲̲̲͡͡π̲̲͡͡ ̲̲͡▫̲̲͡͡ ̲|̡̡̡ ̡ ̴̡ı̴̡̡
perkiset
Olde World Hacker
Administrator
Lifer
*****
Offline Offline

Posts: 10096



View Profile
« Reply #3 on: June 25, 2010, 11:26:48 PM »

Nothing wrong with your code.

do this:
error_reporting(E_ERROR);

and that will go away. Those are notices, not even warnings. It's perfectly fine to use variables that are previously undefined.

Logged

It is now believed, that after having lived in one compound with 3 wives and never leaving the house for 5 years, Bin Laden called the U.S. Navy Seals himself.
BlackSwan
n00b
*
Offline Offline

Posts: 6


View Profile
« Reply #4 on: June 26, 2010, 09:03:41 AM »

Thanks, Perk your solution worked!  However, I was still getting the error:
Quote
PHP Deprecated:  Comments starting with '#' are deprecated in /etc/php5/cli/conf.d/mcrypt.ini on line 1 in Unknown on line 0
A quick Google search pulled up this https://bugs.launchpad.net/ubuntu/+source/php-mcrypt/+bug/540208
And that fixed that problem so everything is working perfect now.

However, I still have an older version of Ubuntu on an old box and I'd like to compare the php.ini file with the newest version. If I can solve this issue globally instead of putting error_reporting(E_ERROR); in all my shit scripts, I'll post the results here just in-case anyone else has the same problems.
Logged

No links in signatures please
perkiset
Olde World Hacker
Administrator
Lifer
*****
Offline Offline

Posts: 10096



View Profile
« Reply #5 on: June 26, 2010, 05:27:32 PM »

This might help: http://php.net/manual/en/errorfunc.configuration.php
Logged

It is now believed, that after having lived in one compound with 3 wives and never leaving the house for 5 years, Bin Laden called the U.S. Navy Seals himself.
herbacious
Journeyman
***
Offline Offline

Posts: 51


View Profile
« Reply #6 on: August 04, 2010, 02:31:42 PM »

you know what - i turned my error reporting up to the max, and then used a custom error handler to turn even the slightest error into an exception

that then gives me a detailed stack trace so I can easily figure out whats gone wrong

since then, although im fixing fairly nit picking notices etc, the code is proving to be a lot more stable and takes less time to fix bigger errors
Logged
perkiset
Olde World Hacker
Administrator
Lifer
*****
Offline Offline

Posts: 10096



View Profile
« Reply #7 on: August 04, 2010, 05:40:26 PM »

Yeah man. The nested exception structure of PHP is pretty good, that is the way to go.
Logged

It is now believed, that after having lived in one compound with 3 wives and never leaving the house for 5 years, Bin Laden called the U.S. Navy Seals himself.
Pages: [1]
  Print  
 
Jump to:  

Perkiset's Place Home   Best of The Cache   phpMyIDE: MySQL Stored Procedures, Functions & Triggers
Politics @ Perkiset's   Pinkhat's Perspective   
cache
mart
coder
programmers
ajax
php
javascript
Powered by MySQL Powered by PHP Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC
Seo4Smf v0.2 © Webmaster's Talks


Valid XHTML 1.0! Valid CSS!