Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2005-07-28 00:15:56

zem
Developer Emeritus
From: Melbourne, Australia
Registered: 2004-04-08
Posts: 2,579

"Notice: undefined variable.." and similar messages

When your Production Status is set to Debugging, it’s not uncommon to see PHP Notices similar to this:

Notice: Undefined index: permlink in …/textpattern/lib/txplib_misc.php(412) : eval()’d code on line 26

Debugging mode is intended for just that: debugging problems. If everything is working fine, there’s no reason to turn on Debugging.

Notices in debug mode are not unusual, and by themselves aren’t an indicator of something wrong. If the only symptom you have is that there are notices produced when Production Status is set to Debugging, then there’s nothing wrong, and you can safely ignore them.

By itself, with no other symptoms, a Notice is not a bug, so please don’t report it as such.

On the other hand, if something is failing to work, the messages produced in debug mode might be helpful in tracking down the source of the problem.


Alex

Offline

#2 2005-07-28 07:02:25

Skubidu
Archived Plugin Author
Registered: 2004-10-23
Posts: 611
Website

Re: "Notice: undefined variable.." and similar messages

What if one gets notices in produciton status “live” (as I do)?

Offline

#3 2005-07-28 14:14:01

starzabove
Member
Registered: 2004-04-13
Posts: 76

Re: "Notice: undefined variable.." and similar messages

Ditto here.
I’ll put the details in a bug report, but on deanload RC4, status Live, I’m getting this error for everyone except Publishing Editor in certain situations:

<code>
textpattern content presentation admin extensions view site

Warning: Invalid argument supplied for foreach() in /home/athomere/public_html/textpattern/lib/txplib_head.php on line 140

Notice: Undefined variable: out in /home/athomere/public_html/textpattern/lib/txplib_head.php on line 143

Warning: join(): Bad arguments. in /home/athomere/public_html/textpattern/lib/txplib_head.php on line 143

Restricted area
</code>

Thanks.

Last edited by starzabove (2005-07-28 14:20:29)


90+ Textpattern installs and still going…

Offline

#4 2005-07-28 14:41:22

Sencer
Archived Developer
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: "Notice: undefined variable.." and similar messages

A Warning is different from a notice. And given that both of you guys are not on status Live, this thread doesn’t apply to you. If you see stuff on live, try turning off plugins, and if you are still seeing stuff, then file a bug-report – though it is likely that something went wrong during the update…

But let’s not discuss other issues in this thread.

Offline

#5 2005-07-28 20:14:12

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: "Notice: undefined variable.." and similar messages

Remember that the admin is always set to ‘debug’.

Offline

#6 2005-07-28 22:47:36

zem
Developer Emeritus
From: Melbourne, Australia
Registered: 2004-04-08
Posts: 2,579

Re: "Notice: undefined variable.." and similar messages

What if one gets notices in produciton status “live” (as I do)?

Sorry about that – the error level was set higher than it should have been during initialization. Fixed in rev 654.


Alex

Offline

#7 2005-09-22 22:19:48

richards
Member
From: Johnson City, TN
Registered: 2005-01-30
Posts: 10
Website

Re: "Notice: undefined variable.." and similar messages

Hey I’m set to status “live” using build Textpattern version: 4.0.1 (r895)
I’m getting this notice when I login to the admin: Notice: Undefined index: view in /home/someuserfolder/public_html/textpattern/lib/txplib_misc.php(429) : eval()’d code on line 64

Last edited by richards (2005-09-22 22:20:24)

Offline

#8 2005-09-23 03:06:35

ubernostrum
Member
From: Lawrence, KS
Registered: 2004-05-05
Posts: 238
Website

Re: "Notice: undefined variable.." and similar messages

No matter what your production status is set to, notices, warnings and errors always show up if they happen in the admin interface. Changing the production status only affects whether they show up on the public part of the site.


You cooin’ with my bird?

Offline

#9 2007-05-16 22:49:40

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: "Notice: undefined variable.." and similar messages

Offline

#10 2007-05-17 00:20:03

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: "Notice: undefined variable.." and similar messages

a Notice is not a bug, so please don’t report it as such.

I’d say a notice is a potential bug and should be investigated and fixed for that reason. Not fixed by suppressing the notice, but by removing the cause. This doesn’t guarantee bug free code, but it can help to detect subtle bugs that might otherwise be overlooked and that improves the quality of the software, IMHO.

Offline

#11 2007-09-14 07:29:25

markusfalk
Member
Registered: 2007-08-16
Posts: 57
Website

Re: "Notice: undefined variable.." and similar messages

I still don’t quite grasp what I need to do when I get a Notice on my frontend while in Live mode. Is it possible to suppress the output? I’m using 4.0.4. and I get “Notice: error_article_context in … txplib_misc.php” on all my error pages.


I sometimes destructively reverse engineer my own work and the only help is this forum.

visit me at visiongraphix

Offline

#12 2007-09-14 08:44:35

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: "Notice: undefined variable.." and similar messages

See FAQ and FAQ

Offline

Board footer

Powered by FluxBB