Menu

[r207]: / trunk / PhpCheckstyle / runFromWeb.php  Maximize  Restore  History

Download this file

26 lines (18 with data), 697 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?php
define("PHPCHECKSTYLE_HOME_DIR", dirname(__FILE__));
require_once PHPCHECKSTYLE_HOME_DIR."/src/PHPCheckstyle.php";
// default values
$options['exclude'] = array();
$options['format'] = "html"; // default format
// Get user selection
$sourceDir = $_POST['sourceDir'];
$resultDir = $_POST['resultDir'];
$configFile = $_POST['configFile'];
//
$formats = explode(',', $options['format']);
// Launch PHPCheckstyle
$style = new PHPCheckstyle($formats, $resultDir, $configFile, null, false, true);
$style->processFiles($sourceDir, $options['exclude']);
echo "Reporting Completed.</BR></BR>";
echo 'Display Results : <a href="'.$resultDir.'">'.$resultDir.'</a>';
?>
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.