random gallery image
random tutorial
preview

..one or more modules you must have seen the iframes used for realtime result display. In this tutorial I'm going to show you how to insert them into your module and how they..

read more

random information gathering
THC Sscan

THC Sscan is a very versatile tool for scanning (html) files

more about this module
more of this category
more modules

HackSuite File Library
File Library
Here you can find the latest files and structure of the THC HackSuite, note that if you have an earlier version of the suite it's not recommended to update files manually. Instead you should overwrite your existing HackSuite environment.
<?php
/* Changes current style

Author: Remco Kouw
Site: http://www.hacksuite.com
Last Edit: 10-03-2015
*/
if(!defined('IN_SCRIPT')){
    exit;
}
$_CONTEXT['subtitle'] = "Style Manager";
// target files we need, so make sure they are present
$aFiles = array($_PATHS['functions_root']."/fwrite.php",$_PATHS['functions_root']."/getdirbydir.php",$_PATHS['data_root']."/style.php");
for(
$x=0;$x<count($aFiles);$x++){
    (!
IsThere($aFiles[$x]) ? include_once($_PATHS['end']) : include_once($aFiles[$x]));
}
// no need to go on if there are no directories in the template directory
if(false==($aDirs GetDirByDir($_PATHS['templates_root'],0))){
    
$_CONTEXT['fatal'] = true;
    include_once(
$_PATHS['end']);
}
if(isset(
$_POST['sStyle'])){
    
// form submitted, let's make sure we have some styles present and that it's worth updating the data file
    
if(!in_array($_POST['sStyle'],$aDirs)){
        
// orly did you rly believe you can change to a style that isn't even there?
        
$_CONTEXT['errors'][] = "Style doesn't exist";
        include_once(
$_PATHS['end']);
    }
    if(
$_POST['sStyle']==$_PATHS['style_user']){
        
// now stop being silly, why change it to the same style.. odd ppl out there :p
        
$_CONTEXT['errors'][] = "You already have that style enabled";
        include_once(
$_PATHS['end']);
    }
    
// make sure that the template has an index page, add a path too, we might need to use it even more in the future
    
$_PATHS['new_style_root'] = $_PATHS['templates_root']."/".$_POST['sStyle'];
    
$sDest $_PATHS['new_style_root']."/index.php";
    if(!
IsThere($sDest)){
        include_once(
$_PATHS['end']);
    }
    
// create the new style.php file data
    
$sData "<?php\n";
    
$sData .= "/* Style environment */\n";
    
$sData .= "\$_STYLE = \"".$_POST['sStyle']."\";\n";
    
$sData .= "?>";
    
// let's hope the update succeeds
    
$sDest $_PATHS['data_root']."/style.php";
    (!
WriteF($sDest,$sData,"w") ? include_once($_PATHS['end']) : $sCode .= "<div class=\"spacingmsg\">".$_CONTEXT['result_headers']['result']."Successfully changed style, click <a href=\"configuration.php\">here</a> to continue</div>");
}
else{
    
/* update style form */
    // output the templates that are available
    
$sSelect "<select name=\"sStyle\">\n";
    for(
$x=0;$x<count($aDirs);$x++){
        
// let's make the selection menu
        
$sSelect .= "<option value=\"".$aDirs[$x]."\"".($aDirs[$x]==$_PATHS['style_user'] ? " selected" "").">".$aDirs[$x]."</option>\n";
    }
    
$sSelect .= "</select>\n";
    
$sCode .= "            <form method=\"post\">\n";
    
$sCode .= "            <div class=\"emboss borderr5 border1pxtrans pad5 edgeglow overflw\">\n";
    
$sCode .= "                <div class=\"embosshdrnocenter border1pxtrans pad10\">Change the look and feel of the THC HackSuite</div>\n";
    
$sCode .= "                <div class=\"cc_record\">\n";
    
$sCode .= "                    <div class=\"flt pad3 w150\">select a style:</div>\n";
    
$sCode .= "                    <div class=\"flt pad3\">".$sSelect."</div>\n";
    
$sCode .= "                </div>\n";
    
$sCode .= "                <div class=\"clear\"></div>\n";
    
$sCode .= "                <div class=\"cc_record\">\n";
    
$sCode .= "                    <div class=\"flt pad3\"><input type=\"hidden\" name=\"iCFG\" value=\"".$_POST['iCFG']."\" /><input type=\"submit\" name=\"submit\" value=\"Change Style\" /></div>\n";
    
$sCode .= "                </div>\n";
    
$sCode .= "                <div class=\"clear\"></div>\n";
    
$sCode .= "            </div>\n";
    
$sCode .= "            </form>\n";
}
?>
powered by
site stats
cms statistics:
version: 0.6.0
downloads: 4372
native: 26
modules: 21
apps: 2
support development
It takes lots of calories in order to create new things for the hacksuite, so it would be grand if you could buy me a protein shake or extra energy to keep me going. Thanks!
disclaimer
We are not responsible for any direct or indirect damage caused by abusing the tools provided on hacksuite.com. The suite is developed for educational purposes, use at your own risk!
Created by Remco Kouw. Powered by protein shakes and a high calorie diet.