php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #18202 suppressing errors with "@"
Submitted: 2002-07-06 17:24 UTC Modified: 2002-07-06 17:26 UTC
From: webmaster at speedy dot co dot il Assigned:
Status: Not a bug Package: Unknown/Other Function
PHP Version: 4.1.2 OS: Red Hat Linux 7.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: webmaster at speedy dot co dot il
New email:
PHP Version: OS:

 

 [2002-07-06 17:24 UTC] webmaster at speedy dot co dot il
Hi,

I tried to suppress warnings in isset expressions (Uninitialized string offset warnings).  The original line was something like this:

if (!(isset($GLOBALS['SPEEDY_GLOBAL_VARS']['PAGE_NAME'])))

When I added the "@" sign like this:

if (!(isset(@$GLOBALS['SPEEDY_GLOBAL_VARS']['PAGE_NAME'])))

My program stopped working, and I got errors like:

PHP Parse error:  parse error, expecting `T_VARIABLE' or `'$'' ....

Eventually, I put the "@" in this place:

if (!(@isset($GLOBALS['SPEEDY_GLOBAL_VARS']['PAGE_NAME'])))

Which works, but why didn't it work the other way?  Is it some kind of PHP bug?

I'm using PHP Version 4.1.2

Thanks,

Uri Even-Chen
Speedy Software
Raanana, Israel.
--------------------------------------------------------
Welcome to Speedy Net (In Hebrew):
   http://www.speedy.co.il/
Speedy Dating (In Hebrew):
   http://dating.speedy.co.il/
Speedy Composer (In English):
   http://www.speedy.co.il/composer/
--------------------------------------------------------

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-07-06 17:26 UTC] derick@php.net
Sorry, but the bug system is not the appropriate forum for asking
support questions. Your problem does not imply a bug in PHP itself.
For a list of more appropriate places to ask for help using PHP,
please visit http://www.php.net/support.php

Thank you for your interest in PHP.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 16:01:30 2024 UTC