Hi all,
m a .net programmer, fairly new to php
can anyone explain me (m not asking to explain in detail) this php code. its in the index.php of an application.
I am not gonna irritate you by posting the whole code. so here's the outline:

<?php
    if(!extension_loaded('ionCube Loader')){
    $__oc=strtolower(substr(php_uname(),0,3));
    $__ln='ioncube_loader_'.$__oc.'_'.substr(phpversion(),0,3).(($__oc=='win')?'.dll':'.so');
    @dl($__ln);
    if(function_exists('_il_exec')){
        return _il_exec();
    }
    $__ln='/ioncube/'.$__ln;
    $__oid=$__id=realpath(ini_get('extension_dir'));
    $__here=dirname(__FILE__);
        ##############
        more code was here but i am not posting here to keep it short
        ################
    }
    else{
        die('The file '.__FILE__." is corrupted.\n");
    }
    if(function_exists('_il_exec')){
        return _il_exec();
    }
    echo('Site error: the file <b>'.__FILE__.'</b> requires the ionCube PHP Loader '.basename($__ln).' to be installed by the site administrator.');
    exit(199);
    ?>
    ######################################## and so on this encrypted THING goes on for like 20 more lines

there's nothing else in the file..
i can't seem to figure out what's with the encrypted thing
any help is appreciated

Recommended Answers

All 2 Replies

'ionCube Loader'

This protects the PHP code on your website, as you can see above. You can see it as a kind of compiled code.

thnx pritaeas.. i just came to know that posting such encrypted code is sort of illegal.. so i'd be grateful if you or some other mod can edit/delete my post to remove that part..

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.