Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 9 of 9

Thread: HTTP-Status

  1. #1
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts

    HTTP-Status

    hi guys need help!

    function i want to use:
    Code:
    http://darklaunch.com/2010/09/01/http-status-codes-in-php-http-header-response-code-function
    i want to initially use
    Code:
    content/system_error.php h
    mm wandering; should i add the said func to:
    generic.func.php an then call it as
    Code:
    HTTPStatusError();

  • #2
    Senior Coder
    Join Date
    Feb 2011
    Location
    Your Monitor
    Posts
    4,090
    Thanks
    51
    Thanked 506 Times in 493 Posts
    I don't think it matters where you add it as long as the code is in your project somewhere.

    Seeing as we know nothing about your project, there isn't much we can do to help really in the way of advice.
    My helpful sig is on vacation trying to loose some weight. It got a bit fat and caused a few problems but it will be back at some point!

  • #3
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts
    Well it's an image script...

    What do u need to kno m8?

  • #4
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts
    Hi

    imgettting

    Warning: Missing argument 1 for HTTPStatus()

    what?

  • #5
    Senior Coder
    Join Date
    Feb 2011
    Location
    Your Monitor
    Posts
    4,090
    Thanks
    51
    Thanked 506 Times in 493 Posts
    Quote Originally Posted by Chris-2k View Post
    Well it's an image script...
    Erm, no. The code at that url is for http status's. It's nothing to do with images unless you mean your script is an image script (things like that you should have mentioned).

    Quote Originally Posted by Chris-2k View Post
    What do u need to kno m8?
    Wy u us netspk al ovr da plc? No seriously, you asked us a question about where to put the code. Unless you're going to tell us about the structure of your project, how do you expect us to know the best place for it to be put?
    My helpful sig is on vacation trying to loose some weight. It got a bit fat and caused a few problems but it will be back at some point!

  • #6
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts
    Sorry for the "netspk" mate.

    Yes my project/script is an image script, consists of content dir, and includes dir, inside we have:

    Code:
    content dir:
    
    content/themes/(THEME NAME HERE)/
    
    includes dir:
    
    includes/form.php
    includes/init.php
    includes/functions.php
    includes/template.func.php
    I don't think it'd go in my theme files? I'm thinking my init.php or preferably functions.php which is there now.. And seems OK, only how to call on system_error.php?

  • #7
    Senior Coder
    Join Date
    Feb 2011
    Location
    Your Monitor
    Posts
    4,090
    Thanks
    51
    Thanked 506 Times in 493 Posts
    Thats more like it!

    I'd put it in the functions file.
    My helpful sig is on vacation trying to loose some weight. It got a bit fat and caused a few problems but it will be back at some point!

  • #8
    Regular Coder
    Join Date
    May 2011
    Posts
    303
    Thanks
    29
    Thanked 0 Times in 0 Posts
    So, when im calling it i must pass a var/argument.

    What argument?2

  • #9
    Senior Coder
    Join Date
    Feb 2011
    Location
    Your Monitor
    Posts
    4,090
    Thanks
    51
    Thanked 506 Times in 493 Posts
    The http status code number is the arguement you pass.

    It's clearly taking a numerical arguement and then selecting an array value based on the key being the same as the arguement passed to the function. Must be said, I'm a bit shocked you've decided to use a function that you've no idea how to use or what it does..
    My helpful sig is on vacation trying to loose some weight. It got a bit fat and caused a few problems but it will be back at some point!


  •  

    Posting Permissions

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