Results 1 to 7 of 7

Thread: [Resolved] ***? Global problem...

Threaded View

  1. #1

    Thread Starter
    Stuck in the 80s The Hobo's Avatar
    Join Date
    Jul 2001
    Location
    Michigan
    Posts
    7,256

    [Resolved] ***? Global problem...

    I'm doing this sort of thing in numerous scripts, however, in ONE FILE, it's not working.

    Here's a condensed version of the code:

    Code:
    <?php
    
        $CONFIG['absolute_path'] = '/home/vbshelf/public_html/reality/news/';
        //config.php simply loads some variables from a database
        //into the $CONFIG array:
        include $CONFIG['absolute_path'] . 'config.php';
    
        echo $CONFIG['numitems'] . '<br>'; //WORKS!
    
        function _news($cat = '') {
            global $CONFIG;
            
            echo $CONFIG['numitems'] . '<br>'; //DOESN'T WORK?
        }
    
    ?>
    What gives?!
    Last edited by The Hobo; Aug 17th, 2003 at 09:44 PM.
    My evil laugh has a squeak in it.

    kristopherwilson.com

Posting Permissions

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



Click Here to Expand Forum to Full Width