當前位置: 首頁>>代碼示例>>PHP>>正文


PHP test::root_path_write_valid方法代碼示例

本文整理匯總了PHP中test::root_path_write_valid方法的典型用法代碼示例。如果您正苦於以下問題:PHP test::root_path_write_valid方法的具體用法?PHP test::root_path_write_valid怎麽用?PHP test::root_path_write_valid使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在test的用法示例。


在下文中一共展示了test::root_path_write_valid方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: updatable

 static function updatable()
 {
     return test::framework_working() && test::config_writable() && test::root_path_write_valid() && test::admin_data_writable() && test::directories_updatable();
 }
開發者ID:laiello,項目名稱:phpbf,代碼行數:4,代碼來源:class.test.php

示例2:

print '<h3>Web server</h3>
	<table cellspacing="0" cellpadding="5" class="tests"><tr>
		<td class="title"><b>Running on Apache</b> (Recommended but not required)</td><td>' . (test::get_apache_version() ? test::ok() . " (" . test::get_apache_version() . ")" : test::warning("No")) . '</td>
	</tr><tr>
		<td class="title"><b>PHP Version</b> (Required 5.0+, recommended 5.2+)</td><td>' . (test::get_php_version() >= 5.0 ? test::get_php_version() >= 5.2 ? test::ok() : test::warning("OK") : test::invalid("No")) . ' (' . test::get_php_version() . ')&nbsp;&nbsp;&nbsp;&nbsp;<a href="' . common::url('self') . '?view=phpinfo">View PHP Info</a></td>
	</tr><tr>
		<td class="title"><b>Sessions</b> (Required)</td><td>' . (test::session_enabled() ? test::ok() : test::invalid()) . '</td>
	</tr><tr>
		<td class="title"><b>Magic quotes</b> (Recommended to be off)</td><td>' . (test::magic_quotes_on() ? test::warning("Turn off for better performance") : test::ok("OFF")) . '</td>
	</tr></table>

	<h3>Admin console and config file</h3>
	<table cellspacing="0" cellpadding="5" class="tests"><tr>
		<td class="title"><b>Valid path to root</b></td><td>' . (test::root_path_valid() ? test::ok("YES") : test::invalid("NO")) . ' (Path: <i>' . PATH_TO_ROOT . '</i>)</td>
	</tr><tr>
		<td class="title"><b>Valid path to root for editing</b></td><td>' . (test::root_path_write_valid() ? test::ok("YES") : test::invalid("NO. Update will not work if it is not valid")) . ' (Path: <i>' . PATH_TO_ROOT_WRITE . '</i>)</td>
	</tr><tr>
		<td class="title"><b>Config file exists</b></td><td>' . (test::config_exists() ? test::ok("YES") : test::invalid("NO")) . ' (Path: <i>' . CONFIG_FILE . '</i>)</td>
	</tr><tr>
		<td class="title"><b>Config file is writable</b> (though edit path)</td><td>' . (test::config_writable() ? test::ok("YES") : test::invalid("NO")) . ' (Path: <i>' . CONFIG_FILE_WRITE . '</i>)</td>
	</tr><tr>
		<td class="title"><b>Config is complete</b></td><td>' . (test::config_complete() ? test::ok("YES") : test::invalid("NO. Run configuration again")) . '</td>
	</tr></table>

	<h3>Directories</h3>
	<table cellspacing="0" cellpadding="5" class="tests"><tr>';
foreach (test::directories() as $id => $data) {
    print '
	<tr>
		<td class="title"><b>Folder: ' . $id . '</b>' . ($data['write_required'] ? ' (Needs to be writable)' : '') . '</td>
		<td>' . ($data['exists'] ? $data['write_required'] && !$data['writable'] ? test::invalid("Not writable") : test::ok("OK") : test::invalid("NOT FOUND")) . ' (Path: <i>' . $data['path'] . '</i>)</td>
開發者ID:laiello,項目名稱:phpbf,代碼行數:31,代碼來源:view.test.php


注:本文中的test::root_path_write_valid方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。