Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Page 1 of 2 12 LastLast
Results 1 to 10 of 12
  1. #1
    Join Date
    Nov 2007
    Posts
    182
    Tokens
    0

    Default fsockopen problen

    ok so i posted about my stats not working because of fsockopen and was told to contact my host and ask them to enable the responce i got was this...

    When you install some PHP products such as osCommerce, you may be faced with a 'register_globals' error such as the following:

    Server Requirement Error: register_globals is disabled in your PHP configuration. This can be enabled in your php.ini configuration file or in the .htaccess file in your catalog directory.

    The documentation that accompanies your PHP product may suggest you request your web hosting provider to turn on 'register_globals' for the entire server. This is simply not safe for all users.

    You can, however, enable it for your hosting account by doing the following:


    • Download the file .htaccess from your public_html directory by FTP
    • Edit the file in a text editor such as notepad and search for the following line:
      php_value register_globals 1
    • Remove the # at the beginning of the line
    • Save and upload the file back to the directory you originally found it

    If the line # php_value register_globals 1 is not present, simply add the following code on a new line and upload the .htaccess file back to the server:
    php_value register_globals 1

    This should resolve the 'register_globals' problem

    Only problem is my .htaccess file has nothing in ? lol

  2. #2

    Default

    If the line # php_value register_globals 1 is not present, simply add the following code on a new line and upload the .htaccess file back to the server:
    php_value register_globals 1
    Explains your problem...?

  3. #3
    Join Date
    Nov 2007
    Posts
    182
    Tokens
    0

    Default

    Quote Originally Posted by Jam-ez View Post
    Explains your problem...?

    Have tried this already and didnt work, ty tho.

  4. #4
    Join Date
    Mar 2008
    Posts
    5,108
    Tokens
    3,780

    Latest Awards:

    Default

    Don't turn register globals on.. you don't need it.. that has nothing to do with the fsockopen problem.

    I don't see what osCommerce has anything to do with it either.

    What's the error/problem you get with your stats?

  5. #5
    Join Date
    Nov 2007
    Posts
    182
    Tokens
    0

    Default

    Quote Originally Posted by Dentafrice View Post
    Don't turn register globals on.. you don't need it.. that has nothing to do with the fsockopen problem.

    I don't see what osCommerce has anything to do with it either.

    What's the error/problem you get with your stats?
    this is the error..

    Warning: fsockopen() [function.fsockopen]: unable to connect to shoutcast.mr-host.com:8036 (Connection timed out) in /home/habjay/public_html/radio_stats.php on line 12
    Habtopia radio Radio Is Currently Offline

  6. #6
    Join Date
    Nov 2008
    Posts
    75
    Tokens
    0

    Default

    Quote Originally Posted by Habtopia View Post
    this is the error..
    That has nothing to do with register globals mate

    It's just PHP telling you it can't connect to the server..

    find fsockopen and change it to @fsockopen

    keep the @ symbol.

    stops the error.

  7. #7
    Join Date
    Nov 2007
    Posts
    182
    Tokens
    0

    Default

    Quote Originally Posted by Doritos View Post
    That has nothing to do with register globals mate

    It's just PHP telling you it can't connect to the server..

    find fsockopen and change it to @fsockopen

    keep the @ symbol.

    stops the error.
    there is no error in the file as it works fine on other hosting accs,
    i will try what you said anyway, thanks.

  8. #8
    Join Date
    Nov 2008
    Posts
    75
    Tokens
    0

    Default

    Quote Originally Posted by Habtopia View Post
    there is no error in the file as it works fine on other hosting accs,
    i will try what you said anyway, thanks.
    Other hosts might be setup to not display the error. That's the problem with moving around share hosting enviroments.

    Just try what I said, and see if it suppresses the error.

  9. #9
    Join Date
    Jun 2005
    Posts
    4,795
    Tokens
    0

    Latest Awards:

    Default

    Adding @ does not stop the error, only `silences` it. If you say that the script works fine on other server then I recommend you contact you host again as they gave you something that is completely unrelated to the problem that you are experiencing.

    Quote Originally Posted by Doritos View Post
    That has nothing to do with register globals mate

    It's just PHP telling you it can't connect to the server..

    find fsockopen and change it to @fsockopen

    keep the @ symbol.

    stops the error.

  10. #10
    Join Date
    Nov 2007
    Location
    London
    Posts
    1,577
    Tokens
    36

    Latest Awards:

    Default

    For the sake of your question, all you would do if it has nothing in it is add:

    Code:
    php_value register_globals 1
    That's all you need to do. That will turn register_globals on for your entire webhosting, or, if you create a new .htaccess file in a single directory only (directory with stats in), and only add that line to this .htaccess, it will only turn register_globals on for that directory.

    But, that has nothing to do with your problem. I wrote a detailed thread that covers almost all problems with radio statistics:

    http://www.habboxforum.com/showthread.php?t=513298

    The bit you want to focus on is step 4:

    4. The radio statistics script connects to the server that the SHOUTcast is on through the port that the SHOUTcast is on. You need to make sure that this port is unblocked on BOTH servers (the one with the hosting that the radio statistics are on and the one hosting the SHOUTcast), (getting technical: inbound data and outbound data) for this to work. If you can connect to it to broadcast on it then it means that your SHOUTcast host has their firewall correctly configured, so you need to contact the host that is hosting the radio statistics script to unblock these ports on the firewall. They may also need the IP to allow the IP through the firewall, depending on what types of firewall they have.

    Right, if you have a crappy host who didn't even know they have a firewall and don't know what a VPS stands for, give them these instructions:

    Connect on SSH
    Enter the following stuff (without the # or space after it)
    # setup
    Now press down on your keyboard and enter
    Now press down, down, right right on your keyboard and press enter
    Now press down 12 times on your keyboard and press right a few times until it goes to the end of whatever the first thing is there, eg text:tcp or 1234:tcp
    Press space twice than left (so you're in a space where theres a space either side)
    Now type the SHOUTcast port followed by :tcp
    eg. 8000:tcp
    Press down then enter.
    Press down, down, right, then enter.
    Then go to quit or just quit whatever you are on on to connect to SSH.

    If they don't know how to connect to SSH then I seriously suggest you move host. These steps may sound silly but they should be clear if you're actually doing it, and it is easier than saying click bla bla because the interface is a bit weird.
    Mr-Host should know how to do this, if you've already contacted them about your radio stats then I find it quite funny that I'm giving support for something that they should really know. Although, if the people who provide your web hosting don't know this either, they're just as bad.

    Hope this solves your issue.
    Kind Regards,

    Guy
    __________________

    Since 2007. Unbelievable Uptime. Web hosting, resellers, master resellers, linux VPS, windows VPS, shoutcasts, at the lowest prices on the net.
    Tech-Hosts.co.uk.


Page 1 of 2 12 LastLast

Posting Permissions

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