/trunk/dev/test/index.html |
---|
--- doc/install_iis.txt (nonexistent) |
+++ doc/install_iis.txt (revision 348) |
@@ -0,0 +1,34 @@ |
+ |
+Install OIDplus to Microsoft IIS |
+================================ |
+ |
+(1) Install IIS using "Programs and Features" in the control panel |
+ |
+ see tutorial here https://www.howtogeek.com/112455/how-to-install-iis-8-on-windows-8/ |
+ |
+(2) Install PHP using the Web Platform Installer |
+ |
+ see more here: https://docs.microsoft.com/en-us/iis/application-frameworks/scenario-build-a-php-website-on-iis/configuring-step-1-install-iis-and-php |
+ |
+ Note: The Web Platform Installer sometimes exits with an error (signature verification failed etc), |
+ but you can ignore it, as PHP is actually successfully installed! |
+ |
+(3) Place OIDplus here: |
+ |
+ C:\inetpub\wwwroot\oidplus\ |
+ |
+(4) Run following command to unlock various things in the web.config file: |
+ |
+ %windir%\system32\inetsrv\appcmd.exe unlock config -section:system.webServer/security/authentication/anonymousAuthentication |
+ |
+(5) Solving problem "SSL Certificate Problem: Unable to get local issuer certificate" |
+ |
+ Download https://curl.haxx.se/ca/cacert.pem and place it in "C:\Program Files (x86)\PHP\v7.0\extras\ssl" |
+ |
+ Edit "C:\Program Files (x86)\PHP\v7.0\php.ini" (you need to run Notepad as administrator) |
+ Search for "curl.cainfo" and change the line into: |
+ curl.cainfo=C:\Program Files\PHP\extras\ssl\cacert.pem |
+ Attention: Do not write "Program Files (x86)", even though it might be the right directory. |
+ Otherwise, PHP will not work anymore "MBstring not found" ... a bug in PHP?! |
+ |
+ Open cmd as administrator and run "iisreset" |
/trunk/includes/classes/OIDplusDatabaseConnection.class.php |
---|
22,6 → 22,7 |
protected /*?bool*/ $html = null; |
protected /*?string*/ $last_query = null; |
public abstract static function getPlugin(): OIDplusDatabasePlugin; |
protected abstract function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult; |
public abstract function error(): string; |
public abstract function transaction_begin()/*: void*/; |
/trunk/includes/classes/OIDplusGui.class.php |
---|
28,7 → 28,13 |
$out['text'] = ''; |
foreach (OIDplus::getPagePlugins() as $plugin) { |
try { |
$plugin->gui($id, $out, $handled); |
} catch (Exception $e) { |
$out['title'] = 'Error'; |
$out['icon'] = 'img/error_big.png'; |
$out['text'] = $e->getMessage(); |
} |
if ($handled) break; |
} |
/trunk/plugins/adminPages/111_systeminfo/OIDplusPageAdminSysteminfo.class.php |
---|
42,38 → 42,93 |
# --- |
$out['text'] .= '<h2>OIDplus</h2>'; |
$out['text'] .= '<div class="container box"><div id="suboid_table" class="table-responsive">'; |
$out['text'] .= '<table class="table table-bordered table-striped">'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <th width="50%">Attribute</th>'; |
$out['text'] .= ' <th width="50%">Value</th>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= ' <tr>'; |
$sysid_oid = OIDplus::getSystemId(true); |
if (!$sysid_oid) $sysid_oid = 'unknown'; |
$out['text'] .= '<p>System OID: '.$sysid_oid.'</p>'; |
$out['text'] .= ' <td>System OID</td>'; |
$out['text'] .= ' <td>'.$sysid_oid.'</td>'; |
$out['text'] .= ' </tr>'; |
$sys_url = OIDplus::getSystemUrl(); |
$out['text'] .= '<p>System URL: '.$sys_url.'</p>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>System URL</td>'; |
$out['text'] .= ' <td>'.$sys_url.'</td>'; |
$out['text'] .= ' </tr>'; |
$sys_ver = OIDplus::getVersion(); |
if (!$sys_ver) $sys_ver = 'unknown'; |
$out['text'] .= '<p>System version: '.$sys_ver.'</p>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>System version</td>'; |
$out['text'] .= ' <td>'.$sys_ver.'</td>'; |
$out['text'] .= ' </tr>'; |
$sys_install_type = OIDplus::getInstallType(); |
$out['text'] .= '<p>Installation type: '.$sys_install_type.'</p>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>Installation type</td>'; |
$out['text'] .= ' <td>'.$sys_install_type.'</td>'; |
$out['text'] .= ' </tr>'; |
$sys_title = OIDplus::config()->getValue('system_title'); |
$out['text'] .= '<p>System title: '.$sys_title.'</p>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>System title</td>'; |
$out['text'] .= ' <td>'.$sys_title.'</td>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= '</table>'; |
$out['text'] .= '</div></div>'; |
# --- |
$out['text'] .= '<h2>PHP</h2>'; |
$out['text'] .= '<p>PHP version: '.phpversion().'</p>'; |
$out['text'] .= '<div class="container box"><div id="suboid_table" class="table-responsive">'; |
$out['text'] .= '<table class="table table-bordered table-striped">'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <th width="50%">Attribute</th>'; |
$out['text'] .= ' <th width="50%">Value</th>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>PHP version</td>'; |
$out['text'] .= ' <td>'.phpversion().'</td>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= '</table>'; |
$out['text'] .= '</div></div>'; |
# --- |
$out['text'] .= '<h2>Webserver</h2>'; |
$out['text'] .= '<p>Server software: '.(isset($_SERVER['SERVER_SOFTWARE']) ? $_SERVER['SERVER_SOFTWARE'] : 'unknown').'</p>'; |
$out['text'] .= '<div class="container box"><div id="suboid_table" class="table-responsive">'; |
$out['text'] .= '<table class="table table-bordered table-striped">'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <th width="50%">Attribute</th>'; |
$out['text'] .= ' <th width="50%">Value</th>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>Server software</td>'; |
$out['text'] .= ' <td>'.(isset($_SERVER['SERVER_SOFTWARE']) ? $_SERVER['SERVER_SOFTWARE'] : 'unknown').'</td>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= '</table>'; |
$out['text'] .= '</div></div>'; |
# --- |
$out['text'] .= '<h2>Database</h2>'; |
$out['text'] .= '<p>Database provider: '.get_class(OIDplus::db()).'</p>'; |
$out['text'] .= '<p>SQL slang: '.get_class(OIDplus::db()->getSlang()).'</p>'; |
$out['text'] .= '<div class="container box"><div id="suboid_table" class="table-responsive">'; |
$out['text'] .= '<table class="table table-bordered table-striped">'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <th width="50%">Attribute</th>'; |
$out['text'] .= ' <th width="50%">Value</th>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>Database provider</td>'; |
$out['text'] .= ' <td>'.OIDplus::db()->getPlugin()->getManifest()->getName().'</td>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= ' <tr>'; |
$out['text'] .= ' <td>SQL slang</td>'; |
$out['text'] .= ' <td>'.OIDplus::db()->getSlang()->getManifest()->getName().'</td>'; |
$out['text'] .= ' </tr>'; |
$out['text'] .= '</table>'; |
$out['text'] .= '</div></div>'; |
// TODO: can we somehow get the DBMS version, connection string etc? |
/trunk/plugins/adminPages/400_oidinfo_export/OIDplusPageAdminOIDInfoExport.class.php |
---|
219,6 → 219,7 |
} |
} |
natsort($all_local_oids_of_root); |
foreach ($all_local_oids_of_root as $local_oid) { |
if (!in_array($local_oid, $root['children'])) { |
$count++; |
447,6 → 448,7 |
$out['text'] .= '<div class="container box"><div id="suboid_table" class="table-responsive">'; |
$out['text'] .= '<table class="table table-bordered table-striped">'; |
$out['text'] .= '<tr><th colspan="4">Actions</th><th>OID</th></tr>'; |
natsort($root['children']); |
foreach ($root['children'] as $child_oid) { |
if (!in_array($child_oid, $all_local_oids)) { |
$count++; |
/trunk/plugins/database/mysqli/OIDplusDatabaseConnectionMySQLi.class.php |
---|
22,6 → 22,10 |
private $prepare_cache = array(); |
private $last_error = null; // we need that because MySQL divides prepared statement errors and normal query errors, but we have only one "error()" method |
public static function getPlugin(): OIDplusDatabasePlugin { |
return new OIDplusDatabasePluginMySQLi(); |
} |
public function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult { |
$this->last_error = null; |
if (is_null($prepared_args)) { |
/trunk/plugins/database/odbc/OIDplusDatabaseConnectionODBC.class.php |
---|
21,6 → 21,10 |
private $conn; |
private $last_error = null; // do the same like MySQL+PDO, just to be equal in the behavior |
public static function getPlugin(): OIDplusDatabasePlugin { |
return new OIDplusDatabasePluginODBC(); |
} |
public function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult { |
$this->last_error = null; |
if (is_null($prepared_args)) { |
/trunk/plugins/database/pdo/OIDplusDatabaseConnectionPDO.class.php |
---|
21,6 → 21,10 |
private $conn = null; |
private $last_error = null; // we need that because PDO divides prepared statement errors and normal query errors, but we have only one "error()" method |
public static function getPlugin(): OIDplusDatabasePlugin { |
return new OIDplusDatabasePluginPDO(); |
} |
public function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult { |
$this->last_error = null; |
if (is_null($prepared_args)) { |
/trunk/plugins/database/pgsql/OIDplusDatabaseConnectionPgSql.class.php |
---|
22,6 → 22,10 |
private $already_prepared = array(); |
private $last_error = null; // do the same like MySQL+PDO, just to be equal in the behavior |
public static function getPlugin(): OIDplusDatabasePlugin { |
return new OIDplusDatabasePluginPgSql(); |
} |
public function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult { |
$this->last_error = null; |
if (is_null($prepared_args)) { |
/trunk/plugins/database/sqlite3/OIDplusDatabaseConnectionSQLite3.class.php |
---|
22,6 → 22,10 |
private $prepare_cache = array(); |
private $last_error = null; // do the same like MySQL+PDO, just to be equal in the behavior |
public static function getPlugin(): OIDplusDatabasePlugin { |
return new OIDplusDatabasePluginSQLite3(); |
} |
public function doQuery(string $sql, /*?array*/ $prepared_args=null): OIDplusQueryResult { |
$this->last_error = null; |
if (is_null($prepared_args)) { |