fopen and fsockopen

Posted on 2011-10-19
Last Modified: 2012-05-12
How can I tell if "fopen" and "fsockopen" is installed on my server?
Question by:COwebmaster
    LVL 23

    Expert Comment

    if(!function_exists(\"fsockopen\")) { 
     echo \"Function Exists\"; 

    Open in new window

    LVL 23

    Accepted Solution

    echo 'Function Exists';
       echo 'function does not exist';

    Open in new window

    LVL 107

    Assisted Solution

    by:Ray Paseur
    Try to use them!  

    First, you can look them up on, and you should always do that any time you are not 100% dead-certain (1) what inputs are required, (2) how they work, (3) what outputs and return values are expected.  Always read the online man pages and pay attention to the user-contributed notes that are some of the best parts of  Here are the links you want to study: (part of the FileSystem) (part of the Network)

    Author Closing Comment


    Featured Post

    6 Surprising Benefits of Threat Intelligence

    All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

    Join & Write a Comment

    SSH (Secure Shell) - Tips and Tricks As you all know SSH(Secure Shell) is a network protocol, which we use to access/transfer files securely between two networked devices. SSH was actually designed as a replacement for insecure protocols that sen…
    I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension ( This reminded me of questions tha…
    Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
    Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now