function check_xml_object()
 {
     if (!$this->xml_object) {
         $filepath = $this->filepath;
         if ($filepath) {
             source($filepath);
         }
     }
 }
示例#2
0
文件: runall.php 项目: seco/53to
$reportfile = "report_{$_GET['filter']}";
if (file_exists($reportfile)) {
    //	rmdir('report');
    $reports = scandir($reportfile);
    /*自己和父节点*/
    print 'on batch run, please waiting : ' . (sizeof($reports) - 2);
    return;
} else {
    mkdir($reportfile);
}
if (file_exists("./coverage/source.js")) {
    if (unlink("./coverage/source.js")) {
        echo "成功删除文件:source.js";
    }
}
source();
if (file_exists("covreport.html")) {
    if (unlink("covreport.html")) {
        echo "成功删除覆盖率报告文件: covreport.html<br />\n";
    }
}
if (file_exists("jshintReport.html")) {
    if (unlink("jshintReport.html")) {
        echo "成功删除: jshintReport.html<br />\n";
    }
}
exec("python ../lib/jshunter_1.2.0.1/jshunter_dev/jshunter/hint.py jshintReport.html ../../../_src", $back);
echo "jshint: " . $back . "<br />\n";
/*记录运行时信息*/
$b = array_key_exists('browser', $_GET) ? $_GET['browser'] : 'all';
//if ( array_key_exists( 'cov' , $_GET ) ){
示例#3
0
<?
	# Известные недоработки:
	# - аргумент должен содержать только название программы-файла, без пути к нему, следовательно его следует валидировать сперва, а этого не происходит

	/**
	 * Выводит исходный код исполняемого файла программы/команды/скрипта...
	 *
	 */

	if (!preg_match('!^\./!', $arg[1])){
		if (isset($_SESSION['cd']['default'])) {
			chdir($_SESSION['cd']['default']);
		}
	}

	return source($arg[1]);

	if (!preg_match('!^\./!', $arg[1])){
		if (isset($_SESSION['cd']['user'])) {
			chdir($_SESSION['cd']['user']);
		}
	}

	function source($cmdname) {
		global $site, $fold;

		$cmdname  = str_replace(['../', '..'], '', $cmdname);	# user see|put this address of file

		if (preg_match('!^\./!', $cmdname)){
			$filename  = $cmdname . $site['extensions'];	# but realy file exist at home dir
			if (!is_readable($filename)) {
 if (!$_GET["cli_id"]) {
     header("Location:client_lookup.php");
     exit;
 }
 // default scope
 if (!$_GET["cli_sales"] && $_SESSION["auth"]["default_scope"] == 'Sales') {
     $_GET["cli_sales"] = 'Yes';
 }
 if (!$_GET["cli_lettings"] && $_SESSION["auth"]["default_scope"] == 'Lettings') {
     $_GET["cli_lettings"] = 'Yes';
 }
 foreach ($_GET as $key => $val) {
     ${$key} = trim($val);
 }
 // returns an array for the multi-dropdown source fields
 $source = source($cli_source, $_SERVER['QUERY_STRING']);
 $method_array = db_enum("client", "cli_method", "array");
 array_pop($method_array);
 // removing 'Import'
 # build data arrays
 $formData1 = array('cli_method' => array('type' => 'radio', 'label' => 'Contact Method', 'value' => $cli_method, 'required' => 2, 'options' => $method_array), 'cli_source' => array('type' => 'select_multi', 'label' => 'Lead Source', 'required' => 2, 'options' => array('dd1' => $source['dd1'], 'dd2' => $source['dd2'])), 'cli_sales' => array('type' => 'radio', 'label' => 'Sales', 'value' => $cli_sales, 'required' => 2, 'options' => db_enum("client", "cli_sales", "array"), 'default' => 'No', 'attributes' => array('onClick' => 'javascript:toggleDivRadio(\'cli_sales\',\'sale\');')), 'cli_lettings' => array('type' => 'radio', 'label' => 'Lettings', 'value' => $cli_lettings, 'required' => 2, 'options' => db_enum("client", "cli_lettings", "array"), 'default' => 'No', 'attributes' => array('onClick' => 'javascript:toggleDivRadio(\'cli_lettings\',\'let\');')));
 // sales form
 $formData2 = array('cli_salemin' => array('type' => 'select_price', 'label' => 'Minimum Price', 'group' => 'Price Range', 'required' => 2, 'options' => array('scope' => 'sales', 'default' => 'Minimum'), 'attributes' => array('style' => 'width:120px')), 'cli_salemax' => array('type' => 'select_price', 'label' => 'Maximum Price', 'group' => 'Price Range', 'last_in_group' => 1, 'required' => 2, 'options' => array('scope' => 'sales', 'default' => 'Maximum'), 'attributes' => array('style' => 'width:120px')), 'cli_salebed' => array('type' => 'select_number', 'label' => 'Minimum Beds', 'required' => 2), 'cli_saleemail' => array('type' => 'radio', 'label' => 'Email Updates', 'required' => 2, 'default' => 'Yes', 'options' => db_enum("client", "cli_saleemail", "array")));
 $ptype_sale = ptype("sale", explode("|", $_GET["cli_saleptype"]));
 // lettings form
 $formData3 = array('cli_letmin' => array('type' => 'select_price', 'label' => 'Minimum Price', 'group' => 'Price Range', 'required' => 2, 'options' => array('scope' => 'lettings', 'default' => 'Minimum'), 'attributes' => array('style' => 'width:120px')), 'cli_letmax' => array('type' => 'select_price', 'label' => 'Maximum Price', 'group' => 'Price Range', 'last_in_group' => 1, 'required' => 2, 'options' => array('scope' => 'lettings', 'default' => 'Maximum'), 'attributes' => array('style' => 'width:120px')), 'cli_letbed' => array('type' => 'select_number', 'label' => 'Minimum Beds', 'required' => 2), 'cli_letemail' => array('type' => 'radio', 'label' => 'Email Updates', 'default' => 'Yes', 'required' => 2, 'options' => db_enum("client", "cli_letemail", "array")));
 $ptype_let = ptype("let", explode("|", $_GET["cli_letptype"]));
 // form is not submitted, show the form
 if (!$_GET["action"]) {
     // start new form object
     $form = new Form();
示例#5
0
文件: show.php 项目: shabbyrobe/amiss
    for ($i = 0; $i < $_GET['loop'] - 1; $i++) {
        eval($script);
    }
}
$manager->connector->queries = 0;
ob_start();
$startTime = microtime(true);
$data = eval($script);
$timeTaken = microtime(true) - $startTime;
$timeTaken = round($timeTaken * 1000, 4);
$memUsed = memory_get_usage();
$memPeak = memory_get_peak_usage();
if ($fmt == 'html') {
    dump_example($data);
    $output = ob_get_clean();
    $source = source($rawScript, true);
    ?>
<html>
<head>
<style type="text/css">
.lines, .code {
    font-size:12px;
    font-family:Courier;
}
.lines {
    width:10px;
    padding-right:4px;
}
</style>
</head>
<body>
示例#6
0
    <td class="label">Initial Contact Method</td>
	<td>' . $cli_method . '</td>
  </tr>
</table>
';
$form1 = array('cli_salutation' => array('type' => 'select', 'group' => 'Full Name', 'label' => 'Salutation', 'value' => $cli_salutation, 'required' => 2, 'options' => join_arrays(array(array('' => ''), db_enum("client", "cli_salutation", "array"))), 'attributes' => array('style' => 'width:60px')), 'cli_fname' => array('type' => 'text', 'group' => 'Full Name', 'label' => 'Forename', 'value' => $cli_fname, 'init' => 'Forename(s)', 'required' => 2, 'attributes' => array('style' => 'width:100px', 'onFocus' => 'javascript:clearField(this,\'Forename(s)\')'), 'function' => 'format_name'), 'cli_sname' => array('type' => 'text', 'group' => 'Full Name', 'last_in_group' => 1, 'label' => 'Surname', 'value' => $cli_sname, 'init' => 'Surname', 'required' => 2, 'attributes' => array('style' => 'width:152px', 'onFocus' => 'javascript:clearField(this,\'Surname\')'), 'function' => 'format_name'), 'cli_tel' => array('type' => 'tel', 'label' => 'Telephone', 'value' => $telephone), 'cli_email' => array('type' => 'text', 'label' => 'Email', 'value' => $cli_email, 'required' => 3, 'attributes' => array('style' => 'width:320px', 'maxlength' => 255), 'tooltip' => 'Must be a valid email address'), 'cli_web' => array('type' => 'text', 'label' => 'Website', 'value' => $cli_web, 'init' => 'http://', 'required' => 1, 'attributes' => array('style' => 'width:320px', 'maxlength' => 255)), 'cli_preferred' => array('type' => 'radio', 'label' => 'Preferred Contact', 'value' => $cli_preferred, 'required' => 2, 'options' => db_enum("client", "cli_preferred", "array"), 'tooltip' => 'How the client would prefer to be contacted, not including property alerts'), 'cli_notes' => array('type' => 'textarea', 'label' => 'Add General Note', 'attributes' => array('class' => 'noteInput')));
// address, this is only used for manual input resulting from ajax input (validation only)
$form2 = array('pro_addr1' => array('type' => 'text', 'label' => 'House Number', 'value' => $pro_addr1, 'required' => 2, 'attributes' => array('class' => 'addr'), 'function' => 'format_street'), 'pro_addr2' => array('type' => 'text', 'label' => 'Building Name', 'value' => $pro_addr2, 'required' => 1, 'attributes' => array('class' => 'addr'), 'function' => 'format_street'), 'pro_addr3' => array('type' => 'text', 'label' => 'Street', 'value' => $pro_addr3, 'required' => 2, 'attributes' => array('class' => 'addr'), 'function' => 'format_street'), 'pro_addr4' => array('type' => 'text', 'label' => 'Town or Area', 'value' => $pro_addr4, 'required' => 3, 'attributes' => array('class' => 'addr'), 'function' => 'format_street'), 'pro_addr5' => array('type' => 'text', 'label' => 'City or County', 'value' => $pro_addr5, 'required' => 2, 'attributes' => array('class' => 'addr'), 'function' => 'format_street'), 'pro_postcode' => array('type' => 'text', 'label' => 'Postcode', 'value' => $pro_postcode, 'required' => 2, 'attributes' => array('class' => 'pc', 'maxlength' => 9), 'function' => 'format_postcode'));
// form 3, deals
$form3 = array();
$form4 = array('cli_salemin' => array('type' => 'select_price', 'value' => $cli_salemin, 'label' => 'Minimum Price', 'group' => 'Price Range', 'required' => 2, 'options' => array('scope' => 'sales', 'default' => 'Minimum'), 'attributes' => array('style' => 'width:120px')), 'cli_salemax' => array('type' => 'select_price', 'value' => $cli_salemax, 'label' => 'Maximum Price', 'group' => 'Price Range', 'last_in_group' => 1, 'required' => 2, 'options' => array('scope' => 'sales', 'default' => 'Maximum'), 'attributes' => array('style' => 'width:120px')), 'cli_salebed' => array('type' => 'select_number', 'value' => $cli_salebed, 'label' => 'Minimum Beds', 'required' => 2), 'cli_saleemail' => array('type' => 'radio', 'value' => $cli_saleemail, 'label' => 'Email Updates', 'required' => 2, 'options' => db_enum("client", "cli_saleemail", "array")));
$ptype_sale = ptype("sale", explode("|", $cli_saleptype));
$form5 = array('cli_letmin' => array('type' => 'select_price', 'value' => $cli_letmin, 'label' => 'Minimum Price', 'group' => 'Price Range', 'required' => 2, 'options' => array('scope' => 'lettings', 'default' => 'Minimum'), 'attributes' => array('style' => 'width:120px')), 'cli_letmax' => array('type' => 'select_price', 'value' => $cli_letmax, 'label' => 'Maximum Price', 'group' => 'Price Range', 'last_in_group' => 1, 'required' => 2, 'options' => array('scope' => 'lettings', 'default' => 'Maximum'), 'attributes' => array('style' => 'width:120px')), 'cli_letbed' => array('type' => 'select_number', 'value' => $cli_letbed, 'label' => 'Minimum Beds', 'required' => 2), 'cli_letemail' => array('type' => 'radio', 'value' => $cli_letemail, 'label' => 'Email Updates', 'required' => 2, 'options' => db_enum("client", "cli_letemail", "array")));
$ptype_let = ptype("let", explode("|", $cli_letptype));
$form7 = array('cli_req' => array('type' => 'textarea', 'label' => 'Add Requirement', 'attributes' => array('class' => 'noteInput', 'viewForm' => 7)));
$source = source($cli_source, $_SERVER['QUERY_STRING'], 'readonly');
if (!$cli_salestatus) {
    $salestatus_array[] = '';
}
if (!$cli_letstatus) {
    $letstatus_array[] = '';
}
$sql = "SELECT * FROM cstatus";
$q = $db->query($sql);
while ($row = $q->fetchRow()) {
    if ($row["cst_scope"] == 'Sales') {
        $salestatus_array[$row["cst_id"]] = $row["cst_title"];
    } elseif ($row["cst_scope"] == 'Lettings') {
        $letstatus_array[$row["cst_id"]] = $row["cst_title"];
    }
}
示例#7
0
function fact($fact)
{
    return source($fact->source(), htmlspecialchars($fact->value()));
}
示例#8
0
文件: hmaprox.php 项目: az0ne/helpful
 <?php 
$data = source("http://proxylist.hidemyass.com/search-225758");
$total1 = filter($data);
$data = source("http://proxylist.hidemyass.com/search-225758/2");
$total2 = filter($data);
$data = source("http://proxylist.hidemyass.com/search-1302871");
$total3 = filter($data);
$final = array_merge($total1, $total2, $total3);
print_r($final);
function filter($data)
{
    $final = array();
    $array = explode('<tr', str_replace(" ", "", $data));
    foreach ($array as $tr) {
        $tr = preg_replace('/\\s+/', "", $tr);
        $type = preg_match_all('/<td>([HTPSsocks4\\/5]+)<\\/td>/', $tr, $type) ? $type[1][0] : false;
        $nons = preg_match_all('/.([a-z0-9A-Z_-]+){display:none}/', $tr, $maths) ? $maths[1] : false;
        if ($type and $nons) {
            $filtre = $tr;
            foreach ($nons as $non) {
                $filtre = preg_replace("/<spanclass=\"{$non}\">.*?<\\/span>/", "", $filtre);
            }
            $filtre = preg_replace('/<divstyle="display:none">.*?<\\/div>/', '', $filtre);
            $filtre = preg_replace('/<spanstyle="display:none">.*?<\\/span>/', '', $filtre);
            preg_match_all('/>([0-9\\.]+)</', $filtre, $ips);
            $port = end($ips[1]);
            array_pop($ips[1]);
            $host = implode("", $ips[1]);
            if (filter_var($host, FILTER_VALIDATE_IP)) {
                $final[] = array('ip' => $host . ":" . $port, 'type' => $type);
                $filee = fopen("hmaprox.html", 'a+') or die("the file cannot be open");
示例#9
0
<?php

require_once './config/require.php';
require_once './commands/source.php';
source($_GET['submitid']);
template('source', $data);
示例#10
0
文件: index.php 项目: Hikari9/Resume
source('https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js');
?>
	<?php 
source('https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css');
?>
	<?php 
source('https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js');
?>
	<?php 
source('style.css');
?>
	<?php 
source('fonts.css');
?>
	<?php 
source('main.js');
?>
</head>
<body>
<div id='site' class='container'>
	<aside id='aside' class='aside' role='aside'>
		<div id='full-name' class='aside-title'>
			<span>Rico</span>
			<span>Tiongson</span>
		</div>
		<div class='aside-tab aside-description'>
			<span class='glyphicon glyphicon-stats'></span>
			<span id='job-title'>Data Scientist</span>
		</div>
	</aside>
	<main id='main' role='main'>
示例#11
0
/**
 * Retorna o diretório url do arquivo na pasta de arquivo enviados
 * @param type $filename
 * @return type
 */
function source_images($filename = '')
{
    return source(get_config()['upload']['imagens'] . '/' . $filename);
}
示例#12
0
     addVisitor($myManager);
     break;
 case 'visitors':
     visitors($myManager);
     break;
 case 'sendEmail':
     sendEmail($myManager);
     break;
 case 'isLogin':
     isLogin();
     break;
 case 'statsreceptioncustomers':
     statsreceptioncustomers($myManager);
     break;
 case 'source':
     source($myManager);
     break;
 case 'statsceremony':
     statsceremony($myManager);
     break;
 case 'statsceremonycustomers':
     statsceremonycustomers($myManager);
     break;
 case 'statculturecustomers':
     statculturecustomers($myManager);
     break;
 case 'updateVisitor':
     updateVisitor($myManager);
     break;
 case 'removeOperation':
     removeOperation($myManager);