Jump to content

Very peculiar behaviour with wire('pages');


joe_g
 Share

Recommended Posts

So I ran into this peculiarity: If I put this piece of code at the end of my 'util.php' (included first on my head.php) — then things work:

<?
    function totallyRandomFunctionName() {
        /* wire('pages');*/
    }
?>

Note how wire('pages') is commented out, but it still somehow does the job.

Now, if I remove the commented line:
 

<?
    function totallyRandomFunctionName() {
        
    }
?>
Then I get this error earlier in util.php, suddenly the wire function isn't existing...:
Uncaught Error: Call to undefined function wire() in /xx/util.php:86

Line 86 has: "wire('config')->urls->root" in it.

I'm quite curious what goes on here!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...