logo-img
  • Home
  • Tutorials
  • Refer and Earn
  • Courses
    • Courses

      AWS
      • AWS Solutions Archit... 60 Section
      Office 365
      • Office 365 System Ad... 27 Section
      Azure
      • Azure (AZ-900) Fund... 10 Section
      • Azure Administrator... 47 Section
      • Azure DevOps (AZ-400... 11 Section
      • AZ-104 Microsoft Azu... 17 Section
      • Getting started with... 7 Section
      Windows Administration
      • Windows Server Admin... 14 Section
      CCNA (200-301) : Routing & Swi...
      • CCNA (200-301) : Rou... 44 Section
      ITILv4- IT Service Management...
      • ITILv4-IT Service Ma... 8 Section
      Ethical Hacking: Cyber Securit...
      IT OJT Internship
      • IT Internship (Engli... 8 Section
      • IT OJT Internship (H... 7 Section
      Python Scripting with AI
      • Python Scripting wit... 4 Section
      DevOps
      • Mastery in Dockers:... 4 Section
      • The Git & Github Boo... 10 Section
      • PowerShell: Script &... 13 Section
      • Jenkins: Jobs, Pipel... 3 Section
      Ethical Hacking (Hindi)
      • Ethical Hacking (Hin... 10 Section
      Digital Marketing
      • Fundamentals of Digi... 1 Section

      Role-Based

      Network Security Engineer3 courses
      Cloud Engineer0 courses
      DevOps Engineer0 courses
      System Engineer0 courses
      SOC Analyst0 courses
      Network Engineer0 courses
  • Internships
    • Internships

      IT Internship(Live)
      Graphic Designing & Video Editing
      Campus Job Internship Program
      Digital Marketing
  • Corporate Training
    • Corporate Training

      AWS + Devops
      Azure + DevOps
      CCNA 200-301
      Devops
      FULL STACK WEB DEVELOPMENT
      UX/UI Design- Complete Figma Bootcamp
      HR Internship - Skills & Competencies
  • Placements
  • Teach with Evision
Login/Register
Student Login Student Login Faculty Login
  • HTML
  • CSS
  • JavaScript
  • SQL
  • News
  • PHP
  • PHP Overview
  • PHP MySQL
  • Static Methods
  • Static Properties
  • Superglobals
  • $GLOBALS
  • $_SERVER
  • $_REQUEST
  • $_POST
  • $_GET
  • $_COOKIE
  • $_SESSION
  • Traits
  • Connecting to MySQL
  • Creating a MySQL Database
  • Creating Table in MySQL
  • Inserting Data in MySQL
  • Selecting Data in MySQL
  • Updating Data in MySQL
  • Deleting Data in MySQL
  • Include & Require
  • File Handling
  • Arrays
  • PHP Comments
  • Variables in PHP
  • Variable Scope
  • PHP DataTypes
  • PHP Operators
  • PHP Conditional Statements
  • PHP Iterative Statements
  • PHP Function
  • Function Arguments
  • OOPS
  • Classes
  • Objects
  • Inheritance
  • Constructors and Destructors
  • Access Modifiers
  • Interface
  • Abstract Classes
  • Class Constants

$GLOBALS

$GLOBALS is a superglobal variable, which is also an array that stores all the global scope variables and is used to access global variables from anywhere in the PHP program.

Example:

<?php
$x = 10;
$y = 11;

function add() {
 $GLOBALS['z'] = $GLOBALS['x'] + $GLOBALS['y'];
}

add();
echo $z;
?>

Output:

21

Previous Next

Site Links

  • Home
  • About
  • Corporate Training
  • Internships
  • Success Corner
  • Contact Us

Useful Links

  • Terms of Use
  • Privacy Policy
  • Refund Policy

Stay up to date

Contact Details

Gaur city Mall, Greater Noida, West Uttar Pradesh 201009.

+91 9811 722 064
info@evisiontechnoserve.com
  • Copyright © 2025 Evision. All Rights Reserved.
Referral Promo
Share Knowledge, Spark Success

Refer a friend to our services and get earnings on your next service. Hurry, this offer won’t be around forever – it’s just a fleeting referral-tunity.

Login

OTP sent successfully!

Resend OTP

Referral Promo
Login by Student

OTP sent successfully!

Resend OTP
Login by Faculty