Hi. 🙂
I'm currently need to write a small piece of code that performs a check on every page of a forum (placed in the header file).
Ok, that part is straight forward.
The idea is if a registered forum user does not have a character created in the forum game, the script redirects the user to a message notifying them and then when they click 'OK' it sends them straight to the "character.php" file which allows them to create a character.
Everything works fine except when it tries to load the "character.php" file because the check in the header keeps looping back to the notification message rather than loading the character creation screen.
What I need to do is somehow grab the current URL so the check occurs on every page BUT this: "http://www.mydomain.com/character.php" to enable the character creation.
Is there a function available that can grab the full URL so it can then search for "character.php" and subsequently exclude it from the if statement or if not found in the URL proceed with the script.
Hope this makes sense.
Any help would be greatly apprieciated. 🙂