473,569 Members | 2,522 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

A question on predefined variables

My apologies if my question sounds childish. Please explain the
following code to me. I found it at the beginning of a script.

if (isset($_REQUES T['GLOBALS']) OR isset($_FILES['GLOBALS']))
{
echo 'Request tainting attempted.';
exit;
}

Also, I'll be very grateful if someone can suggest me a good reference
on predefined variables. (The one included in PHP Manual didn't help
much.)

Thanks a lot.

Oct 2 '06 #1
1 1392

Le Poisson wrote:
My apologies if my question sounds childish. Please explain the
following code to me. I found it at the beginning of a script.

if (isset($_REQUES T['GLOBALS']) OR isset($_FILES['GLOBALS']))
{
echo 'Request tainting attempted.';
exit;
}

Also, I'll be very grateful if someone can suggest me a good reference
on predefined variables. (The one included in PHP Manual didn't help
much.)

Thanks a lot.
Its saying if $globals has a value then exit the script, ie. its trying
to prevent people from setting values themselves.. google has many
great php resources.

Flamer.

Oct 2 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1745
by: poisondart | last post by:
Is there a predefined entity set for Spanish accents? I know that I could just easily make one, except that I intend to do this for other languages in the future, which may have more accents than Spanish. The closest to what I was expecting was this link: http://www.altheim.com/specs/charents.html ....but the link to the ent file is...
3
509
by: lovecreatesbeauty | last post by:
Predefined class member functions and inheritance How many member functions on earth can be provided (predefined) by standard-compliant compilers? Scott Meyers says that there are 6: (1)default constructor, (2)copy constructor, (3)destructor, (4)assignment operator, (5)address-of operator (non-const), (6)address-of operator (const),...
4
1845
by: lovecreatesbeauty | last post by:
How many member functions will be predefined (provided by compilers implicitly) and called by standard-compliant compilers for a class? Does such a list be given in iso/iec 14882? Which member functions of a base class won't be inherited by derived class? Do all the member functions of a base class predefined by standard-compliant...
6
2708
by: J.G.Harston | last post by:
I've been trying to track down explicit information about this for some time. I know that the ANSI C standard specifies the __* and _* macro namespace as reserved for the compiler implementation, and playing with a handful of compilers I can find what those specific compilers predefine, but is there any information out there on how that...
5
12811
by: ampeloso | last post by:
Hello, I would like to allocte memory, but I want it to start at a predefined address. I have a program that writes data to ROM in an embedded device and I would like to state where it goes. Can this be done and how? Thanks Mike
5
7210
by: iwl | last post by:
Hi, is there an predefined empty base class which I can instanziate to have an container i can copy attributes in?
2
4460
by: merkury1 | last post by:
Does C# have any predefined preprocessor constants like the C/C++ compiler does? In C++ you had such predefined constants as: __cplusplus, _DEBUG, _WIN32, MSC_VER. Are there any such things for C#? It would be nice if there were some for .Net version (1 or 2), compact framework or full framework, etc. Thanks. Randy Beckwith
0
1319
by: im20 | last post by:
I am helping a polish up a client's PPC campaign and when of the problems I have run into is that the real estate backend system he is using, does not allow the ability to link directly to a predefined search. Say for a city. You have to use a form to get anything out of the system in return. You can link directly to a listing but not a search. ...
2
2687
by: =?windows-1252?Q?=22=C1lvaro_G=2E_Vicario=22?= | last post by:
Is there any way to tell PHP predefined variables ($GLOBALS, $argv, $argc, $_GET, $_POST…) from *global* user-defined variables? Neither $GLOBALS nor get_defined_vars() put user data apart. I’m writing a class to generate PHP definition files for syntax highlighting with two features: 1. It takes data from current install (e.g., you get...
0
7701
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7615
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7924
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
1
7677
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7979
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6284
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
3643
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2115
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1223
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.