Find the answer to your Linux question:
Results 1 to 2 of 2
I am wondering what would be the equivalent to $0 for php just to get a quick answer from someone who knows php, $0 is the shell scripting variable that ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Apr 2009
    Posts
    11

    php and $0


    I am wondering what would be the equivalent to $0 for php

    just to get a quick answer from someone who knows php, $0 is the shell scripting variable that gets
    the scripts name

  2. #2
    Just Joined! manicanet's Avatar
    Join Date
    Nov 2009
    Posts
    11
    The safest way to do it is:
    Code:
    $phpself = basename(__FILE__);

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •