globally accessing variable in php

Discussion in 'Web Design, HTML And CSS' started by deepakagrawal, Apr 13, 2007.

  1. deepakagrawal

    deepakagrawal New Member

    Joined:
    Apr 13, 2007
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    0
    Hello,
    I am deepak, i am desiging a website on php, so on can i make a variable in such a way so thai i can access that variable on other file, such as when we declare a extern variable in 'c' and we can access on other file ....
    So pls tell me can i do same as on "php".
    Thanks
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,375
    Likes Received:
    388
    Trophy Points:
    83
    use the global $Varname and you will get the variable in the other file
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice