|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #24730 Error in ""
Submitted: 2003-07-20 16:15 UTC Modified: 2003-07-20 16:57 UTC
From: matosale at yahoo dot com Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS: WindowsXP
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please !
Your email address:
Solve the problem:
9 + 34 = ?
Subscribe to this entry?

 [2003-07-20 16:15 UTC] matosale at yahoo dot com
In the spanish version says:

<?php echo $_SERVER["HTTP_USER_AGENT"]; ?

and it doesn't work. A friend of mine says that it should be like this:

<?php echo $HTTP_USER_AGENT ?>

when i put it like this it did work :o)

Reproduce code:
<?php echo $_SERVER["HTTP_USER_AGENT"]; ?

Expected result:
Opera/7.11 (Windows NT 5.1; U) [es-ES]

Actual result:


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-07-20 16:25 UTC]
You are probably not using a version of PHP that has superglobals ( < 4.1.0).  Upgrade!
 [2003-07-20 16:57 UTC]
And from that page, immediatly above the quoted example:

Notas acerca de PHP Autoglobals:  $_SERVER es una variable reservada por PHP que contiene toda la informaci?n del servidor de web. Es conocida como Autoglobal (o Superglobal). Lee el manual en la secci?n titulada Autoglobals para mas informaci?n. Estas son variables especiales que son introducidas en la versi?n 4.1.0 de PHP. Antes pod?amos usar los, $HTTP_*_VARS arrays, tales como $HTTP_SERVER_VARS. Aunque estos han sido despreciados, estas antiguas variables todav?a existen. (Tambi?n puedes mirar las notas relacionadas acerca del viejo c?digo.)
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sat Oct 16 04:03:33 2021 UTC