1
0
mirror of https://github.com/php/web-php.git synced 2026-03-23 23:02:13 +01:00

Enhancement: Enable binary_operator_spaces fixer

Closes GH-667.
This commit is contained in:
Andreas Möller
2022-08-22 19:17:38 +02:00
committed by GitHub
parent 57f505ed58
commit 1ebc2c4996
42 changed files with 881 additions and 880 deletions

View File

@@ -21,6 +21,7 @@ $config
->setRules([ ->setRules([
'array_indentation' => true, 'array_indentation' => true,
'array_syntax' => true, 'array_syntax' => true,
'binary_operator_spaces' => true,
'class_attributes_separation' => true, 'class_attributes_separation' => true,
'concat_space' => [ 'concat_space' => [
'spacing' => 'one', 'spacing' => 'one',

View File

@@ -2,12 +2,12 @@
include_once __DIR__ . '/../include/prepend.inc'; include_once __DIR__ . '/../include/prepend.inc';
$i = 0; $i = 0;
do { do {
$y = date("Y")-$i; $y = date("Y") - $i;
if (file_exists("./$y.php")) { if (file_exists("./$y.php")) {
mirror_redirect("/archive/$y.php"); mirror_redirect("/archive/$y.php");
break; break;
} }
} while (++$i<3); } while (++$i < 3);
include_once __DIR__ . '/../include/errors.inc'; include_once __DIR__ . '/../include/errors.inc';
error_noservice(); error_noservice();

View File

@@ -2,7 +2,7 @@
$_SERVER['BASE_PAGE'] = 'build-setup.php'; $_SERVER['BASE_PAGE'] = 'build-setup.php';
include_once __DIR__ . '/include/prepend.inc'; include_once __DIR__ . '/include/prepend.inc';
$SIDEBAR_DATA =' $SIDEBAR_DATA = '
<div class="panel"> <div class="panel">
<div class="body"> <div class="body">
<p> <p>
@@ -172,6 +172,6 @@ site_header("Operating System Preparation", ["current" => "community"]);
</p> </p>
</div> </div>
<?php <?php
site_footer(['sidebar'=>$SIDEBAR_DATA]); site_footer(['sidebar' => $SIDEBAR_DATA]);
/* vim: set et ts=4 sw=4 ft=php: : */ /* vim: set et ts=4 sw=4 ft=php: : */

View File

@@ -22,7 +22,7 @@ $abs = $pwd . "/" . (string)$_GET["f"];
$abs = realpath($abs); $abs = realpath($abs);
if (strncmp($abs, $pwd, strlen($pwd)) != 0) { if (strncmp($abs, $pwd, strlen($pwd)) != 0) {
header("Location: https://www.php.net/" . strtr($_GET["f"],["\r"=>"", "\n"=>""])); header("Location: https://www.php.net/" . strtr($_GET["f"],["\r" => "", "\n" => ""]));
exit; exit;
} }

34
cal.php
View File

@@ -126,7 +126,7 @@ if (count($errors) > 0) {
// Beginning and end of this month // Beginning and end of this month
$bom = mktime(0, 0, 1, $cm, 1, $cy); $bom = mktime(0, 0, 1, $cm, 1, $cy);
$eom = mktime(0, 0, 1, $cm+1, 0, $cy); $eom = mktime(0, 0, 1, $cm + 1, 0, $cy);
// Link to previous month (but do not link to too early dates) // Link to previous month (but do not link to too early dates)
$prev_link = (function () use ($cm, $cy) { $prev_link = (function () use ($cm, $cy) {
@@ -147,7 +147,7 @@ $prev_link = (function () use ($cm, $cy) {
// Link to next month (but do not link to too early dates) // Link to next month (but do not link to too early dates)
$next_link = (function () use ($cm, $cy) { $next_link = (function () use ($cm, $cy) {
$nm = mktime(0, 0, 1, $cm+1, 1, $cy); $nm = mktime(0, 0, 1, $cm + 1, 1, $cy);
$year = date('Y', $nm); $year = date('Y', $nm);
if (!valid_year($year)) { if (!valid_year($year)) {
return '&nbsp;'; return '&nbsp;';
@@ -174,7 +174,7 @@ echo '<table id="cal" width="100%" border="1" cellspacing="0" cellpadding="3">',
// Print out headers for weekdays // Print out headers for weekdays
for ($i = 0; $i < 7; $i++) { for ($i = 0; $i < 7; $i++) {
echo '<th width="14%">', date("l",mktime(0,0,1,4,$i+1,2001)), "</th>\n"; echo '<th width="14%">', date("l",mktime(0,0,1,4,$i + 1,2001)), "</th>\n";
} }
echo "</tr>\n<tr>"; echo "</tr>\n<tr>";
@@ -225,7 +225,7 @@ function date_for_recur($recur, $day, $bom, $eom)
$eomd = date("w",$eom) + 1; $eomd = date("w",$eom) + 1;
$days = (($eomd - $day + 7) % 7) + ((abs($recur) - 1) * 7); $days = (($eomd - $day + 7) % 7) + ((abs($recur) - 1) * 7);
return mktime(0, 0, 1, date("m", $bom)+1, -$days, date("Y", $bom)); return mktime(0, 0, 1, date("m", $bom) + 1, -$days, date("Y", $bom));
} }
// Display a <div> for each of the events that are on a given day // Display a <div> for each of the events that are on a given day
@@ -327,8 +327,8 @@ function load_events($from, $whole_month = false)
// Multi-day event // Multi-day event
case 2: case 2:
if (($event['start'] >= $from_date && $event['start'] <= $to_date) if (($event['start'] >= $from_date && $event['start'] <= $to_date)
|| ($event['end'] >= $from_date && $event['end'] <= $to_date) || ($event['end'] >= $from_date && $event['end'] <= $to_date)
|| ($event['start'] <= $from_date && $event['end'] >= $to_date)) { || ($event['start'] <= $from_date && $event['end'] >= $to_date)) {
$events[] = $event; $events[] = $event;
} }
break; break;
@@ -363,17 +363,17 @@ function read_event($fp)
// Return with SQL-resultset like array // Return with SQL-resultset like array
return [ return [
'id' => $id, 'id' => $id,
'type' => $tipo, 'type' => $tipo,
'start' => $sdato, 'start' => $sdato,
'end' => $edato, 'end' => $edato,
'recur' => $recur, 'recur' => $recur,
'recur_day' => $recur_day, 'recur_day' => $recur_day,
'sdesc' => $sdesc, 'sdesc' => $sdesc,
'url' => $url, 'url' => $url,
'ldesc' => base64_decode($ldesc, false), 'ldesc' => base64_decode($ldesc, false),
'country' => $country, 'country' => $country,
'category' => $category, 'category' => $category,
]; ];
} }
@@ -385,7 +385,7 @@ function valid_year($year)
$current_year = date("Y"); $current_year = date("Y");
// We only allow this and the next year for displays // We only allow this and the next year for displays
if ($year != $current_year && $year != $current_year+1) { if ($year != $current_year && $year != $current_year + 1) {
return false; return false;
} }

View File

@@ -3,10 +3,10 @@ $_SERVER['BASE_PAGE'] = 'conferences/index.php';
include_once __DIR__ . '/../include/prepend.inc'; include_once __DIR__ . '/../include/prepend.inc';
include_once __DIR__ . '/../include/pregen-news.inc'; include_once __DIR__ . '/../include/pregen-news.inc';
mirror_setcookie("LAST_NEWS", $_SERVER["REQUEST_TIME"], 60*60*24*365); mirror_setcookie("LAST_NEWS", $_SERVER["REQUEST_TIME"], 60 * 60 * 24 * 365);
site_header("PHP Conferences around the world", [ site_header("PHP Conferences around the world", [
'headtags' => '<link rel="alternate" type="application/atom+xml" title="PHP: Conference announcements" href="' . $MYSITE . 'feed.atom">', 'headtags' => '<link rel="alternate" type="application/atom+xml" title="PHP: Conference announcements" href="' . $MYSITE . 'feed.atom">',
'current' => 'community', 'current' => 'community',
'css' => ['home.css'], 'css' => ['home.css'],
]); ]);
@@ -28,7 +28,7 @@ $panels = '<p class="prepend"><a href="https://wiki.php.net/conferences">Want to
foreach ($frontpage as $entry) { foreach ($frontpage as $entry) {
$link = preg_replace('~^(http://php.net/|https://www.php.net/)~', '', $entry["id"]); $link = preg_replace('~^(http://php.net/|https://www.php.net/)~', '', $entry["id"]);
$id = parse_url($entry["id"], PHP_URL_FRAGMENT); $id = parse_url($entry["id"], PHP_URL_FRAGMENT);
$date = date_format(date_create($entry["updated"]), 'Y-m-d'); $date = date_format(date_create($entry["updated"]), 'Y-m-d');
$content .= '<div class="newsentry">'; $content .= '<div class="newsentry">';
$content .= '<h3 class="newstitle title"><a href="' . $MYSITE . $link . '" id="' . $id . '">' . $entry["title"] . '</a></h3>'; $content .= '<h3 class="newstitle title"><a href="' . $MYSITE . $link . '" id="' . $id . '">' . $entry["title"] . '</a></h3>';

View File

@@ -7,7 +7,7 @@ if (!empty($_GET['active_langs'])) {
exit; exit;
} }
$SIDEBAR_DATA=' $SIDEBAR_DATA = '
<div class="panel"> <div class="panel">
<div class="headline">Online documentation</div> <div class="headline">Online documentation</div>
<div class="body"> <div class="body">
@@ -42,8 +42,8 @@ site_header("Download documentation", ["current" => "docs"]);
// Format to look for // Format to look for
$formats = [ $formats = [
"Single HTML file" => "html.gz", "Single HTML file" => "html.gz",
"Many HTML files" => "tar.gz", "Many HTML files" => "tar.gz",
"HTML Help file" => "chm", "HTML Help file" => "chm",
"HTML Help file (with user notes)" => "chm", "HTML Help file (with user notes)" => "chm",
]; ];
?> ?>
@@ -114,14 +114,14 @@ foreach ($LANGUAGES as $langcode => $language) {
$link_to = "/distributions/manual/$filename"; $link_to = "/distributions/manual/$filename";
// Try to get size and changed date // Try to get size and changed date
$size = @filesize($filepath); $size = @filesize($filepath);
$changed = @filemtime($filepath); $changed = @filemtime($filepath);
// Size available, collect information // Size available, collect information
if ($size !== false) { if ($size !== false) {
$files[$langcode][$formatname] = [ $files[$langcode][$formatname] = [
$link_to, $link_to,
(int) ($size/1024), (int) ($size / 1024),
date("j M Y", $changed), date("j M Y", $changed),
$extension $extension
]; ];

View File

@@ -22,7 +22,7 @@ function print_star(): void
function random_bgcolor($min, $max): void function random_bgcolor($min, $max): void
{ {
echo "style=\"background-color: #" . echo "style=\"background-color: #" .
sprintf('%02x%02x%02x', rand($min, $max)*51, rand($min, $max)*51, rand($min, $max)*51) . sprintf('%02x%02x%02x', rand($min, $max) * 51, rand($min, $max) * 51, rand($min, $max) * 51) .
";\""; ";\"";
} }
?> ?>

View File

@@ -29,9 +29,9 @@ site_header("Downloads",
[ [
'link' => [ 'link' => [
[ [
"rel" => "alternate", "rel" => "alternate",
"type" => "application/atom+xml", "type" => "application/atom+xml",
"href" => $MYSITE . "releases/feed.php", "href" => $MYSITE . "releases/feed.php",
"title" => "PHP Release feed" "title" => "PHP Release feed"
], ],
], ],

624
error.php
View File

@@ -213,41 +213,41 @@ if ($path = is_known_term($term)) {
// new URLs for these pages. // new URLs for these pages.
$manual_page_moves = [ $manual_page_moves = [
// entry point changed // entry point changed
'installation' => 'install', 'installation' => 'install',
// was split among platforms (don't know where to redirect) // was split among platforms (don't know where to redirect)
'install.apache' => 'install', 'install.apache' => 'install',
'install.apache2' => 'install', 'install.apache2' => 'install',
'install.netscape-enterprise'=> 'install', 'install.netscape-enterprise' => 'install',
'install.otherhttpd' => 'install', 'install.otherhttpd' => 'install',
// moved to platform sections // moved to platform sections
'install.caudium' => 'install.unix.caudium', 'install.caudium' => 'install.unix.caudium',
'install.commandline' => 'install.unix.commandline', 'install.commandline' => 'install.unix.commandline',
'install.fhttpd' => 'install.unix.fhttpd', 'install.fhttpd' => 'install.unix.fhttpd',
'install.hpux' => 'install.unix.hpux', 'install.hpux' => 'install.unix.hpux',
'install.iis' => 'install.windows.iis', 'install.iis' => 'install.windows.iis',
'install.linux' => 'install.unix', 'install.linux' => 'install.unix',
'install.omnihttpd' => 'install.windows.omnihttpd', 'install.omnihttpd' => 'install.windows.omnihttpd',
'install.openbsd' => 'install.unix.openbsd', 'install.openbsd' => 'install.unix.openbsd',
'install.sambar' => 'install.windows.sambar', 'install.sambar' => 'install.windows.sambar',
'install.solaris' => 'install.unix.solaris', 'install.solaris' => 'install.unix.solaris',
'install.xitami' => 'install.windows.xitami', 'install.xitami' => 'install.windows.xitami',
'install.windows.installer.msi' => 'install.windows', 'install.windows.installer.msi' => 'install.windows',
'install.windows.installer' => 'install.windows', 'install.windows.installer' => 'install.windows',
// Internals docs where moved // Internals docs where moved
'zend' => 'internals2.ze1.zendapi', 'zend' => 'internals2.ze1.zendapi',
'zend-api' => 'internals2.ze1.zendapi', 'zend-api' => 'internals2.ze1.zendapi',
'internals.pdo' => 'internals2.pdo', 'internals.pdo' => 'internals2.pdo',
'phpdevel' => 'internals2.ze1.php3devel', 'phpdevel' => 'internals2.ze1.php3devel',
'tsrm' => 'internals2.ze1.tsrm', 'tsrm' => 'internals2.ze1.tsrm',
// Replaced extensions // Replaced extensions
'aspell' => 'pspell', 'aspell' => 'pspell',
// Refactored // Refactored
'regexp.reference' => 'regexp.introduction', 'regexp.reference' => 'regexp.introduction',
]; ];
if (isset($manual_page_moves[$URI])) { if (isset($manual_page_moves[$URI])) {
@@ -260,36 +260,36 @@ if (isset($manual_page_moves[$URI])) {
} }
$manual_redirections = [ $manual_redirections = [
'class.oci-lob' => 'class.ocilob', 'class.oci-lob' => 'class.ocilob',
'oci-lob.append' => 'ocilob.append', 'oci-lob.append' => 'ocilob.append',
'oci-lob.close' => 'ocilob.close', 'oci-lob.close' => 'ocilob.close',
'oci-lob.eof' => 'ocilob.eof', 'oci-lob.eof' => 'ocilob.eof',
'oci-lob.erase' => 'ocilob.erase', 'oci-lob.erase' => 'ocilob.erase',
'oci-lob.export' => 'ocilob.export', 'oci-lob.export' => 'ocilob.export',
'oci-lob.flush' => 'ocilob.flush', 'oci-lob.flush' => 'ocilob.flush',
'oci-lob.free' => 'ocilob.free', 'oci-lob.free' => 'ocilob.free',
'oci-lob.getbuffering' => 'ocilob.getbuffering', 'oci-lob.getbuffering' => 'ocilob.getbuffering',
'oci-lob.import' => 'ocilob.import', 'oci-lob.import' => 'ocilob.import',
'oci-lob.load' => 'ocilob.load', 'oci-lob.load' => 'ocilob.load',
'oci-lob.read' => 'ocilob.read', 'oci-lob.read' => 'ocilob.read',
'oci-lob.rewind' => 'ocilob.rewind', 'oci-lob.rewind' => 'ocilob.rewind',
'oci-lob.save' => 'ocilob.save', 'oci-lob.save' => 'ocilob.save',
'oci-lob.seek' => 'ocilob.seek', 'oci-lob.seek' => 'ocilob.seek',
'oci-lob.setbuffering' => 'ocilob.setbuffering', 'oci-lob.setbuffering' => 'ocilob.setbuffering',
'oci-lob.size' => 'ocilob.size', 'oci-lob.size' => 'ocilob.size',
'oci-lob.tell' => 'ocilob.tell', 'oci-lob.tell' => 'ocilob.tell',
'oci-lob.truncate' => 'ocilob.truncate', 'oci-lob.truncate' => 'ocilob.truncate',
'oci-lob.write' => 'ocilob.write', 'oci-lob.write' => 'ocilob.write',
'oci-lob.writetemporary' => 'ocilob.writetemporary', 'oci-lob.writetemporary' => 'ocilob.writetemporary',
'class.oci-collection' => 'class.ocicollection', 'class.oci-collection' => 'class.ocicollection',
'oci-collection.append' => 'ocicollection.append', 'oci-collection.append' => 'ocicollection.append',
'oci-collection.assign' => 'ocicollection.assign', 'oci-collection.assign' => 'ocicollection.assign',
'oci-collection.assignelem' => 'ocicollection.assignelem', 'oci-collection.assignelem' => 'ocicollection.assignelem',
'oci-collection.free' => 'ocicollection.free', 'oci-collection.free' => 'ocicollection.free',
'oci-collection.getelem' => 'ocicollection.getelem', 'oci-collection.getelem' => 'ocicollection.getelem',
'oci-collection.max' => 'ocicollection.max', 'oci-collection.max' => 'ocicollection.max',
'oci-collection.size' => 'ocicollection.size', 'oci-collection.size' => 'ocicollection.size',
'oci-collection.trim' => 'ocicollection.trim', 'oci-collection.trim' => 'ocicollection.trim',
]; ];
if (preg_match("!^manual/([^/]+)/([^/]+)$!", $URI, $match) && isset($manual_redirections[$match[2]])) { if (preg_match("!^manual/([^/]+)/([^/]+)$!", $URI, $match) && isset($manual_redirections[$match[2]])) {
@@ -299,330 +299,330 @@ if (preg_match("!^manual/([^/]+)/([^/]+)$!", $URI, $match) && isset($manual_redi
// ============================================================================ // ============================================================================
// Define shortcuts for PHP files, manual pages and external redirects // Define shortcuts for PHP files, manual pages and external redirects
$uri_aliases = [ $uri_aliases = [
# PHP page shortcuts # PHP page shortcuts
"download" => "downloads", "download" => "downloads",
"getphp" => "downloads", "getphp" => "downloads",
"getdocs" => "download-docs", "getdocs" => "download-docs",
"documentation" => "docs", "documentation" => "docs",
"mailinglists" => "mailing-lists", "mailinglists" => "mailing-lists",
"mailinglist" => "mailing-lists", "mailinglist" => "mailing-lists",
"changelog" => "ChangeLog-7", "changelog" => "ChangeLog-7",
"gethelp" => "support", "gethelp" => "support",
"help" => "support", "help" => "support",
"unsubscribe" => "unsub", "unsubscribe" => "unsub",
"subscribe" => "mailing-lists", "subscribe" => "mailing-lists",
"logos" => "download-logos", "logos" => "download-logos",
# manual shortcuts # manual shortcuts
"intro" => "introduction", "intro" => "introduction",
"whatis" => "introduction", "whatis" => "introduction",
"whatisphp" => "introduction", "whatisphp" => "introduction",
"what_is_php" => "introduction", "what_is_php" => "introduction",
"windows" => "install.windows", "windows" => "install.windows",
"win32" => "install.windows", "win32" => "install.windows",
"globals" => "language.variables.predefined", "globals" => "language.variables.predefined",
"register_globals" => "security.globals", "register_globals" => "security.globals",
"registerglobals" => "security.globals", "registerglobals" => "security.globals",
"manual/en/security.registerglobals.php" => "security.globals", // fix for 4.3.8 configure "manual/en/security.registerglobals.php" => "security.globals", // fix for 4.3.8 configure
"magic_quotes" => "security.magicquotes", "magic_quotes" => "security.magicquotes",
"magicquotes" => "security.magicquotes", "magicquotes" => "security.magicquotes",
"gd" => "image", "gd" => "image",
"bcmath" => "bc", "bcmath" => "bc",
'streams' => 'book.stream', 'streams' => 'book.stream',
"mongodb" => "set.mongodb", "mongodb" => "set.mongodb",
"hrtime" => "function.hrtime", // Prefer function over PECL ext "hrtime" => "function.hrtime", // Prefer function over PECL ext
"callback" => "language.pseudo-types", "callback" => "language.pseudo-types",
"number" => "language.pseudo-types", "number" => "language.pseudo-types",
"mixed" => "language.pseudo-types", "mixed" => "language.pseudo-types",
"bool" => "language.types.boolean", "bool" => "language.types.boolean",
"boolean" => "language.types.boolean", "boolean" => "language.types.boolean",
"int" => "language.types.integer", "int" => "language.types.integer",
"integer" => "language.types.integer", "integer" => "language.types.integer",
"float" => "language.types.float", "float" => "language.types.float",
"string" => "language.types.string", "string" => "language.types.string",
"heredoc" => "language.types.string", "heredoc" => "language.types.string",
"<<<" => "language.types.string", "<<<" => "language.types.string",
"object" => "language.types.object", "object" => "language.types.object",
"null" => "language.types.null", "null" => "language.types.null",
'callable' => 'language.types.callable', 'callable' => 'language.types.callable',
"htaccess" => "configuration.changes", "htaccess" => "configuration.changes",
"php_value" => "configuration.changes", "php_value" => "configuration.changes",
"ternary" => "language.operators.comparison", "ternary" => "language.operators.comparison",
"instanceof" => "language.operators.type", "instanceof" => "language.operators.type",
"if" => "language.control-structures", "if" => "language.control-structures",
"static" => "language.variables.scope", "static" => "language.variables.scope",
"global" => "language.variables.scope", "global" => "language.variables.scope",
"@" => "language.operators.errorcontrol", "@" => "language.operators.errorcontrol",
"&" => "language.references", "&" => "language.references",
"**" => "language.operators.arithmetic", "**" => "language.operators.arithmetic",
"..." => "functions.arguments", "..." => "functions.arguments",
"splat" => "functions.arguments", "splat" => "functions.arguments",
"arrow" => "functions.arrow", "arrow" => "functions.arrow",
"fn" => "functions.arrow", "fn" => "functions.arrow",
// ?:, ??, ??= // ?:, ??, ??=
// These shortcuts can not be captured here since they // These shortcuts can not be captured here since they
// don't actually produce a 404 error. // don't actually produce a 404 error.
// Instead, we have a small check in index.php directly. // Instead, we have a small check in index.php directly.
"dowhile" => "control-structures.do.while", "dowhile" => "control-structures.do.while",
"tut" => "tutorial", "tut" => "tutorial",
"tut.php" => "tutorial", // BC "tut.php" => "tutorial", // BC
"faq.php" => "faq", // BC "faq.php" => "faq", // BC
"bugs.php" => "bugs", // BC "bugs.php" => "bugs", // BC
"bugstats.php" => "bugstats", // BC "bugstats.php" => "bugstats", // BC
"docs-echm.php"=> "download-docs", // BC "docs-echm.php" => "download-docs", // BC
"odbc" => "uodbc", // BC "odbc" => "uodbc", // BC
"links" => "support", // BC "links" => "support", // BC
"links.php" => "support", // BC "links.php" => "support", // BC
"oracle" => "oci8", "oracle" => "oci8",
"_" => "function.gettext", "_" => "function.gettext",
"cli" => "features.commandline", "cli" => "features.commandline",
"oop" => "language.oop5", "oop" => "language.oop5",
"enum" => "language.enumerations", "enum" => "language.enumerations",
"enums" => "language.enumerations", "enums" => "language.enumerations",
"const" => "language.constants.syntax", "const" => "language.constants.syntax",
"class" => "language.oop5.basic", "class" => "language.oop5.basic",
"new" => "language.oop5.basic", "new" => "language.oop5.basic",
"extends" => "language.oop5.basic", "extends" => "language.oop5.basic",
"clone" => "language.oop5.cloning", "clone" => "language.oop5.cloning",
"construct" => "language.oop5.decon", "construct" => "language.oop5.decon",
"destruct" => "language.oop5.decon", "destruct" => "language.oop5.decon",
"public" => "language.oop5.visibility", "public" => "language.oop5.visibility",
"private" => "language.oop5.visibility", "private" => "language.oop5.visibility",
"protected" => "language.oop5.visibility", "protected" => "language.oop5.visibility",
"var" => "language.oop5.visibility", "var" => "language.oop5.visibility",
"abstract" => "language.oop5.abstract", "abstract" => "language.oop5.abstract",
"interface" => "language.oop5.interfaces", "interface" => "language.oop5.interfaces",
"interfaces" => "language.oop5.interfaces", "interfaces" => "language.oop5.interfaces",
"autoload" => "language.oop5.autoload", "autoload" => "language.oop5.autoload",
"__autoload" => "language.oop5.autoload", "__autoload" => "language.oop5.autoload",
"language.oop5.reflection" => "book.reflection", // BC "language.oop5.reflection" => "book.reflection", // BC
"::" => "language.oop5.paamayim-nekudotayim", "::" => "language.oop5.paamayim-nekudotayim",
"__construct" => "language.oop5.decon", "__construct" => "language.oop5.decon",
"__destruct" => "language.oop5.decon", "__destruct" => "language.oop5.decon",
"__call" => "language.oop5.overloading", "__call" => "language.oop5.overloading",
"__callstatic" => "language.oop5.overloading", "__callstatic" => "language.oop5.overloading",
"__get" => "language.oop5.overloading", "__get" => "language.oop5.overloading",
"__set" => "language.oop5.overloading", "__set" => "language.oop5.overloading",
"__isset" => "language.oop5.overloading", "__isset" => "language.oop5.overloading",
"__unset" => "language.oop5.overloading", "__unset" => "language.oop5.overloading",
"__sleep" => "language.oop5.magic", "__sleep" => "language.oop5.magic",
"__wakeup" => "language.oop5.magic", "__wakeup" => "language.oop5.magic",
"__tostring" => "language.oop5.magic", "__tostring" => "language.oop5.magic",
"__set_state" => "language.oop5.magic", "__set_state" => "language.oop5.magic",
"__debuginfo" => "language.oop5.magic", "__debuginfo" => "language.oop5.magic",
"__clone" => "language.oop5.cloning", "__clone" => "language.oop5.cloning",
"throw" => "language.exceptions", "throw" => "language.exceptions",
"try" => "language.exceptions", "try" => "language.exceptions",
"catch" => "language.exceptions", "catch" => "language.exceptions",
"lsb" => "language.oop5.late-static-bindings", "lsb" => "language.oop5.late-static-bindings",
"namespace" => "language.namespaces", "namespace" => "language.namespaces",
"use" => "language.namespaces.using", "use" => "language.namespaces.using",
"iterator" => "language.oop5.iterations", "iterator" => "language.oop5.iterations",
"factory" => "language.oop5.patterns", "factory" => "language.oop5.patterns",
"singleton" => "language.oop5.patterns", "singleton" => "language.oop5.patterns",
"trait" => "language.oop5.traits", "trait" => "language.oop5.traits",
"traits" => "language.oop5.traits", "traits" => "language.oop5.traits",
"news.php" => "archive/index", // BC "news.php" => "archive/index", // BC
"readme.mirror" => "mirroring", // BC "readme.mirror" => "mirroring", // BC
"php5" => "language.oop5", "php5" => "language.oop5",
"zend_changes.txt" => "language.oop5", // BC "zend_changes.txt" => "language.oop5", // BC
"zend2_example.phps" => "language.oop5", // BC "zend2_example.phps" => "language.oop5", // BC
"zend_changes_php_5_0_0b2.txt" => "language.oop5", // BC "zend_changes_php_5_0_0b2.txt" => "language.oop5", // BC
"zend-engine-2" => "language.oop5", // BC "zend-engine-2" => "language.oop5", // BC
"zend-engine-2.php" => "language.oop5", // BC "zend-engine-2.php" => "language.oop5", // BC
"news_php_5_0_0b2.txt" => "ChangeLog-5", // BC "news_php_5_0_0b2.txt" => "ChangeLog-5", // BC
"news_php_5_0_0b3.txt" => "ChangeLog-5", // BC "news_php_5_0_0b3.txt" => "ChangeLog-5", // BC
"manual/about-notes.php" => "manual/add-note", // BC "manual/about-notes.php" => "manual/add-note", // BC
"software/index.php" => "software", // BC "software/index.php" => "software", // BC
"releases.php" => "releases/index", // BC "releases.php" => "releases/index", // BC
"migration7" => "migration70", // Consistent with migration5 "migration7" => "migration70", // Consistent with migration5
"update_5_2.txt" => "migration52", // BC "update_5_2.txt" => "migration52", // BC
"readme_upgrade_51.php" => "migration51", // BC "readme_upgrade_51.php" => "migration51", // BC
"internals" => "internals2", // BC "internals" => "internals2", // BC
"configuration.directives" => "ini.core", // BC "configuration.directives" => "ini.core", // BC
# regexp. BC # regexp. BC
"regexp.reference.backslash" => "regexp.reference.escape", "regexp.reference.backslash" => "regexp.reference.escape",
"regexp.reference.circudollar" => "regexp.reference.anchors", "regexp.reference.circudollar" => "regexp.reference.anchors",
"regexp.reference.squarebrackets" => "regexp.reference.character-classes", "regexp.reference.squarebrackets" => "regexp.reference.character-classes",
"regexp.reference.verticalbar" => "regexp.reference.alternation", "regexp.reference.verticalbar" => "regexp.reference.alternation",
# external shortcut aliases ;) # external shortcut aliases ;)
"dochowto" => "phpdochowto", "dochowto" => "phpdochowto",
# CVS -> SVN # CVS -> SVN
"anoncvs.php" => "git", "anoncvs.php" => "git",
"cvs-php.php" => "git-php", "cvs-php.php" => "git-php",
# SVN -> Git # SVN -> Git
"svn" => "git", "svn" => "git",
"svn.php" => "git", "svn.php" => "git",
"svn-php" => "git-php", "svn-php" => "git-php",
"svn-php.php" => "git-php", "svn-php.php" => "git-php",
# CVSUp -> Nada # CVSUp -> Nada
"cvsup" => "mirroring", "cvsup" => "mirroring",
# Other items # Other items
"security/crypt" => "security/crypt_blowfish", "security/crypt" => "security/crypt_blowfish",
# Bugfixes # Bugfixes
"array_sort" => "sort", // #64743 "array_sort" => "sort", // #64743
"array-sort" => "sort", // #64743 "array-sort" => "sort", // #64743
# Removed pages # Removed pages
"tips.php" => "urlhowto", "tips.php" => "urlhowto",
"tips" => "urlhowto", "tips" => "urlhowto",
]; ];
$external_redirects = [ $external_redirects = [
"php4news" => "https://github.com/php/php-src/raw/PHP-4.4/NEWS", "php4news" => "https://github.com/php/php-src/raw/PHP-4.4/NEWS",
"php5news" => "https://github.com/php/php-src/raw/PHP-5.6/NEWS", "php5news" => "https://github.com/php/php-src/raw/PHP-5.6/NEWS",
"php53news" => "https://github.com/php/php-src/raw/PHP-5.3/NEWS", "php53news" => "https://github.com/php/php-src/raw/PHP-5.3/NEWS",
"php54news" => "https://github.com/php/php-src/raw/PHP-5.4/NEWS", "php54news" => "https://github.com/php/php-src/raw/PHP-5.4/NEWS",
"php55news" => "https://github.com/php/php-src/raw/PHP-5.5/NEWS", "php55news" => "https://github.com/php/php-src/raw/PHP-5.5/NEWS",
"php56news" => "https://github.com/php/php-src/raw/PHP-5.6/NEWS", "php56news" => "https://github.com/php/php-src/raw/PHP-5.6/NEWS",
"php70news" => "https://github.com/php/php-src/raw/PHP-7.0/NEWS", "php70news" => "https://github.com/php/php-src/raw/PHP-7.0/NEWS",
"php71news" => "https://github.com/php/php-src/raw/PHP-7.1/NEWS", "php71news" => "https://github.com/php/php-src/raw/PHP-7.1/NEWS",
"php72news" => "https://github.com/php/php-src/raw/PHP-7.2/NEWS", "php72news" => "https://github.com/php/php-src/raw/PHP-7.2/NEWS",
"php73news" => "https://github.com/php/php-src/raw/PHP-7.3/NEWS", "php73news" => "https://github.com/php/php-src/raw/PHP-7.3/NEWS",
"php74news" => "https://github.com/php/php-src/raw/PHP-7.4/NEWS", "php74news" => "https://github.com/php/php-src/raw/PHP-7.4/NEWS",
"php80news" => "https://github.com/php/php-src/raw/PHP-8.0/NEWS", "php80news" => "https://github.com/php/php-src/raw/PHP-8.0/NEWS",
"phptrunknews"=> "https://github.com/php/php-src/raw/master/NEWS", "phptrunknews" => "https://github.com/php/php-src/raw/master/NEWS",
"pear" => "http://pear.php.net/", "pear" => "http://pear.php.net/",
"bugs" => "https://bugs.php.net/", "bugs" => "https://bugs.php.net/",
"bugstats" => "https://bugs.php.net/stats.php", "bugstats" => "https://bugs.php.net/stats.php",
"phpdochowto" => "http://doc.php.net/tutorial/", "phpdochowto" => "http://doc.php.net/tutorial/",
"rev" => "http://doc.php.net/revcheck.php?p=graph&lang=$LANG", "rev" => "http://doc.php.net/revcheck.php?p=graph&lang=$LANG",
"release/5_3_0.php" => "/releases/5_3_0.php", // PHP 5.3.0 release announcement had a typo "release/5_3_0.php" => "/releases/5_3_0.php", // PHP 5.3.0 release announcement had a typo
"ideas.php" => "http://wiki.php.net/ideas", // BC "ideas.php" => "http://wiki.php.net/ideas", // BC
"releases.atom" => "/releases/feed.php", // BC, No need to pre-generate it "releases.atom" => "/releases/feed.php", // BC, No need to pre-generate it
"spec" => "https://github.com/php/php-langspec", "spec" => "https://github.com/php/php-langspec",
"sunglasses" => "https://www.youtube.com/watch?v=dQw4w9WgXcQ", // Temporary easter egg for bug#66144 "sunglasses" => "https://www.youtube.com/watch?v=dQw4w9WgXcQ", // Temporary easter egg for bug#66144
]; ];
// Temporary hack to fix bug #49956 for mysqli -- Please don't hate me for this. Data taken from mysqli/summary.xml // Temporary hack to fix bug #49956 for mysqli -- Please don't hate me for this. Data taken from mysqli/summary.xml
$mysqli_redirects = [ $mysqli_redirects = [
"mysqli_affected_rows" => "mysqli.affected-rows", "mysqli_affected_rows" => "mysqli.affected-rows",
"mysqli_get_client_version" => "mysqli.client-version", "mysqli_get_client_version" => "mysqli.client-version",
"mysqli_connect_errno" => "mysqli.connect-errno", "mysqli_connect_errno" => "mysqli.connect-errno",
"mysqli_connect_error" => "mysqli.connect-error", "mysqli_connect_error" => "mysqli.connect-error",
"mysqli_errno" => "mysqli.errno", "mysqli_errno" => "mysqli.errno",
"mysqli_error" => "mysqli.error", "mysqli_error" => "mysqli.error",
"mysqli_field_count" => "mysqli.field-count", "mysqli_field_count" => "mysqli.field-count",
"mysqli_get_host_info" => "mysqli.host-info", "mysqli_get_host_info" => "mysqli.host-info",
"mysqli_get_proto_info" => "mysqli.protocol-version", "mysqli_get_proto_info" => "mysqli.protocol-version",
"mysqli_get_server_version" => "mysqli.server-version", "mysqli_get_server_version" => "mysqli.server-version",
"mysqli_info" => "mysqli.info", "mysqli_info" => "mysqli.info",
"mysqli_insert_id" => "mysqli.insert-id", "mysqli_insert_id" => "mysqli.insert-id",
"mysqli_sqlstate" => "mysqli.sqlstate", "mysqli_sqlstate" => "mysqli.sqlstate",
"mysqli_warning_count" => "mysqli.warning-count", "mysqli_warning_count" => "mysqli.warning-count",
"mysqli_autocommit" => "mysqli.autocommit", "mysqli_autocommit" => "mysqli.autocommit",
"mysqli_change_user" => "mysqli.change-user", "mysqli_change_user" => "mysqli.change-user",
"mysqli_character_set_name" => "mysqli.character-set-name", "mysqli_character_set_name" => "mysqli.character-set-name",
"mysqli_close" => "mysqli.close", "mysqli_close" => "mysqli.close",
"mysqli_commit" => "mysqli.commit", "mysqli_commit" => "mysqli.commit",
"mysqli_connect" => "mysqli.construct", "mysqli_connect" => "mysqli.construct",
"mysqli_debug" => "mysqli.debug", "mysqli_debug" => "mysqli.debug",
"mysqli_dump_debug_info" => "mysqli.dump-debug-info", "mysqli_dump_debug_info" => "mysqli.dump-debug-info",
"mysqli_get_charset" => "mysqli.get-charset", "mysqli_get_charset" => "mysqli.get-charset",
"mysqli_get_connection_stats" => "mysqli.get-connection-stats", "mysqli_get_connection_stats" => "mysqli.get-connection-stats",
"mysqli_get_client_info" => "mysqli.get-client-info", "mysqli_get_client_info" => "mysqli.get-client-info",
"mysqli_get_client_stats" => "mysqli.get-client-stats", "mysqli_get_client_stats" => "mysqli.get-client-stats",
"mysqli_get_cache_stats" => "mysqli.get-cache-stats", "mysqli_get_cache_stats" => "mysqli.get-cache-stats",
"mysqli_get_server_info" => "mysqli.get-server-info", "mysqli_get_server_info" => "mysqli.get-server-info",
"mysqli_get_warnings" => "mysqli.get-warnings", "mysqli_get_warnings" => "mysqli.get-warnings",
"mysqli_init" => "mysqli.init", "mysqli_init" => "mysqli.init",
"mysqli_kill" => "mysqli.kill", "mysqli_kill" => "mysqli.kill",
"mysqli_more_results" => "mysqli.more-results", "mysqli_more_results" => "mysqli.more-results",
"mysqli_multi_query" => "mysqli.multi-query", "mysqli_multi_query" => "mysqli.multi-query",
"mysqli_next_result" => "mysqli.next-result", "mysqli_next_result" => "mysqli.next-result",
"mysqli_options" => "mysqli.options", "mysqli_options" => "mysqli.options",
"mysqli_ping" => "mysqli.ping", "mysqli_ping" => "mysqli.ping",
"mysqli_prepare" => "mysqli.prepare", "mysqli_prepare" => "mysqli.prepare",
"mysqli_query" => "mysqli.query", "mysqli_query" => "mysqli.query",
"mysqli_real_connect" => "mysqli.real-connect", "mysqli_real_connect" => "mysqli.real-connect",
"mysqli_real_escape_string" => "mysqli.real-escape-string", "mysqli_real_escape_string" => "mysqli.real-escape-string",
"mysqli_real_query" => "mysqli.real-query", "mysqli_real_query" => "mysqli.real-query",
"mysqli_refresh" => "mysqli.refresh", "mysqli_refresh" => "mysqli.refresh",
"mysqli_rollback" => "mysqli.rollback", "mysqli_rollback" => "mysqli.rollback",
"mysqli_select_db" => "mysqli.select-db", "mysqli_select_db" => "mysqli.select-db",
"mysqli_set_charset" => "mysqli.set-charset", "mysqli_set_charset" => "mysqli.set-charset",
"mysqli_set_local_infile_default" => "mysqli.set-local-infile-default", "mysqli_set_local_infile_default" => "mysqli.set-local-infile-default",
"mysqli_set_local_infile_handler" => "mysqli.set-local-infile-handler", "mysqli_set_local_infile_handler" => "mysqli.set-local-infile-handler",
"mysqli_ssl_set" => "mysqli.ssl-set", "mysqli_ssl_set" => "mysqli.ssl-set",
"mysqli_stat" => "mysqli.stat", "mysqli_stat" => "mysqli.stat",
"mysqli_stmt_init" => "mysqli.stmt-init", "mysqli_stmt_init" => "mysqli.stmt-init",
"mysqli_store_result" => "mysqli.store-result", "mysqli_store_result" => "mysqli.store-result",
"mysqli_thread_id" => "mysqli.thread-id", "mysqli_thread_id" => "mysqli.thread-id",
"mysqli_thread_safe" => "mysqli.thread-safe", "mysqli_thread_safe" => "mysqli.thread-safe",
"mysqli_use_result" => "mysqli.use-result", "mysqli_use_result" => "mysqli.use-result",
"mysqli_stmt_affected_rows" => "mysqli-stmt.affected-rows", "mysqli_stmt_affected_rows" => "mysqli-stmt.affected-rows",
"mysqli_stmt_errno" => "mysqli-stmt.errno", "mysqli_stmt_errno" => "mysqli-stmt.errno",
"mysqli_stmt_error" => "mysqli-stmt.error", "mysqli_stmt_error" => "mysqli-stmt.error",
"mysqli_stmt_field_count" => "mysqli-stmt.field-count", "mysqli_stmt_field_count" => "mysqli-stmt.field-count",
"mysqli_stmt_insert_id" => "mysqli-stmt.insert-id", "mysqli_stmt_insert_id" => "mysqli-stmt.insert-id",
"mysqli_stmt_param_count" => "mysqli-stmt.param-count", "mysqli_stmt_param_count" => "mysqli-stmt.param-count",
"mysqli_stmt_sqlstate" => "mysqli-stmt.sqlstate", "mysqli_stmt_sqlstate" => "mysqli-stmt.sqlstate",
"mysqli_stmt_attr_get" => "mysqli-stmt.attr-get", "mysqli_stmt_attr_get" => "mysqli-stmt.attr-get",
"mysqli_stmt_attr_set" => "mysqli-stmt.attr-set", "mysqli_stmt_attr_set" => "mysqli-stmt.attr-set",
"mysqli_stmt_bind_param" => "mysqli-stmt.bind-param", "mysqli_stmt_bind_param" => "mysqli-stmt.bind-param",
"mysqli_stmt_bind_result" => "mysqli-stmt.bind-result", "mysqli_stmt_bind_result" => "mysqli-stmt.bind-result",
"mysqli_stmt_close" => "mysqli-stmt.close", "mysqli_stmt_close" => "mysqli-stmt.close",
"mysqli_stmt_data_seek" => "mysqli-stmt.data-seek", "mysqli_stmt_data_seek" => "mysqli-stmt.data-seek",
"mysqli_stmt_execute" => "mysqli-stmt.execute", "mysqli_stmt_execute" => "mysqli-stmt.execute",
"mysqli_stmt_fetch" => "mysqli-stmt.fetch", "mysqli_stmt_fetch" => "mysqli-stmt.fetch",
"mysqli_stmt_free_result" => "mysqli-stmt.free-result", "mysqli_stmt_free_result" => "mysqli-stmt.free-result",
"mysqli_stmt_get_result" => "mysqli-stmt.get-result", "mysqli_stmt_get_result" => "mysqli-stmt.get-result",
"mysqli_stmt_get_warnings" => "mysqli-stmt.get-warnings", "mysqli_stmt_get_warnings" => "mysqli-stmt.get-warnings",
"mysqli_stmt_more_results" => "mysqli-stmt.more-results", "mysqli_stmt_more_results" => "mysqli-stmt.more-results",
"mysqli_stmt_next_result" => "mysqli-stmt.next-result", "mysqli_stmt_next_result" => "mysqli-stmt.next-result",
"mysqli_stmt_num_rows" => "mysqli-stmt.num-rows", "mysqli_stmt_num_rows" => "mysqli-stmt.num-rows",
"mysqli_stmt_prepare" => "mysqli-stmt.prepare", "mysqli_stmt_prepare" => "mysqli-stmt.prepare",
"mysqli_stmt_reset" => "mysqli-stmt.reset", "mysqli_stmt_reset" => "mysqli-stmt.reset",
"mysqli_stmt_result_metadata" => "mysqli-stmt.result-metadata", "mysqli_stmt_result_metadata" => "mysqli-stmt.result-metadata",
"mysqli_stmt_send_long_data" => "mysqli-stmt.send-long-data", "mysqli_stmt_send_long_data" => "mysqli-stmt.send-long-data",
"mysqli_stmt_store_result" => "mysqli-stmt.store-result", "mysqli_stmt_store_result" => "mysqli-stmt.store-result",
"mysqli_field_tell" => "mysqli-result.current-field", "mysqli_field_tell" => "mysqli-result.current-field",
"mysqli_num_fields" => "mysqli-result.field-count", "mysqli_num_fields" => "mysqli-result.field-count",
"mysqli_fetch_lengths" => "mysqli-result.lengths", "mysqli_fetch_lengths" => "mysqli-result.lengths",
"mysqli_num_rows" => "mysqli-result.num-rows", "mysqli_num_rows" => "mysqli-result.num-rows",
"mysqli_data_seek" => "mysqli-result.data-seek", "mysqli_data_seek" => "mysqli-result.data-seek",
"mysqli_fetch_all" => "mysqli-result.fetch-all", "mysqli_fetch_all" => "mysqli-result.fetch-all",
"mysqli_fetch_array" => "mysqli-result.fetch-array", "mysqli_fetch_array" => "mysqli-result.fetch-array",
"mysqli_fetch_assoc" => "mysqli-result.fetch-assoc", "mysqli_fetch_assoc" => "mysqli-result.fetch-assoc",
"mysqli_fetch_field_direct" => "mysqli-result.fetch-field-direct", "mysqli_fetch_field_direct" => "mysqli-result.fetch-field-direct",
"mysqli_fetch_field" => "mysqli-result.fetch-field", "mysqli_fetch_field" => "mysqli-result.fetch-field",
"mysqli_fetch_fields" => "mysqli-result.fetch-fields", "mysqli_fetch_fields" => "mysqli-result.fetch-fields",
"mysqli_fetch_object" => "mysqli-result.fetch-object", "mysqli_fetch_object" => "mysqli-result.fetch-object",
"mysqli_fetch_row" => "mysqli-result.fetch-row", "mysqli_fetch_row" => "mysqli-result.fetch-row",
"mysqli_field_seek" => "mysqli-result.field-seek", "mysqli_field_seek" => "mysqli-result.field-seek",
"mysqli_free_result" => "mysqli-result.free", "mysqli_free_result" => "mysqli-result.free",
"mysqli_embedded_server_end" => "mysqli-driver.embedded-server-end", "mysqli_embedded_server_end" => "mysqli-driver.embedded-server-end",
"mysqli_embedded_server_start" => "mysqli-driver.embedded-server-start", "mysqli_embedded_server_start" => "mysqli-driver.embedded-server-start",
]; ];
// Merge this temporary hack with $uri_aliases so it'll be treated as such // Merge this temporary hack with $uri_aliases so it'll be treated as such
@@ -647,7 +647,7 @@ if (isset($external_redirects[$URI])) {
// Temporary hack for mirror-info, until all the pages // Temporary hack for mirror-info, until all the pages
// will be capable of being included from anywhere // will be capable of being included from anywhere
if ($URI=='mirror-info') { if ($URI == 'mirror-info') {
status_header(200); status_header(200);
include_once __DIR__ . "/$URI.php"; include_once __DIR__ . "/$URI.php";
exit; exit;

View File

@@ -66,7 +66,7 @@ site_header("Get Involved", ["current" => "community"]);
<?php <?php
$SIDEBAR_DATA =' $SIDEBAR_DATA = '
<div class="panel"> <div class="panel">
<div class="headline">Table of Contents</div> <div class="headline">Table of Contents</div>
<div class="body"> <div class="body">
@@ -80,6 +80,6 @@ $SIDEBAR_DATA ='
</div> </div>
'; ';
site_footer(['sidebar'=>$SIDEBAR_DATA]); site_footer(['sidebar' => $SIDEBAR_DATA]);
/* vim: set et ts=4 sw=4 ft=php: : */ /* vim: set et ts=4 sw=4 ft=php: : */

View File

@@ -28,10 +28,10 @@ site_header("Using Git for PHP Development", ["current" => "community"]);
$groups = [ $groups = [
"none" => "Choose One", "none" => "Choose One",
"php" => "PHP Group", "php" => "PHP Group",
"pear" => "PEAR Group", "pear" => "PEAR Group",
"pecl" => "PECL Group", "pecl" => "PECL Group",
"doc" => "Doc Group", "doc" => "Doc Group",
]; ];
?> ?>
@@ -80,12 +80,12 @@ if (count($_POST) && (!isset($_POST['purpose']) || !is_array($_POST['purpose'])
"https://main.php.net/entry/svn-account.php", "https://main.php.net/entry/svn-account.php",
[ [
"username" => $_POST['id'], "username" => $_POST['id'],
"name" => $_POST['fullname'], "name" => $_POST['fullname'],
"email" => $_POST['email'], "email" => $_POST['email'],
"passwd" => $_POST['password'], "passwd" => $_POST['password'],
"note" => $_POST['realpurpose'], "note" => $_POST['realpurpose'],
"yesno" => $_POST['yesno'], "yesno" => $_POST['yesno'],
"group" => $_POST['group'], "group" => $_POST['group'],
] ]
); );
// Error while posting // Error while posting
@@ -102,7 +102,7 @@ if (count($_POST) && (!isset($_POST['purpose']) || !is_array($_POST['purpose'])
?> ?>
<p> <p>
Thank you. Your request has been sent. You should hear something within the Thank you. Your request has been sent. You should hear something within the
next week or so. If you haven't heard anything by around <?php echo date('l, F jS', time()+604800); ?> next week or so. If you haven't heard anything by around <?php echo date('l, F jS', time() + 604800); ?>
then please send an email to the appropriate <a href="/mailing-lists.php">mailing list</a>: then please send an email to the appropriate <a href="/mailing-lists.php">mailing list</a>:
</p> </p>
<ul> <ul>

View File

@@ -45,8 +45,8 @@ if (isset($_REQUEST['count'])) {
} }
// read out photo metadata // read out photo metadata
$path = __DIR__ . '/elephpants'; $path = __DIR__ . '/elephpants';
$json = @file_get_contents($path . '/flickr.json'); $json = @file_get_contents($path . '/flickr.json');
$photos = json_decode($json, true); $photos = json_decode($json, true);
// if no photo data, respond with an error. // if no photo data, respond with an error.
@@ -78,8 +78,8 @@ foreach ($photos as $photo) {
// add photo to response array. // add photo to response array.
$elephpants[] = [ $elephpants[] = [
'title' => $photo['title'], 'title' => $photo['title'],
'url' => "http://flickr.com/photos/" . $photo['owner'] . "/" . $photo['id'], 'url' => "http://flickr.com/photos/" . $photo['owner'] . "/" . $photo['id'],
'data' => base64_encode(file_get_contents($path . '/' . $photo['filename'])) 'data' => base64_encode(file_get_contents($path . '/' . $photo['filename']))
]; ];
} }

View File

@@ -17,23 +17,23 @@ $BRANCHES = [
'security' => '2000-10-20', 'security' => '2000-10-20',
], ],
'5.3' => [ '5.3' => [
'stable' => '2013-07-11', 'stable' => '2013-07-11',
'security' => '2014-08-14', 'security' => '2014-08-14',
], ],
'5.4' => [ '5.4' => [
'stable' => '2014-09-14', 'stable' => '2014-09-14',
'security' => '2015-09-03', 'security' => '2015-09-03',
], ],
'5.5' => [ '5.5' => [
'stable' => '2015-07-10', 'stable' => '2015-07-10',
'security' => '2016-07-21', 'security' => '2016-07-21',
], ],
'5.6' => [ '5.6' => [
'stable' => '2017-01-19', 'stable' => '2017-01-19',
'security' => '2018-12-31', 'security' => '2018-12-31',
], ],
'7.0' => [ '7.0' => [
'stable' => '2018-01-04', 'stable' => '2018-01-04',
'security' => '2019-01-10', 'security' => '2019-01-10',
], ],
]; ];

View File

@@ -125,227 +125,227 @@ TODO: Determine if we want to continue 301 -OR- make these official URLs.
function is_known_ini (string $ini): ?string { function is_known_ini (string $ini): ?string {
$inis = [ $inis = [
'engine' => 'apache.configuration.php#ini.engine', 'engine' => 'apache.configuration.php#ini.engine',
'short-open-tag' => 'ini.core.php#ini.short-open-tag', 'short-open-tag' => 'ini.core.php#ini.short-open-tag',
'asp-tags' => 'ini.core.php#ini.asp-tags', 'asp-tags' => 'ini.core.php#ini.asp-tags',
'precision' => 'ini.core.php#ini.precision', 'precision' => 'ini.core.php#ini.precision',
'y2k-compliance' => 'ini.core.php#ini.y2k-compliance', 'y2k-compliance' => 'ini.core.php#ini.y2k-compliance',
'output-buffering' => 'outcontrol.configuration.php#ini.output-buffering', 'output-buffering' => 'outcontrol.configuration.php#ini.output-buffering',
'output-handler' => 'outcontrol.configuration.php#ini.output-handler', 'output-handler' => 'outcontrol.configuration.php#ini.output-handler',
'zlib.output-compression' => 'zlib.configuration.php#ini.zlib.output-compression', 'zlib.output-compression' => 'zlib.configuration.php#ini.zlib.output-compression',
'zlib.output-compression-level' => 'zlib.configuration.php#ini.zlib.output-compression-level', 'zlib.output-compression-level' => 'zlib.configuration.php#ini.zlib.output-compression-level',
'zlib.output-handler' => 'zlib.configuration.php#ini.zlib.output-handler', 'zlib.output-handler' => 'zlib.configuration.php#ini.zlib.output-handler',
'implicit-flush' => 'outcontrol.configuration.php#ini.implicit-flush', 'implicit-flush' => 'outcontrol.configuration.php#ini.implicit-flush',
'allow-call-time-pass-reference'=> 'ini.core.php#ini.allow-call-time-pass-reference', 'allow-call-time-pass-reference' => 'ini.core.php#ini.allow-call-time-pass-reference',
'safe-mode' => 'ini.sect.safe-mode.php#ini.safe-mode', 'safe-mode' => 'ini.sect.safe-mode.php#ini.safe-mode',
'safe-mode-gid' => 'ini.sect.safe-mode.php#ini.safe-mode-gid', 'safe-mode-gid' => 'ini.sect.safe-mode.php#ini.safe-mode-gid',
'safe-mode-include-dir' => 'ini.sect.safe-mode.php#ini.safe-mode-include-dir', 'safe-mode-include-dir' => 'ini.sect.safe-mode.php#ini.safe-mode-include-dir',
'safe-mode-exec-dir' => 'ini.sect.safe-mode.php#ini.safe-mode-exec-dir', 'safe-mode-exec-dir' => 'ini.sect.safe-mode.php#ini.safe-mode-exec-dir',
'safe-mode-allowed-env-vars' => 'ini.sect.safe-mode.php#ini.safe-mode-allowed-env-vars', 'safe-mode-allowed-env-vars' => 'ini.sect.safe-mode.php#ini.safe-mode-allowed-env-vars',
'safe-mode-protected-env-vars' => 'ini.sect.safe-mode.php#ini.safe-mode-protected-env-vars', 'safe-mode-protected-env-vars' => 'ini.sect.safe-mode.php#ini.safe-mode-protected-env-vars',
'open-basedir' => 'ini.core.php#ini.open-basedir', 'open-basedir' => 'ini.core.php#ini.open-basedir',
'disable-functions' => 'ini.core.php#ini.disable-functions', 'disable-functions' => 'ini.core.php#ini.disable-functions',
'disable-classes' => 'ini.core.php#ini.disable-classes', 'disable-classes' => 'ini.core.php#ini.disable-classes',
'zend.assertions' => 'ini.core.php#ini.zend.assertions', 'zend.assertions' => 'ini.core.php#ini.zend.assertions',
'syntax-highlighting' => 'misc.configuration.php#ini.syntax-highlighting', 'syntax-highlighting' => 'misc.configuration.php#ini.syntax-highlighting',
'ignore-user-abort' => 'misc.configuration.php#ini.ignore-user-abort', 'ignore-user-abort' => 'misc.configuration.php#ini.ignore-user-abort',
'realpath-cache-size' => 'ini.core.php#ini.realpath-cache-size', 'realpath-cache-size' => 'ini.core.php#ini.realpath-cache-size',
'realpath-cache-ttl' => 'ini.core.php#ini.realpath-cache-ttl', 'realpath-cache-ttl' => 'ini.core.php#ini.realpath-cache-ttl',
'expose-php' => 'ini.core.php#ini.expose-php', 'expose-php' => 'ini.core.php#ini.expose-php',
'max-execution-time' => 'info.configuration.php#ini.max-execution-time', 'max-execution-time' => 'info.configuration.php#ini.max-execution-time',
'max-input-time' => 'info.configuration.php#ini.max-input-time', 'max-input-time' => 'info.configuration.php#ini.max-input-time',
'max-input-nesting-level' => 'info.configuration.php#ini.max-input-nesting-level', 'max-input-nesting-level' => 'info.configuration.php#ini.max-input-nesting-level',
'memory-limit' => 'ini.core.php#ini.memory-limit', 'memory-limit' => 'ini.core.php#ini.memory-limit',
'error-reporting' => 'errorfunc.configuration.php#ini.error-reporting', 'error-reporting' => 'errorfunc.configuration.php#ini.error-reporting',
'display-errors' => 'errorfunc.configuration.php#ini.display-errors', 'display-errors' => 'errorfunc.configuration.php#ini.display-errors',
'display-startup-errors' => 'errorfunc.configuration.php#ini.display-startup-errors', 'display-startup-errors' => 'errorfunc.configuration.php#ini.display-startup-errors',
'log-errors' => 'errorfunc.configuration.php#ini.log-errors', 'log-errors' => 'errorfunc.configuration.php#ini.log-errors',
'log-errors-max-len' => 'errorfunc.configuration.php#ini.log-errors-max-len', 'log-errors-max-len' => 'errorfunc.configuration.php#ini.log-errors-max-len',
'ignore-repeated-errors' => 'errorfunc.configuration.php#ini.ignore-repeated-errors', 'ignore-repeated-errors' => 'errorfunc.configuration.php#ini.ignore-repeated-errors',
'ignore-repeated-source' => 'errorfunc.configuration.php#ini.ignore-repeated-source', 'ignore-repeated-source' => 'errorfunc.configuration.php#ini.ignore-repeated-source',
'report-memleaks' => 'errorfunc.configuration.php#ini.report-memleaks', 'report-memleaks' => 'errorfunc.configuration.php#ini.report-memleaks',
'track-errors' => 'errorfunc.configuration.php#ini.track-errors', 'track-errors' => 'errorfunc.configuration.php#ini.track-errors',
'xmlrpc-errors' => 'errorfunc.configuration.php#ini.xmlrpc-errors', 'xmlrpc-errors' => 'errorfunc.configuration.php#ini.xmlrpc-errors',
'html-errors' => 'errorfunc.configuration.php#ini.html-errors', 'html-errors' => 'errorfunc.configuration.php#ini.html-errors',
'docref-root' => 'errorfunc.configuration.php#ini.docref-root', 'docref-root' => 'errorfunc.configuration.php#ini.docref-root',
'docref-ext' => 'errorfunc.configuration.php#ini.docref-ext', 'docref-ext' => 'errorfunc.configuration.php#ini.docref-ext',
'error-prepend-string' => 'errorfunc.configuration.php#ini.error-prepend-string', 'error-prepend-string' => 'errorfunc.configuration.php#ini.error-prepend-string',
'error-append-string' => 'errorfunc.configuration.php#ini.error-append-string', 'error-append-string' => 'errorfunc.configuration.php#ini.error-append-string',
'error-log' => 'errorfunc.configuration.php#ini.error-log', 'error-log' => 'errorfunc.configuration.php#ini.error-log',
'syslog.facility' => 'errorfunc.configuration.php#ini.syslog.facility', 'syslog.facility' => 'errorfunc.configuration.php#ini.syslog.facility',
'syslog.filter' => 'errorfunc.configuration.php#ini.syslog.filter', 'syslog.filter' => 'errorfunc.configuration.php#ini.syslog.filter',
'syslog.ident' => 'errorfunc.configuration.php#ini.syslog.ident', 'syslog.ident' => 'errorfunc.configuration.php#ini.syslog.ident',
'arg-separator.output' => 'ini.core.php#ini.arg-separator.output', 'arg-separator.output' => 'ini.core.php#ini.arg-separator.output',
'arg-separator.input' => 'ini.core.php#ini.arg-separator.input', 'arg-separator.input' => 'ini.core.php#ini.arg-separator.input',
'variables-order' => 'ini.core.php#ini.variables-order', 'variables-order' => 'ini.core.php#ini.variables-order',
'request-order' => 'ini.core.php#ini.request-order', 'request-order' => 'ini.core.php#ini.request-order',
'register-globals' => 'ini.core.php#ini.register-globals', 'register-globals' => 'ini.core.php#ini.register-globals',
'register-long-arrays' => 'ini.core.php#ini.register-long-arrays', 'register-long-arrays' => 'ini.core.php#ini.register-long-arrays',
'register-argc-argv' => 'ini.core.php#ini.register-argc-argv', 'register-argc-argv' => 'ini.core.php#ini.register-argc-argv',
'auto-globals-jit' => 'ini.core.php#ini.auto-globals-jit', 'auto-globals-jit' => 'ini.core.php#ini.auto-globals-jit',
'post-max-size' => 'ini.core.php#ini.post-max-size', 'post-max-size' => 'ini.core.php#ini.post-max-size',
'magic-quotes-gpc' => 'info.configuration.php#ini.magic-quotes-gpc', 'magic-quotes-gpc' => 'info.configuration.php#ini.magic-quotes-gpc',
'magic-quotes-runtime' => 'info.configuration.php#ini.magic-quotes-runtime', 'magic-quotes-runtime' => 'info.configuration.php#ini.magic-quotes-runtime',
'magic-quotes-sybase' => 'sybase.configuration.php#ini.magic-quotes-sybase', 'magic-quotes-sybase' => 'sybase.configuration.php#ini.magic-quotes-sybase',
'auto-prepend-file' => 'ini.core.php#ini.auto-prepend-file', 'auto-prepend-file' => 'ini.core.php#ini.auto-prepend-file',
'auto-append-file' => 'ini.core.php#ini.auto-append-file', 'auto-append-file' => 'ini.core.php#ini.auto-append-file',
'default-mimetype' => 'ini.core.php#ini.default-mimetype', 'default-mimetype' => 'ini.core.php#ini.default-mimetype',
'default-charset' => 'ini.core.php#ini.default-charset', 'default-charset' => 'ini.core.php#ini.default-charset',
'always-populate-raw-post-data' => 'ini.core.php#ini.always-populate-raw-post-data', 'always-populate-raw-post-data' => 'ini.core.php#ini.always-populate-raw-post-data',
'include-path' => 'ini.core.php#ini.include-path', 'include-path' => 'ini.core.php#ini.include-path',
'doc-root' => 'ini.core.php#ini.doc-root', 'doc-root' => 'ini.core.php#ini.doc-root',
'user-dir' => 'ini.core.php#ini.user-dir', 'user-dir' => 'ini.core.php#ini.user-dir',
'extension-dir' => 'ini.core.php#ini.extension-dir', 'extension-dir' => 'ini.core.php#ini.extension-dir',
'enable-dl' => 'info.configuration.php#ini.enable-dl', 'enable-dl' => 'info.configuration.php#ini.enable-dl',
'cgi.force-redirect' => 'ini.core.php#ini.cgi.force-redirect', 'cgi.force-redirect' => 'ini.core.php#ini.cgi.force-redirect',
'cgi.redirect-status-env' => 'ini.core.php#ini.cgi.redirect-status-env', 'cgi.redirect-status-env' => 'ini.core.php#ini.cgi.redirect-status-env',
'cgi.fix-pathinfo' => 'ini.core.php#ini.cgi.fix-pathinfo', 'cgi.fix-pathinfo' => 'ini.core.php#ini.cgi.fix-pathinfo',
'fastcgi.impersonate' => 'ini.core.php#ini.fastcgi.impersonate', 'fastcgi.impersonate' => 'ini.core.php#ini.fastcgi.impersonate',
'cgi.rfc2616-headers' => 'ini.core.php#ini.cgi.rfc2616-headers', 'cgi.rfc2616-headers' => 'ini.core.php#ini.cgi.rfc2616-headers',
'file-uploads' => 'ini.core.php#ini.file-uploads', 'file-uploads' => 'ini.core.php#ini.file-uploads',
'upload-tmp-dir' => 'ini.core.php#ini.upload-tmp-dir', 'upload-tmp-dir' => 'ini.core.php#ini.upload-tmp-dir',
'upload-max-filesize' => 'ini.core.php#ini.upload-max-filesize', 'upload-max-filesize' => 'ini.core.php#ini.upload-max-filesize',
'allow-url-fopen' => 'filesystem.configuration.php#ini.allow-url-fopen', 'allow-url-fopen' => 'filesystem.configuration.php#ini.allow-url-fopen',
'allow-url-include' => 'filesystem.configuration.php#ini.allow-url-include', 'allow-url-include' => 'filesystem.configuration.php#ini.allow-url-include',
'from' => 'filesystem.configuration.php#ini.from', 'from' => 'filesystem.configuration.php#ini.from',
'user-agent' => 'filesystem.configuration.php#ini.user-agent', 'user-agent' => 'filesystem.configuration.php#ini.user-agent',
'default-socket-timeout' => 'filesystem.configuration.php#ini.default-socket-timeout', 'default-socket-timeout' => 'filesystem.configuration.php#ini.default-socket-timeout',
'auto-detect-line-endings' => 'filesystem.configuration.php#ini.auto-detect-line-endings', 'auto-detect-line-endings' => 'filesystem.configuration.php#ini.auto-detect-line-endings',
'date.timezone' => 'datetime.configuration.php#ini.date.timezone', 'date.timezone' => 'datetime.configuration.php#ini.date.timezone',
'date.default-latitude' => 'datetime.configuration.php#ini.date.default-latitude', 'date.default-latitude' => 'datetime.configuration.php#ini.date.default-latitude',
'date.default-longitude' => 'datetime.configuration.php#ini.date.default-longitude', 'date.default-longitude' => 'datetime.configuration.php#ini.date.default-longitude',
'date.sunrise-zenith' => 'datetime.configuration.php#ini.date.sunrise-zenith', 'date.sunrise-zenith' => 'datetime.configuration.php#ini.date.sunrise-zenith',
'date.sunset-zenith' => 'datetime.configuration.php#ini.date.sunset-zenith', 'date.sunset-zenith' => 'datetime.configuration.php#ini.date.sunset-zenith',
'filter.default' => 'filter.configuration.php#ini.filter.default', 'filter.default' => 'filter.configuration.php#ini.filter.default',
'filter.default-flags' => 'filter.configuration.php#ini.filter.default-flags', 'filter.default-flags' => 'filter.configuration.php#ini.filter.default-flags',
'sqlite.assoc-case' => 'sqlite.configuration.php#ini.sqlite.assoc-case', 'sqlite.assoc-case' => 'sqlite.configuration.php#ini.sqlite.assoc-case',
'pcre.backtrack-limit' => 'pcre.configuration.php#ini.pcre.backtrack-limit', 'pcre.backtrack-limit' => 'pcre.configuration.php#ini.pcre.backtrack-limit',
'pcre.recursion-limit' => 'pcre.configuration.php#ini.pcre.recursion-limit', 'pcre.recursion-limit' => 'pcre.configuration.php#ini.pcre.recursion-limit',
'pdo-odbc.connection-pooling' => 'ref.pdo-odbc.php#ini.pdo-odbc.connection-pooling', 'pdo-odbc.connection-pooling' => 'ref.pdo-odbc.php#ini.pdo-odbc.connection-pooling',
'phar.readonly' => 'phar.configuration.php#ini.phar.readonly', 'phar.readonly' => 'phar.configuration.php#ini.phar.readonly',
'phar.require-hash' => 'phar.configuration.php#ini.phar.require-hash', 'phar.require-hash' => 'phar.configuration.php#ini.phar.require-hash',
'define-syslog-variables' => 'network.configuration.php#ini.define-syslog-variables', 'define-syslog-variables' => 'network.configuration.php#ini.define-syslog-variables',
'smtp' => 'mail.configuration.php#ini.smtp', 'smtp' => 'mail.configuration.php#ini.smtp',
'smtp-port' => 'mail.configuration.php#ini.smtp-port', 'smtp-port' => 'mail.configuration.php#ini.smtp-port',
'sendmail-from' => 'mail.configuration.php#ini.sendmail-from', 'sendmail-from' => 'mail.configuration.php#ini.sendmail-from',
'sendmail-path' => 'mail.configuration.php#ini.sendmail-path', 'sendmail-path' => 'mail.configuration.php#ini.sendmail-path',
'sql.safe-mode' => 'ini.core.php#ini.sql.safe-mode', 'sql.safe-mode' => 'ini.core.php#ini.sql.safe-mode',
'odbc.default-db' => 'odbc.configuration.php#ini.uodbc.default-db', 'odbc.default-db' => 'odbc.configuration.php#ini.uodbc.default-db',
'odbc.default-user' => 'odbc.configuration.php#ini.uodbc.default-user', 'odbc.default-user' => 'odbc.configuration.php#ini.uodbc.default-user',
'odbc.default-pw' => 'odbc.configuration.php#ini.uodbc.default-pw', 'odbc.default-pw' => 'odbc.configuration.php#ini.uodbc.default-pw',
'odbc.allow-persistent' => 'odbc.configuration.php#ini.uodbc.allow-persistent', 'odbc.allow-persistent' => 'odbc.configuration.php#ini.uodbc.allow-persistent',
'odbc.check-persistent' => 'odbc.configuration.php#ini.uodbc.check-persistent', 'odbc.check-persistent' => 'odbc.configuration.php#ini.uodbc.check-persistent',
'odbc.max-persistent' => 'odbc.configuration.php#ini.uodbc.max-persistent', 'odbc.max-persistent' => 'odbc.configuration.php#ini.uodbc.max-persistent',
'odbc.max-links' => 'odbc.configuration.php#ini.uodbc.max-links', 'odbc.max-links' => 'odbc.configuration.php#ini.uodbc.max-links',
'odbc.defaultlrl' => 'odbc.configuration.php#ini.uodbc.defaultlrl', 'odbc.defaultlrl' => 'odbc.configuration.php#ini.uodbc.defaultlrl',
'odbc.defaultbinmode' => 'odbc.configuration.php#ini.uodbc.defaultbinmode', 'odbc.defaultbinmode' => 'odbc.configuration.php#ini.uodbc.defaultbinmode',
'mysql.allow-local-infile' => 'mysql.configuration.php#ini.mysql.allow-local-infile', 'mysql.allow-local-infile' => 'mysql.configuration.php#ini.mysql.allow-local-infile',
'mysql.allow-persistent' => 'mysql.configuration.php#ini.mysql.allow-persistent', 'mysql.allow-persistent' => 'mysql.configuration.php#ini.mysql.allow-persistent',
'mysql.max-persistent' => 'mysql.configuration.php#ini.mysql.max-persistent', 'mysql.max-persistent' => 'mysql.configuration.php#ini.mysql.max-persistent',
'mysql.max-links' => 'mysql.configuration.php#ini.mysql.max-links', 'mysql.max-links' => 'mysql.configuration.php#ini.mysql.max-links',
'mysql.default-port' => 'mysql.configuration.php#ini.mysql.default-port', 'mysql.default-port' => 'mysql.configuration.php#ini.mysql.default-port',
'mysql.default-socket' => 'mysql.configuration.php#ini.mysql.default-socket', 'mysql.default-socket' => 'mysql.configuration.php#ini.mysql.default-socket',
'mysql.default-host' => 'mysql.configuration.php#ini.mysql.default-host', 'mysql.default-host' => 'mysql.configuration.php#ini.mysql.default-host',
'mysql.default-user' => 'mysql.configuration.php#ini.mysql.default-user', 'mysql.default-user' => 'mysql.configuration.php#ini.mysql.default-user',
'mysql.default-password' => 'mysql.configuration.php#ini.mysql.default-password', 'mysql.default-password' => 'mysql.configuration.php#ini.mysql.default-password',
'mysql.connect-timeout' => 'mysql.configuration.php#ini.mysql.connect-timeout', 'mysql.connect-timeout' => 'mysql.configuration.php#ini.mysql.connect-timeout',
'mysql.trace-mode' => 'mysql.configuration.php#ini.mysql.trace-mode', 'mysql.trace-mode' => 'mysql.configuration.php#ini.mysql.trace-mode',
'mysqli.allow-local-infile' => 'mysqli.configuration.php#ini.mysqli.allow-local-infile', 'mysqli.allow-local-infile' => 'mysqli.configuration.php#ini.mysqli.allow-local-infile',
'mysqli.max-links' => 'mysqli.configuration.php#ini.mysqli.max-links', 'mysqli.max-links' => 'mysqli.configuration.php#ini.mysqli.max-links',
'mysqli.allow-persistent' => 'mysqli.configuration.php#ini.mysqli.allow-persistent', 'mysqli.allow-persistent' => 'mysqli.configuration.php#ini.mysqli.allow-persistent',
'mysqli.default-port' => 'mysqli.configuration.php#ini.mysqli.default-port', 'mysqli.default-port' => 'mysqli.configuration.php#ini.mysqli.default-port',
'mysqli.default-socket' => 'mysqli.configuration.php#ini.mysqli.default-socket', 'mysqli.default-socket' => 'mysqli.configuration.php#ini.mysqli.default-socket',
'mysqli.default-host' => 'mysqli.configuration.php#ini.mysqli.default-host', 'mysqli.default-host' => 'mysqli.configuration.php#ini.mysqli.default-host',
'mysqli.default-user' => 'mysqli.configuration.php#ini.mysqli.default-user', 'mysqli.default-user' => 'mysqli.configuration.php#ini.mysqli.default-user',
'mysqli.default-pw' => 'mysqli.configuration.php#ini.mysqli.default-pw', 'mysqli.default-pw' => 'mysqli.configuration.php#ini.mysqli.default-pw',
'oci8.privileged-connect' => 'oci8.configuration.php#ini.oci8.privileged-connect', 'oci8.privileged-connect' => 'oci8.configuration.php#ini.oci8.privileged-connect',
'oci8.max-persistent' => 'oci8.configuration.php#ini.oci8.max-persistent', 'oci8.max-persistent' => 'oci8.configuration.php#ini.oci8.max-persistent',
'oci8.persistent-timeout' => 'oci8.configuration.php#ini.oci8.persistent-timeout', 'oci8.persistent-timeout' => 'oci8.configuration.php#ini.oci8.persistent-timeout',
'oci8.ping-interval' => 'oci8.configuration.php#ini.oci8.ping-interval', 'oci8.ping-interval' => 'oci8.configuration.php#ini.oci8.ping-interval',
'oci8.statement-cache-size' => 'oci8.configuration.php#ini.oci8.statement-cache-size', 'oci8.statement-cache-size' => 'oci8.configuration.php#ini.oci8.statement-cache-size',
'oci8.default-prefetch' => 'oci8.configuration.php#ini.oci8.default-prefetch', 'oci8.default-prefetch' => 'oci8.configuration.php#ini.oci8.default-prefetch',
'oci8.old-oci-close-semantics' => 'oci8.configuration.php#ini.oci8.old-oci-close-semantics', 'oci8.old-oci-close-semantics' => 'oci8.configuration.php#ini.oci8.old-oci-close-semantics',
'opcache.preload' => 'opcache.configuration.php#ini.opcache.preload', 'opcache.preload' => 'opcache.configuration.php#ini.opcache.preload',
'pgsql.allow-persistent' => 'pgsql.configuration.php#ini.pgsql.allow-persistent', 'pgsql.allow-persistent' => 'pgsql.configuration.php#ini.pgsql.allow-persistent',
'pgsql.auto-reset-persistent' => 'pgsql.configuration.php#ini.pgsql.auto-reset-persistent', 'pgsql.auto-reset-persistent' => 'pgsql.configuration.php#ini.pgsql.auto-reset-persistent',
'pgsql.max-persistent' => 'pgsql.configuration.php#ini.pgsql.max-persistent', 'pgsql.max-persistent' => 'pgsql.configuration.php#ini.pgsql.max-persistent',
'pgsql.max-links' => 'pgsql.configuration.php#ini.pgsql.max-links', 'pgsql.max-links' => 'pgsql.configuration.php#ini.pgsql.max-links',
'pgsql.ignore-notice' => 'pgsql.configuration.php#ini.pgsql.ignore-notice', 'pgsql.ignore-notice' => 'pgsql.configuration.php#ini.pgsql.ignore-notice',
'pgsql.log-notice' => 'pgsql.configuration.php#ini.pgsql.log-notice', 'pgsql.log-notice' => 'pgsql.configuration.php#ini.pgsql.log-notice',
'sqlite3.extension-dir' => 'sqlite3.configuration.php#ini.sqlite3.extension-dir', 'sqlite3.extension-dir' => 'sqlite3.configuration.php#ini.sqlite3.extension-dir',
'sybct.allow-persistent' => 'sybase.configuration.php#ini.sybct.allow-persistent', 'sybct.allow-persistent' => 'sybase.configuration.php#ini.sybct.allow-persistent',
'sybct.max-persistent' => 'sybase.configuration.php#ini.sybct.max-persistent', 'sybct.max-persistent' => 'sybase.configuration.php#ini.sybct.max-persistent',
'sybct.max-links' => 'sybase.configuration.php#ini.sybct.max-links', 'sybct.max-links' => 'sybase.configuration.php#ini.sybct.max-links',
'sybct.min-server-severity' => 'sybase.configuration.php#ini.sybct.min-server-severity', 'sybct.min-server-severity' => 'sybase.configuration.php#ini.sybct.min-server-severity',
'sybct.min-client-severity' => 'sybase.configuration.php#ini.sybct.min-client-severity', 'sybct.min-client-severity' => 'sybase.configuration.php#ini.sybct.min-client-severity',
'sybct.timeout' => 'sybase.configuration.php#ini.sybct.timeout', 'sybct.timeout' => 'sybase.configuration.php#ini.sybct.timeout',
'bcmath.scale' => 'bc.configuration.php#ini.bcmath.scale', 'bcmath.scale' => 'bc.configuration.php#ini.bcmath.scale',
'browscap' => 'misc.configuration.php#ini.browscap', 'browscap' => 'misc.configuration.php#ini.browscap',
'session.save-handler' => 'session.configuration.php#ini.session.save-handler', 'session.save-handler' => 'session.configuration.php#ini.session.save-handler',
'session.save-path' => 'session.configuration.php#ini.session.save-path', 'session.save-path' => 'session.configuration.php#ini.session.save-path',
'session.use-cookies' => 'session.configuration.php#ini.session.use-cookies', 'session.use-cookies' => 'session.configuration.php#ini.session.use-cookies',
'session.cookie-secure' => 'session.configuration.php#ini.session.cookie-secure', 'session.cookie-secure' => 'session.configuration.php#ini.session.cookie-secure',
'session.use-only-cookies' => 'session.configuration.php#ini.session.use-only-cookies', 'session.use-only-cookies' => 'session.configuration.php#ini.session.use-only-cookies',
'session.name' => 'session.configuration.php#ini.session.name', 'session.name' => 'session.configuration.php#ini.session.name',
'session.auto-start' => 'session.configuration.php#ini.session.auto-start', 'session.auto-start' => 'session.configuration.php#ini.session.auto-start',
'session.cookie-lifetime' => 'session.configuration.php#ini.session.cookie-lifetime', 'session.cookie-lifetime' => 'session.configuration.php#ini.session.cookie-lifetime',
'session.cookie-path' => 'session.configuration.php#ini.session.cookie-path', 'session.cookie-path' => 'session.configuration.php#ini.session.cookie-path',
'session.cookie-domain' => 'session.configuration.php#ini.session.cookie-domain', 'session.cookie-domain' => 'session.configuration.php#ini.session.cookie-domain',
'session.cookie-httponly' => 'session.configuration.php#ini.session.cookie-httponly', 'session.cookie-httponly' => 'session.configuration.php#ini.session.cookie-httponly',
'session.serialize-handler' => 'session.configuration.php#ini.session.serialize-handler', 'session.serialize-handler' => 'session.configuration.php#ini.session.serialize-handler',
'session.gc-probability' => 'session.configuration.php#ini.session.gc-probability', 'session.gc-probability' => 'session.configuration.php#ini.session.gc-probability',
'session.gc-divisor' => 'session.configuration.php#ini.session.gc-divisor', 'session.gc-divisor' => 'session.configuration.php#ini.session.gc-divisor',
'session.gc-maxlifetime' => 'session.configuration.php#ini.session.gc-maxlifetime', 'session.gc-maxlifetime' => 'session.configuration.php#ini.session.gc-maxlifetime',
'session.bug-compat-42' => 'session.configuration.php#ini.session.bug-compat-42', 'session.bug-compat-42' => 'session.configuration.php#ini.session.bug-compat-42',
'session.bug-compat-warn' => 'session.configuration.php#ini.session.bug-compat-warn', 'session.bug-compat-warn' => 'session.configuration.php#ini.session.bug-compat-warn',
'session.referer-check' => 'session.configuration.php#ini.session.referer-check', 'session.referer-check' => 'session.configuration.php#ini.session.referer-check',
'session.entropy-length' => 'session.configuration.php#ini.session.entropy-length', 'session.entropy-length' => 'session.configuration.php#ini.session.entropy-length',
'session.entropy-file' => 'session.configuration.php#ini.session.entropy-file', 'session.entropy-file' => 'session.configuration.php#ini.session.entropy-file',
'session.cache-limiter' => 'session.configuration.php#ini.session.cache-limiter', 'session.cache-limiter' => 'session.configuration.php#ini.session.cache-limiter',
'session.cache-expire' => 'session.configuration.php#ini.session.cache-expire', 'session.cache-expire' => 'session.configuration.php#ini.session.cache-expire',
'session.sid-length' => 'session.configuration.php#ini.session.sid-length', 'session.sid-length' => 'session.configuration.php#ini.session.sid-length',
'session.use-trans-sid' => 'session.configuration.php#ini.session.use-trans-sid', 'session.use-trans-sid' => 'session.configuration.php#ini.session.use-trans-sid',
'session.hash-function' => 'session.configuration.php#ini.session.hash-function', 'session.hash-function' => 'session.configuration.php#ini.session.hash-function',
'session.hash-bits-per-character' => 'session.configuration.php#ini.session.hash-bits-per-character', 'session.hash-bits-per-character' => 'session.configuration.php#ini.session.hash-bits-per-character',
'session.upload-progress.enabled' => 'session.configuration.php#ini.session.upload-progress.enabled', 'session.upload-progress.enabled' => 'session.configuration.php#ini.session.upload-progress.enabled',
'session.upload-progress.cleanup' => 'session.configuration.php#ini.session.upload-progress.cleanup', 'session.upload-progress.cleanup' => 'session.configuration.php#ini.session.upload-progress.cleanup',
'session.upload-progress.prefix' => 'session.configuration.php#ini.session.upload-progress.prefix', 'session.upload-progress.prefix' => 'session.configuration.php#ini.session.upload-progress.prefix',
'session.upload-progress.name' => 'session.configuration.php#ini.session.upload-progress.name', 'session.upload-progress.name' => 'session.configuration.php#ini.session.upload-progress.name',
'session.upload-progress.freq' => 'session.configuration.php#ini.session.upload-progress.freq', 'session.upload-progress.freq' => 'session.configuration.php#ini.session.upload-progress.freq',
'session.upload-progress.min-freq' => 'session.configuration.php#ini.session.upload-progress.min-freq', 'session.upload-progress.min-freq' => 'session.configuration.php#ini.session.upload-progress.min-freq',
'url-rewriter.tags' => 'session.configuration.php#ini.url-rewriter.tags', 'url-rewriter.tags' => 'session.configuration.php#ini.url-rewriter.tags',
'assert.active' => 'info.configuration.php#ini.assert.active', 'assert.active' => 'info.configuration.php#ini.assert.active',
'assert.exception' => 'info.configuration.php#ini.assert.exception', 'assert.exception' => 'info.configuration.php#ini.assert.exception',
'assert.warning' => 'info.configuration.php#ini.assert.warning', 'assert.warning' => 'info.configuration.php#ini.assert.warning',
'assert.bail' => 'info.configuration.php#ini.assert.bail', 'assert.bail' => 'info.configuration.php#ini.assert.bail',
'assert.callback' => 'info.configuration.php#ini.assert.callback', 'assert.callback' => 'info.configuration.php#ini.assert.callback',
'assert.quiet-eval' => 'info.configuration.php#ini.assert.quiet-eval', 'assert.quiet-eval' => 'info.configuration.php#ini.assert.quiet-eval',
'zend.enable-gc' => 'info.configuration.php#ini.zend.enable-gc', 'zend.enable-gc' => 'info.configuration.php#ini.zend.enable-gc',
'com.typelib-file' => 'com.configuration.php#ini.com.typelib-file', 'com.typelib-file' => 'com.configuration.php#ini.com.typelib-file',
'com.allow-dcom' => 'com.configuration.php#ini.com.allow-dcom', 'com.allow-dcom' => 'com.configuration.php#ini.com.allow-dcom',
'com.autoregister-typelib' => 'com.configuration.php#ini.com.autoregister-typelib', 'com.autoregister-typelib' => 'com.configuration.php#ini.com.autoregister-typelib',
'com.autoregister-casesensitive'=> 'com.configuration.php#ini.com.autoregister-casesensitive', 'com.autoregister-casesensitive' => 'com.configuration.php#ini.com.autoregister-casesensitive',
'com.autoregister-verbose' => 'com.configuration.php#ini.com.autoregister-verbose', 'com.autoregister-verbose' => 'com.configuration.php#ini.com.autoregister-verbose',
'mbstring.language' => 'mbstring.configuration.php#ini.mbstring.language', 'mbstring.language' => 'mbstring.configuration.php#ini.mbstring.language',
'mbstring.internal-encoding' => 'mbstring.configuration.php#ini.mbstring.internal-encoding', 'mbstring.internal-encoding' => 'mbstring.configuration.php#ini.mbstring.internal-encoding',
'mbstring.http-input' => 'mbstring.configuration.php#ini.mbstring.http-input', 'mbstring.http-input' => 'mbstring.configuration.php#ini.mbstring.http-input',
'mbstring.http-output' => 'mbstring.configuration.php#ini.mbstring.http-output', 'mbstring.http-output' => 'mbstring.configuration.php#ini.mbstring.http-output',
'mbstring.encoding-translation' => 'mbstring.configuration.php#ini.mbstring.encoding-translation', 'mbstring.encoding-translation' => 'mbstring.configuration.php#ini.mbstring.encoding-translation',
'mbstring.detect-order' => 'mbstring.configuration.php#ini.mbstring.detect-order', 'mbstring.detect-order' => 'mbstring.configuration.php#ini.mbstring.detect-order',
'mbstring.substitute-character' => 'mbstring.configuration.php#ini.mbstring.substitute-character', 'mbstring.substitute-character' => 'mbstring.configuration.php#ini.mbstring.substitute-character',
'mbstring.func-overload' => 'mbstring.configuration.php#ini.mbstring.func-overload', 'mbstring.func-overload' => 'mbstring.configuration.php#ini.mbstring.func-overload',
'gd.jpeg-ignore-warning' => 'image.configuration.php#ini.image.jpeg-ignore-warning', 'gd.jpeg-ignore-warning' => 'image.configuration.php#ini.image.jpeg-ignore-warning',
'exif.encode-unicode' => 'exif.configuration.php#ini.exif.encode-unicode', 'exif.encode-unicode' => 'exif.configuration.php#ini.exif.encode-unicode',
'exif.decode-unicode-motorola' => 'exif.configuration.php#ini.exif.decode-unicode-motorola', 'exif.decode-unicode-motorola' => 'exif.configuration.php#ini.exif.decode-unicode-motorola',
'exif.decode-unicode-intel' => 'exif.configuration.php#ini.exif.decode-unicode-intel', 'exif.decode-unicode-intel' => 'exif.configuration.php#ini.exif.decode-unicode-intel',
'exif.encode-jis' => 'exif.configuration.php#ini.exif.encode-jis', 'exif.encode-jis' => 'exif.configuration.php#ini.exif.encode-jis',
'exif.decode-jis-motorola' => 'exif.configuration.php#ini.exif.decode-jis-motorola', 'exif.decode-jis-motorola' => 'exif.configuration.php#ini.exif.decode-jis-motorola',
'exif.decode-jis-intel' => 'exif.configuration.php#ini.exif.decode-jis-intel', 'exif.decode-jis-intel' => 'exif.configuration.php#ini.exif.decode-jis-intel',
'tidy.default-config' => 'tidy.configuration.php#ini.tidy.default-config', 'tidy.default-config' => 'tidy.configuration.php#ini.tidy.default-config',
'tidy.clean-output' => 'tidy.configuration.php#ini.tidy.clean-output', 'tidy.clean-output' => 'tidy.configuration.php#ini.tidy.clean-output',
'soap.wsdl-cache-enabled' => 'soap.configuration.php#ini.soap.wsdl-cache-enabled', 'soap.wsdl-cache-enabled' => 'soap.configuration.php#ini.soap.wsdl-cache-enabled',
'soap.wsdl-cache-dir' => 'soap.configuration.php#ini.soap.wsdl-cache-dir', 'soap.wsdl-cache-dir' => 'soap.configuration.php#ini.soap.wsdl-cache-dir',
'soap.wsdl-cache-ttl' => 'soap.configuration.php#ini.soap.wsdl-cache-ttl', 'soap.wsdl-cache-ttl' => 'soap.configuration.php#ini.soap.wsdl-cache-ttl',
]; ];
return $inis[$ini] ?? null; return $inis[$ini] ?? null;
@@ -354,28 +354,28 @@ function is_known_ini (string $ini): ?string {
function is_known_variable(string $variable): ?string { function is_known_variable(string $variable): ?string {
$variables = [ $variables = [
// Variables // Variables
'globals' => 'reserved.variables.globals.php', 'globals' => 'reserved.variables.globals.php',
'-server' => 'reserved.variables.server.php', '-server' => 'reserved.variables.server.php',
'-get' => 'reserved.variables.get.php', '-get' => 'reserved.variables.get.php',
'-post' => 'reserved.variables.post.php', '-post' => 'reserved.variables.post.php',
'-files' => 'reserved.variables.files.php', '-files' => 'reserved.variables.files.php',
'-request' => 'reserved.variables.request.php', '-request' => 'reserved.variables.request.php',
'-session' => 'reserved.variables.session.php', '-session' => 'reserved.variables.session.php',
'-cookie' => 'reserved.variables.cookies.php', '-cookie' => 'reserved.variables.cookies.php',
'-env' => 'reserved.variables.environment.php', '-env' => 'reserved.variables.environment.php',
'this' => 'language.oop5.basic.php', 'this' => 'language.oop5.basic.php',
'php-errormsg' => 'reserved.variables.phperrormsg.php', 'php-errormsg' => 'reserved.variables.phperrormsg.php',
'argv' => 'reserved.variables.argv.php', 'argv' => 'reserved.variables.argv.php',
'argc' => 'reserved.variables.argc.php', 'argc' => 'reserved.variables.argc.php',
'http-raw-post-data' => 'reserved.variables.httprawpostdata.php', 'http-raw-post-data' => 'reserved.variables.httprawpostdata.php',
'http-response-header' => 'reserved.variables.httpresponseheader.php', 'http-response-header' => 'reserved.variables.httpresponseheader.php',
'http-server-vars' => 'reserved.variables.server.php', 'http-server-vars' => 'reserved.variables.server.php',
'http-get-vars' => 'reserved.variables.get.php', 'http-get-vars' => 'reserved.variables.get.php',
'http-post-vars' => 'reserved.variables.post.php', 'http-post-vars' => 'reserved.variables.post.php',
'http-session-vars' => 'reserved.variables.session.php', 'http-session-vars' => 'reserved.variables.session.php',
'http-post-files' => 'reserved.variables.files.php', 'http-post-files' => 'reserved.variables.files.php',
'http-cookie-vars' => 'reserved.variables.cookies.php', 'http-cookie-vars' => 'reserved.variables.cookies.php',
'http-env-vars' => 'reserved.variables.env.php', 'http-env-vars' => 'reserved.variables.env.php',
]; ];
return $variables[ltrim($variable, '$')] ?? null; return $variables[ltrim($variable, '$')] ?? null;
@@ -383,79 +383,79 @@ function is_known_variable(string $variable): ?string {
function is_known_term (string $term): ?string { function is_known_term (string $term): ?string {
$terms = [ $terms = [
'<>' => 'language.operators.comparison.php', '<>' => 'language.operators.comparison.php',
'<=>' => 'language.operators.comparison.php', '<=>' => 'language.operators.comparison.php',
'spaceship' => 'language.operators.comparison.php', 'spaceship' => 'language.operators.comparison.php',
'==' => 'language.operators.comparison.php', '==' => 'language.operators.comparison.php',
'===' => 'language.operators.comparison.php', '===' => 'language.operators.comparison.php',
'@' => 'language.operators.errorcontrol.php', '@' => 'language.operators.errorcontrol.php',
'apache' => 'install.php', 'apache' => 'install.php',
'array' => 'language.types.array.php', 'array' => 'language.types.array.php',
'arrays' => 'language.types.array.php', 'arrays' => 'language.types.array.php',
'case' => 'control-structures.switch.php', 'case' => 'control-structures.switch.php',
'catch' => 'language.exceptions.php', 'catch' => 'language.exceptions.php',
'checkbox' => 'faq.html.php', 'checkbox' => 'faq.html.php',
'class' => 'language.oop5.basic.php', 'class' => 'language.oop5.basic.php',
'classes' => 'language.oop5.basic.php', 'classes' => 'language.oop5.basic.php',
'closures' => 'functions.anonymous.php', 'closures' => 'functions.anonymous.php',
'cookie' => 'features.cookies.php', 'cookie' => 'features.cookies.php',
'date' => 'function.date.php', 'date' => 'function.date.php',
'exception' => 'language.exceptions.php', 'exception' => 'language.exceptions.php',
'extends' => 'language.oop5.basic.php#language.oop5.basic.extends', 'extends' => 'language.oop5.basic.php#language.oop5.basic.extends',
'file' => 'function.file.php', 'file' => 'function.file.php',
'finally' => 'language.exceptions.php', 'finally' => 'language.exceptions.php',
'fopen' => 'function.fopen.php', 'fopen' => 'function.fopen.php',
'for' => 'control-structures.for.php', 'for' => 'control-structures.for.php',
'foreach' => 'control-structures.foreach.php', 'foreach' => 'control-structures.foreach.php',
'form' => 'language.variables.external.php', 'form' => 'language.variables.external.php',
'forms' => 'language.variables.external.php', 'forms' => 'language.variables.external.php',
'function' => 'language.functions.php', 'function' => 'language.functions.php',
'gd' => 'book.image.php', 'gd' => 'book.image.php',
'get' => 'reserved.variables.get.php', 'get' => 'reserved.variables.get.php',
'global' => 'language.variables.scope.php', 'global' => 'language.variables.scope.php',
'globals' => 'language.variables.scope.php', 'globals' => 'language.variables.scope.php',
'header' => 'function.header.php', 'header' => 'function.header.php',
'heredoc' => 'language.types.string.php#language.types.string.syntax.heredoc', 'heredoc' => 'language.types.string.php#language.types.string.syntax.heredoc',
'nowdoc' => 'language.types.string.php#language.types.string.syntax.nowdoc', 'nowdoc' => 'language.types.string.php#language.types.string.syntax.nowdoc',
'htaccess' => 'configuration.file.php', 'htaccess' => 'configuration.file.php',
'if' => 'control-structures.if.php', 'if' => 'control-structures.if.php',
'include' => 'function.include.php', 'include' => 'function.include.php',
'int' => 'language.types.integer.php', 'int' => 'language.types.integer.php',
'ip' => 'reserved.variables.server.php', 'ip' => 'reserved.variables.server.php',
'iterable' => 'language.types.iterable.php', 'iterable' => 'language.types.iterable.php',
'juggling' => 'language.types.type-juggling.php', 'juggling' => 'language.types.type-juggling.php',
'location' => 'function.header.php', 'location' => 'function.header.php',
'mail' => 'function.mail.php', 'mail' => 'function.mail.php',
'modulo' => 'language.operators.arithmetic.php', 'modulo' => 'language.operators.arithmetic.php',
'mysql' => 'mysql.php', 'mysql' => 'mysql.php',
'new' => 'language.oop5.basic.php#language.oop5.basic.new', 'new' => 'language.oop5.basic.php#language.oop5.basic.new',
'null' => 'language.types.null.php', 'null' => 'language.types.null.php',
'object' => 'language.types.object.php', 'object' => 'language.types.object.php',
'operator' => 'language.operators.php', 'operator' => 'language.operators.php',
'operators' => 'language.operators.php', 'operators' => 'language.operators.php',
'or' => 'language.operators.logical.php', 'or' => 'language.operators.logical.php',
'php.ini' => 'configuration.file.php', 'php.ini' => 'configuration.file.php',
'php-mysql.dll' => 'book.mysql.php', 'php-mysql.dll' => 'book.mysql.php',
'php-self' => 'reserved.variables.server.php', 'php-self' => 'reserved.variables.server.php',
'query-string' => 'reserved.variables.server.php', 'query-string' => 'reserved.variables.server.php',
'redirect' => 'function.header.php', 'redirect' => 'function.header.php',
'reference' => 'index.php', 'reference' => 'index.php',
'referer' => 'reserved.variables.server.php', 'referer' => 'reserved.variables.server.php',
'referrer' => 'reserved.variables.server.php', 'referrer' => 'reserved.variables.server.php',
'remote-addr' => 'reserved.variables.server.php', 'remote-addr' => 'reserved.variables.server.php',
'request' => 'reserved.variables.request.php', 'request' => 'reserved.variables.request.php',
'session' => 'features.sessions.php', 'session' => 'features.sessions.php',
'smtp' => 'book.mail.php', 'smtp' => 'book.mail.php',
'ssl' => 'book.openssl.php', 'ssl' => 'book.openssl.php',
'static' => 'language.oop5.static.php', 'static' => 'language.oop5.static.php',
'stdin' => 'wrappers.php.php', 'stdin' => 'wrappers.php.php',
'string' => 'language.types.string.php', 'string' => 'language.types.string.php',
'superglobal' => 'language.variables.superglobals.php', 'superglobal' => 'language.variables.superglobals.php',
'superglobals' => 'language.variables.superglobals.php', 'superglobals' => 'language.variables.superglobals.php',
'switch' => 'control-structures.switch.php', 'switch' => 'control-structures.switch.php',
'timestamp' => 'function.time.php', 'timestamp' => 'function.time.php',
'try' => 'language.exceptions.php', 'try' => 'language.exceptions.php',
'upload' => 'features.file-upload.php', 'upload' => 'features.file-upload.php',
]; ];
return $terms[$term] ?? null; return $terms[$term] ?? null;
@@ -473,24 +473,24 @@ Search snippet provider: A dirty proof-of-concept:
*/ */
function is_known_snippet(string $term): ?string { function is_known_snippet(string $term): ?string {
$snippets = [ $snippets = [
'global' => ' 'global' => '
The <b>global</b> keyword is used to manipulate <a href="/language.variables.scope">variable scope</a>, and The <b>global</b> keyword is used to manipulate <a href="/language.variables.scope">variable scope</a>, and
there is also the concept of <a href="/language.variables.superglobals">super globals</a> in PHP, there is also the concept of <a href="/language.variables.superglobals">super globals</a> in PHP,
which are special variables with a global scope.', which are special variables with a global scope.',
'string' => ' 'string' => '
There is the <a href="/language.types.string">string type</a>, which is a scalar, There is the <a href="/language.types.string">string type</a>, which is a scalar,
and also many <a href="/ref.strings">string functions.</a>', and also many <a href="/ref.strings">string functions.</a>',
'str' => ' 'str' => '
Many <a href="/ref.strings">string functions</a> begin with <b>str</b>, Many <a href="/ref.strings">string functions</a> begin with <b>str</b>,
and there is also the <a href="/language.types.string">string type</a>.', and there is also the <a href="/language.types.string">string type</a>.',
'_server' => ' '_server' => '
<a href="/reserved.variables.server">$_SERVER</a> <a href="/reserved.variables.server">$_SERVER</a>
is a <a href="/language.variables.superglobals">super global</a>, is a <a href="/language.variables.superglobals">super global</a>,
and is home to many predefined variables that are typically provided by a web server', and is home to many predefined variables that are typically provided by a web server',
'class' => ' 'class' => '
A <a href="/language.oop5">class</a> is an OOP (Object Oriented Programming) concept, A <a href="/language.oop5">class</a> is an OOP (Object Oriented Programming) concept,
and PHP is both a procedural and OOP friendly language.', and PHP is both a procedural and OOP friendly language.',
'function' => ' 'function' => '
PHP contains thousands of functions. You might be interested in how a PHP contains thousands of functions. You might be interested in how a
<a href="/language.functions">function is defined</a>, or <a href="/language.functions">function is defined</a>, or
<a href="/about.prototypes">how to read a function prototype</a>. <a href="/about.prototypes">how to read a function prototype</a>.

View File

@@ -12,7 +12,7 @@ $possible_files = [$df, "manual/$df"];
$site_config = [ $site_config = [
'current' => 'downloads', 'current' => 'downloads',
'css' => ['mirror.css'] 'css' => ['mirror.css']
]; ];
// Find out what is the exact file requested // Find out what is the exact file requested

View File

@@ -76,7 +76,7 @@ function i2c_go()
$COUNTRY = $country; $COUNTRY = $country;
// Set the country in a cookie for a week // Set the country in a cookie for a week
return mirror_setcookie("COUNTRY", "$country,$ipnum", 60*60*24*7); return mirror_setcookie("COUNTRY", "$country,$ipnum", 60 * 60 * 24 * 7);
} }
@@ -115,7 +115,7 @@ function i2c_search_in_index($ip)
// Store for next compare // Store for next compare
$idxpart = (int) $data[0]; $idxpart = (int) $data[0];
$recnum = (int) $data[1]; $recnum = (int) $data[1];
} }
// Return record number found // Return record number found
@@ -140,7 +140,7 @@ function i2c_search_in_db($ip, $idx)
if (!$ipdb) { return $country; } if (!$ipdb) { return $country; }
// Jump to record $idx // Jump to record $idx
fseek($ipdb, ($idx[0] ? (($idx[0]-1)*24) : 0)); fseek($ipdb, ($idx[0] ? (($idx[0] - 1) * 24) : 0));
// Read records until we hit the end of the file, // Read records until we hit the end of the file,
// or we find the range where this IP is, or we // or we find the range where this IP is, or we
@@ -162,8 +162,8 @@ function i2c_search_in_db($ip, $idx)
// Split the record to it's parts // Split the record to it's parts
$range_start = (float) substr($record, 0, 10); $range_start = (float) substr($record, 0, 10);
$range_end = (float) substr($record, 10, 10); $range_end = (float) substr($record, 10, 10);
$country = substr($record, 20, 3); $country = substr($record, 20, 3);
// Getting closer to the end of the indexed region // Getting closer to the end of the indexed region
$idx[0] += 1; $idx[0] += 1;

View File

@@ -52,7 +52,7 @@ function language_choose_code()
$explicitly_specified = language_add(htmlspecialchars($_REQUEST['lang'], ENT_QUOTES, 'UTF-8'), $languages); $explicitly_specified = language_add(htmlspecialchars($_REQUEST['lang'], ENT_QUOTES, 'UTF-8'), $languages);
// Set the language in a cookie for a year // Set the language in a cookie for a year
mirror_setcookie("LAST_LANG", $explicitly_specified, 60*60*24*365); mirror_setcookie("LAST_LANG", $explicitly_specified, 60 * 60 * 24 * 365);
} }
// Specified in a shortcut URL (eg. /en/echo or /pt_br/echo) // Specified in a shortcut URL (eg. /en/echo or /pt_br/echo)
@@ -84,7 +84,7 @@ function language_choose_code()
} }
// Set the language in a cookie for a year // Set the language in a cookie for a year
mirror_setcookie("LAST_LANG", $flang, 60*60*24*365); mirror_setcookie("LAST_LANG", $flang, 60 * 60 * 24 * 365);
} }
// Honor the users own language setting (if available) // Honor the users own language setting (if available)

View File

@@ -10,41 +10,41 @@
http://www.unicode.org/unicode/onlinedat/languages.html http://www.unicode.org/unicode/onlinedat/languages.html
*/ */
$LANGUAGES = [ $LANGUAGES = [
'en' => 'English', 'en' => 'English',
'ar' => 'Arabic', 'ar' => 'Arabic',
'bg' => 'Bulgarian', 'bg' => 'Bulgarian',
'pt_BR' => 'Brazilian Portuguese', 'pt_BR' => 'Brazilian Portuguese',
'zh' => 'Chinese (Simplified)', 'zh' => 'Chinese (Simplified)',
'hk' => 'Chinese (Hong Kong Cantonese)', 'hk' => 'Chinese (Hong Kong Cantonese)',
'tw' => 'Chinese (Traditional)', 'tw' => 'Chinese (Traditional)',
'ca' => 'Catalan', 'ca' => 'Catalan',
'cs' => 'Czech', 'cs' => 'Czech',
'da' => 'Danish', 'da' => 'Danish',
'nl' => 'Dutch', 'nl' => 'Dutch',
'fi' => 'Finnish', 'fi' => 'Finnish',
'fr' => 'French', 'fr' => 'French',
'de' => 'German', 'de' => 'German',
'el' => 'Greek', 'el' => 'Greek',
'he' => 'Hebrew', 'he' => 'Hebrew',
'hu' => 'Hungarian', 'hu' => 'Hungarian',
'id' => 'Indonesian', 'id' => 'Indonesian',
'it' => 'Italian', 'it' => 'Italian',
'ja' => 'Japanese', 'ja' => 'Japanese',
'kr' => 'Korean', 'kr' => 'Korean',
'lt' => 'Lithuanian', 'lt' => 'Lithuanian',
'no' => 'Norwegian', 'no' => 'Norwegian',
'pl' => 'Polish', 'pl' => 'Polish',
'pt' => 'Portuguese', 'pt' => 'Portuguese',
'ro' => 'Romanian', 'ro' => 'Romanian',
'ru' => 'Russian', 'ru' => 'Russian',
'fa' => 'Persian', 'fa' => 'Persian',
'sr' => 'Serbian', 'sr' => 'Serbian',
'sk' => 'Slovak', 'sk' => 'Slovak',
'sl' => 'Slovenian', 'sl' => 'Slovenian',
'es' => 'Spanish', 'es' => 'Spanish',
'sv' => 'Swedish', 'sv' => 'Swedish',
'tr' => 'Turkish', 'tr' => 'Turkish',
'uk' => 'Ukrainian', 'uk' => 'Ukrainian',
]; ];
/* /*
@@ -57,32 +57,32 @@ $LANGUAGES = [
- http://docs.php.net/ - http://docs.php.net/
*/ */
$INACTIVE_ONLINE_LANGUAGES = [ $INACTIVE_ONLINE_LANGUAGES = [
'ar' => 'Arabic', 'ar' => 'Arabic',
'bg' => 'Bulgarian', 'bg' => 'Bulgarian',
'hk' => 'Chinese (Hong Kong Cantonese)', 'hk' => 'Chinese (Hong Kong Cantonese)',
'tw' => 'Chinese (Traditional)', 'tw' => 'Chinese (Traditional)',
'ca' => 'Catalan', 'ca' => 'Catalan',
'cs' => 'Czech', 'cs' => 'Czech',
'da' => 'Danish', 'da' => 'Danish',
'nl' => 'Dutch', 'nl' => 'Dutch',
'fi' => 'Finnish', 'fi' => 'Finnish',
'el' => 'Greek', 'el' => 'Greek',
'he' => 'Hebrew', 'he' => 'Hebrew',
'hu' => 'Hungarian', 'hu' => 'Hungarian',
'id' => 'Indonesian', 'id' => 'Indonesian',
'it' => 'Italian', 'it' => 'Italian',
'kr' => 'Korean', 'kr' => 'Korean',
'lt' => 'Lithuanian', 'lt' => 'Lithuanian',
'no' => 'Norwegian', 'no' => 'Norwegian',
'pl' => 'Polish', 'pl' => 'Polish',
'pt' => 'Portuguese', 'pt' => 'Portuguese',
'fa' => 'Persian', 'fa' => 'Persian',
'ro' => 'Romanian', 'ro' => 'Romanian',
'sr' => 'Serbian', 'sr' => 'Serbian',
'sk' => 'Slovak', 'sk' => 'Slovak',
'sl' => 'Slovenian', 'sl' => 'Slovenian',
'sv' => 'Swedish', 'sv' => 'Swedish',
'uk' => 'Ukrainian', 'uk' => 'Ukrainian',
]; ];
$ACTIVE_ONLINE_LANGUAGES = array_diff($LANGUAGES, $INACTIVE_ONLINE_LANGUAGES); $ACTIVE_ONLINE_LANGUAGES = array_diff($LANGUAGES, $INACTIVE_ONLINE_LANGUAGES);

View File

@@ -171,7 +171,7 @@ function print_link($url, $linktext = false, $target = false, $extras = false)
// make_popup_link() // make_popup_link()
// return a hyperlink to something, within the site, that pops up a new window // return a hyperlink to something, within the site, that pops up a new window
// //
function make_popup_link ($url, $linktext=false, $target=false, $windowprops="", $extras=false) { function make_popup_link ($url, $linktext = false, $target = false, $windowprops = "", $extras = false) {
return sprintf("<a href=\"%s\" target=\"%s\" onclick=\"window.open('%s','%s','%s');return false;\"%s>%s</a>", return sprintf("<a href=\"%s\" target=\"%s\" onclick=\"window.open('%s','%s','%s');return false;\"%s>%s</a>",
htmlspecialchars($url, ENT_QUOTES | ENT_IGNORE), htmlspecialchars($url, ENT_QUOTES | ENT_IGNORE),
($target ?: "_new"), ($target ?: "_new"),
@@ -186,7 +186,7 @@ function make_popup_link ($url, $linktext=false, $target=false, $windowprops="",
// print_popup_link() // print_popup_link()
// print a hyperlink to something, within the site, that pops up a new window // print a hyperlink to something, within the site, that pops up a new window
// //
function print_popup_link($url, $linktext=false, $windowprops="", $target=false, $extras=false) { function print_popup_link($url, $linktext = false, $windowprops = "", $target = false, $extras = false) {
echo make_popup_link($url, $linktext, $windowprops, $target, $extras); echo make_popup_link($url, $linktext, $windowprops, $target, $extras);
} }
@@ -221,7 +221,7 @@ function download_link($file, $title)
if ($size < 1024) { if ($size < 1024) {
echo number_format($size) . 'b'; echo number_format($size) . 'b';
} else { } else {
echo number_format($size/1024) . 'Kb'; echo number_format($size / 1024) . 'Kb';
} }
echo ']'; echo ']';
} }
@@ -445,9 +445,9 @@ function print_news($news, $dog, $max = 5, $onlyyear = null, $return = false) {
if ($return) { if ($return) {
$retval[] = [ $retval[] = [
"title" => $item["title"], "title" => $item["title"],
"id" => $id, "id" => $id,
"permlink" => $permlink, "permlink" => $permlink,
"date" => $newsdate, "date" => $newsdate,
]; ];
continue; continue;
} }
@@ -480,8 +480,8 @@ function site_header($title = '', $config = [])
"meta-navigation" => [], "meta-navigation" => [],
'classes' => '', 'classes' => '',
'layout_span' => 9, 'layout_span' => 9,
"cache" => false, "cache" => false,
"headsup" => "", "headsup" => "",
]; ];
$config = array_merge($defaults, $config); $config = array_merge($defaults, $config);
@@ -543,17 +543,17 @@ function news_toc($sections = null) {
$items = [ $items = [
"news" => [ "news" => [
"title" => "News", "title" => "News",
"link" => "/archive/", "link" => "/archive/",
"children" => print_news($NEWS_ENTRIES, "frontpage", 3, null, true), "children" => print_news($NEWS_ENTRIES, "frontpage", 3, null, true),
], ],
"conferences" => [ "conferences" => [
"title" => "Conferences", "title" => "Conferences",
"link" => "/conferences/", "link" => "/conferences/",
"children" => print_news($NEWS_ENTRIES, "conferences", 3, null, true), "children" => print_news($NEWS_ENTRIES, "conferences", 3, null, true),
], ],
"papers" => [ "papers" => [
"title" => "Call for Papers", "title" => "Call for Papers",
"link" => "/conferences/", "link" => "/conferences/",
"children" => print_news($NEWS_ENTRIES, "cfp", 3, null, true), "children" => print_news($NEWS_ENTRIES, "cfp", 3, null, true),
], ],
]; ];
@@ -629,7 +629,7 @@ function doc_toc_list($lang, $index, $file) {
function doc_toc_title($lang, $index, $file, $elm = "dt") { function doc_toc_title($lang, $index, $file, $elm = "dt") {
foreach ($index as $entry) { foreach ($index as $entry) {
if ($entry[0] == "$file.php") { if ($entry[0] == "$file.php") {
$link = $entry[0]; $link = $entry[0];
$title = $entry[1]; $title = $entry[1];
break; break;
} }

View File

@@ -11,8 +11,8 @@ function posttohost($url, $data)
$data = http_build_query($data); $data = http_build_query($data);
$opts = [ $opts = [
'method' => 'POST', 'method' => 'POST',
'header' => 'Content-type: application/x-www-form-urlencoded', 'header' => 'Content-type: application/x-www-form-urlencoded',
'content' => $data, 'content' => $data,
]; ];

View File

@@ -183,7 +183,7 @@ function myphpnet_save()
} }
// Set all the preferred values for a year // Set all the preferred values for a year
mirror_setcookie("MYPHPNET", join(",", $MYPHPNET), 60*60*24*365); mirror_setcookie("MYPHPNET", join(",", $MYPHPNET), 60 * 60 * 24 * 365);
} }

View File

@@ -1,7 +1,7 @@
<?php <?php
function search_results($res, $q, $profile='all', $per_page=10, $s=0, $l='en', $show_title=true, $show_foot=true, $show_attrib=true) { function search_results($res, $q, $profile = 'all', $per_page = 10, $s = 0, $l = 'en', $show_title = true, $show_foot = true, $show_attrib = true) {
$start_result = $s; $start_result = $s;
$end_result = $s + $res['ResultSet']['totalResultsReturned'] -1; $end_result = $s + $res['ResultSet']['totalResultsReturned'] - 1;
$results_count = ($res['ResultSet']['totalResultsAvailable'] < 100 ? $res['ResultSet']['totalResultsAvailable'] : 'more than 100'); $results_count = ($res['ResultSet']['totalResultsAvailable'] < 100 ? $res['ResultSet']['totalResultsAvailable'] : 'more than 100');
@@ -13,20 +13,20 @@ function search_results($res, $q, $profile='all', $per_page=10, $s=0, $l='en', $
$php_img_dir = 'http://www.php.net/images'; $php_img_dir = 'http://www.php.net/images';
$types = [ $types = [
'pear' => '<img src="' . $php_img_dir . '/pear_item.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>', 'pear' => '<img src="' . $php_img_dir . '/pear_item.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>',
'pecl' => '<img src="' . $php_img_dir . '/pecl_item.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>', 'pecl' => '<img src="' . $php_img_dir . '/pecl_item.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>',
'pecl4win' => '<img src="' . $php_img_dir . '/pecl_item_win.gif" height="22" width="21" style="float:left; margin-left:-31px;"/>', 'pecl4win' => '<img src="' . $php_img_dir . '/pecl_item_win.gif" height="22" width="21" style="float:left; margin-left:-31px;"/>',
'peclbugs' => '<img src="' . $php_img_dir . '/pecl_item_bug.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>', 'peclbugs' => '<img src="' . $php_img_dir . '/pecl_item_bug.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>',
'pearbugs' => '<img src="' . $php_img_dir . '/pear_item_bug.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>', 'pearbugs' => '<img src="' . $php_img_dir . '/pear_item_bug.gif" height="19" width="17" style="float:left; margin-left:-30px;"/>',
'talks' => '<img src="' . $php_img_dir . '/ele-icon.gif" height="20" width="32" style="float:left; margin-left:-40px;"/>', 'talks' => '<img src="' . $php_img_dir . '/ele-icon.gif" height="20" width="32" style="float:left; margin-left:-40px;"/>',
'snaps' => '<img src="' . $php_img_dir . '/logos/php_xpstyle_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'snaps' => '<img src="' . $php_img_dir . '/logos/php_xpstyle_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'cvsweb' => '<img src="' . $php_img_dir . '/logos/php_script_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'cvsweb' => '<img src="' . $php_img_dir . '/logos/php_script_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'viewcvs' => '<img src="' . $php_img_dir . '/logos/php_script_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'viewcvs' => '<img src="' . $php_img_dir . '/logos/php_script_ico.png" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'news' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'news' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'php' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'php' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'doc' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'doc' => '<img src="' . $php_img_dir . '/logos/php-icon-white.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'bugs' => '<img src="' . $php_img_dir . '/php_bug.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>', 'bugs' => '<img src="' . $php_img_dir . '/php_bug.gif" height="32" width="32" style="float:left; margin-left:-40px;"/>',
'gtk' => '<img src="' . $php_img_dir . '/logos/php-gtk-white.gif" height="26" width="32" style="float:left; margin-left:-40px;"/>' 'gtk' => '<img src="' . $php_img_dir . '/logos/php-gtk-white.gif" height="26" width="32" style="float:left; margin-left:-40px;"/>'
]; ];
foreach($res['ResultSet']['Result'] as $i => $hit) { foreach($res['ResultSet']['Result'] as $i => $hit) {
@@ -42,9 +42,9 @@ function search_results($res, $q, $profile='all', $per_page=10, $s=0, $l='en', $
$real_url = preg_replace('@^http://(?!doc|qa|gtk)\w{2,3}\.php\.net(?!/~)(.*)$@', '$1', $hit['Url']); $real_url = preg_replace('@^http://(?!doc|qa|gtk)\w{2,3}\.php\.net(?!/~)(.*)$@', '$1', $hit['Url']);
$displayurl = preg_replace('@^http://(?:(?!doc|qa|php|gtk)\w{2,3}\.)?(.+[^/])/?$@', '$1', $hit['Url']); $displayurl = preg_replace('@^http://(?:(?!doc|qa|php|gtk)\w{2,3}\.)?(.+[^/])/?$@', '$1', $hit['Url']);
$type = substr($displayurl,0,strpos($displayurl,'.')); $type = substr($displayurl,0,strpos($displayurl,'.'));
if($type=='pecl' && strstr($displayurl,"/bugs/")) $type = "peclbugs"; if($type == 'pecl' && strstr($displayurl,"/bugs/")) $type = "peclbugs";
if($type=='pear' && strstr($displayurl,"/bugs/")) $type = "pearbugs"; if($type == 'pear' && strstr($displayurl,"/bugs/")) $type = "pearbugs";
if($type=='smarty') continue; if($type == 'smarty') continue;
$display_title = str_replace(['PHP:', '&amp;'], ['', '&'], $hit['Title']); $display_title = str_replace(['PHP:', '&amp;'], ['', '&'], $hit['Title']);
// Fall back to the PHP logo for unknown hits // Fall back to the PHP logo for unknown hits
@@ -76,7 +76,7 @@ EOB;
<ul id="results_nav_list"> <ul id="results_nav_list">
EOB; EOB;
$start = 0; $start = 0;
for($z=1; $z < 11; $z++) { for($z = 1; $z < 11; $z++) {
if($start > $res['ResultSet']['totalResultsAvailable']) { if($start > $res['ResultSet']['totalResultsAvailable']) {
break; break;
} }

View File

@@ -97,13 +97,13 @@ function manual_notes_load($id)
if ($line == "") { continue; } if ($line == "") { continue; }
@list($id, $sect, $rate, $ts, $user, $note, $up, $down) = explode("|", $line); @list($id, $sect, $rate, $ts, $user, $note, $up, $down) = explode("|", $line);
$notes[$id] = [ $notes[$id] = [
"id" => $id, "id" => $id,
"sect" => $sect, "sect" => $sect,
"rate" => $rate, "rate" => $rate,
"xwhen" => $ts, "xwhen" => $ts,
"user" => $user, "user" => $user,
"note" => base64_decode($note, true), "note" => base64_decode($note, true),
"votes" => ["up"=> (int)$up, "down"=> (int)$down] "votes" => ["up" => (int)$up, "down" => (int)$down]
]; ];
} }
fclose($fp); fclose($fp);
@@ -112,7 +112,7 @@ function manual_notes_load($id)
} }
// Print out one user note entry // Print out one user note entry
function manual_note_display($date, $name, $text, $id, $votes = ['up'=>0, 'down'=>0], $voteOption = true) function manual_note_display($date, $name, $text, $id, $votes = ['up' => 0, 'down' => 0], $voteOption = true)
{ {
if ($name) { if ($name) {
$name = "\n <strong class=\"user\"><em>" . htmlspecialchars($name) . "</em></strong>"; $name = "\n <strong class=\"user\"><em>" . htmlspecialchars($name) . "</em></strong>";
@@ -124,7 +124,7 @@ function manual_note_display($date, $name, $text, $id, $votes = ['up'=>0, 'down'
// New date style will be relative time // New date style will be relative time
$datestr = relTime(new DateTime("@{$date}")); $datestr = relTime(new DateTime("@{$date}"));
$fdatestr = date("Y-m-d h:i", $date); $fdatestr = date("Y-m-d h:i", $date);
$text = clean_note($text); $text = clean_note($text);
// Calculate note rating by up/down votes // Calculate note rating by up/down votes
$vote = $votes['up'] - $votes['down']; $vote = $votes['up'] - $votes['down'];
@@ -201,7 +201,7 @@ function manual_navigation_breadcrumbs(array $setup) {
foreach (array_reverse($setup["parents"]) as $parent) { foreach (array_reverse($setup["parents"]) as $parent) {
$menu[] = [ $menu[] = [
"title" => $parent[1], "title" => $parent[1],
"link" => $parent[0], "link" => $parent[0],
]; ];
} }
@@ -209,7 +209,7 @@ function manual_navigation_breadcrumbs(array $setup) {
if ($setup["up"][0]) { if ($setup["up"][0]) {
$last_item = [ $last_item = [
"title" => $setup["up"][1], "title" => $setup["up"][1],
"link" => $setup["up"][0], "link" => $setup["up"][0],
]; ];
$menu[] = $last_item; $menu[] = $last_item;
} }
@@ -221,7 +221,7 @@ function manual_navigation_related(array $setup) {
foreach ($setup['toc'] as $entry) { foreach ($setup['toc'] as $entry) {
$siblings[] = [ $siblings[] = [
"title" => manual_navigation_methodname($entry[1]), "title" => manual_navigation_methodname($entry[1]),
"link" => $entry[0], "link" => $entry[0],
"current" => $setup["this"][0] == $entry[0], "current" => $setup["this"][0] == $entry[0],
]; ];
} }
@@ -230,7 +230,7 @@ function manual_navigation_related(array $setup) {
if ($setup["up"][0]) { if ($setup["up"][0]) {
$last_item = [ $last_item = [
"title" => $setup["up"][1], "title" => $setup["up"][1],
"link" => $setup["up"][0], "link" => $setup["up"][0],
]; ];
$siblings = [array_merge($last_item, ["children" => $siblings])]; $siblings = [array_merge($last_item, ["children" => $siblings])];
} }
@@ -242,7 +242,7 @@ function manual_navigation_deprecated(array $setup) {
foreach ((array)$setup['toc_deprecated'] as $entry) { foreach ((array)$setup['toc_deprecated'] as $entry) {
$methods[] = [ $methods[] = [
"title" => manual_navigation_methodname($entry[1]), "title" => manual_navigation_methodname($entry[1]),
"link" => $entry[0], "link" => $entry[0],
"current" => $setup["this"][0] == $entry[0], "current" => $setup["this"][0] == $entry[0],
]; ];
} }
@@ -307,12 +307,12 @@ function manual_setup($setup) {
$config = [ $config = [
"current" => "docs", "current" => "docs",
"breadcrumbs" => $breadcrumbs, "breadcrumbs" => $breadcrumbs,
"languages" => array_keys($ACTIVE_ONLINE_LANGUAGES), "languages" => array_keys($ACTIVE_ONLINE_LANGUAGES),
"meta-navigation" => [ "meta-navigation" => [
"contents" => $base . $setup["home"][0], "contents" => $base . $setup["home"][0],
"index" => $base . $setup["up"][0], "index" => $base . $setup["up"][0],
"prev" => $base . $setup["prev"][0], "prev" => $base . $setup["prev"][0],
"next" => $base . $setup["next"][0], "next" => $base . $setup["next"][0],
], ],
"lang" => $setup["head"][1], "lang" => $setup["head"][1],
"thispage" => $setup["this"][0], "thispage" => $setup["this"][0],

View File

@@ -167,7 +167,7 @@ function header_nocache()
function get_available_sqlites() { function get_available_sqlites() {
$allsqlites = [1 => 'sqlite', 2 => 'sqlite3', 4 => 'pdo_sqlite', 8 => 'pdo_sqlite2']; $allsqlites = [1 => 'sqlite', 2 => 'sqlite3', 4 => 'pdo_sqlite', 8 => 'pdo_sqlite2'];
$avail = 0; $avail = 0;
if (function_exists('sqlite_open')) { if (function_exists('sqlite_open')) {
$avail += 1; $avail += 1;
@@ -215,7 +215,7 @@ function get_shortname($page) {
array_shift($sections); array_shift($sections);
// We can atleast remove manual/xx/ // We can atleast remove manual/xx/
$shorturl = substr($page, strrpos($page, "/")+1); $shorturl = substr($page, strrpos($page, "/") + 1);
foreach ($sections as $section) { foreach ($sections as $section) {
// If we know this section // If we know this section
@@ -250,10 +250,10 @@ if (!isset($_SERVER["HTTPS"]) || $_SERVER["HTTPS"] != "on") {
if ($_SERVER["SERVER_PORT"] != '80' && $_SERVER["SERVER_PORT"] != 443) { if ($_SERVER["SERVER_PORT"] != '80' && $_SERVER["SERVER_PORT"] != 443) {
$MYSITE = $proto . '://' . $_SERVER["SERVER_NAME"] . ':' . (int)$_SERVER["SERVER_PORT"] . '/'; $MYSITE = $proto . '://' . $_SERVER["SERVER_NAME"] . ':' . (int)$_SERVER["SERVER_PORT"] . '/';
$msite = 'http://' . $_SERVER["SERVER_NAME"] . ':' . (int)$_SERVER["SERVER_PORT"] . '/'; $msite = 'http://' . $_SERVER["SERVER_NAME"] . ':' . (int)$_SERVER["SERVER_PORT"] . '/';
} else { } else {
$MYSITE = $proto . '://' . $_SERVER["SERVER_NAME"] . '/'; $MYSITE = $proto . '://' . $_SERVER["SERVER_NAME"] . '/';
$msite = 'https://' . $_SERVER["SERVER_NAME"] . '/'; $msite = 'https://' . $_SERVER["SERVER_NAME"] . '/';
} }
// If the mirror is not registered with this name, provide defaults // If the mirror is not registered with this name, provide defaults

View File

@@ -21,36 +21,36 @@ $RELEASES = (function () {
/* PHP 8.1 Release */ /* PHP 8.1 Release */
$data['8.1'] = [ $data['8.1'] = [
'version' => '8.1.9', 'version' => '8.1.9',
'date' => '04 Aug 2022', 'date' => '04 Aug 2022',
'tags' => [], // Set to ['security'] for security releases. 'tags' => [], // Set to ['security'] for security releases.
'sha256' => [ 'sha256' => [
'tar.gz' => '954cf77f7e0a70dc765e7639acdfdccd164be5cd1bce3dbe9d10c58dca631e76', 'tar.gz' => '954cf77f7e0a70dc765e7639acdfdccd164be5cd1bce3dbe9d10c58dca631e76',
'tar.bz2' => '9ebb0e2e571db6fd5930428dcb2d19ed3e050338ec1f1347c282cae92fc086ff', 'tar.bz2' => '9ebb0e2e571db6fd5930428dcb2d19ed3e050338ec1f1347c282cae92fc086ff',
'tar.xz' => '53477e73e6254dc942b68913a58d815ffdbf6946baf61a1f8ef854de524c27bf', 'tar.xz' => '53477e73e6254dc942b68913a58d815ffdbf6946baf61a1f8ef854de524c27bf',
] ]
]; ];
/* PHP 8.0 Release */ /* PHP 8.0 Release */
$data['8.0'] = [ $data['8.0'] = [
'version' => '8.0.22', 'version' => '8.0.22',
'date' => '04 Aug 2022', 'date' => '04 Aug 2022',
'tags' => [], // Set to ['security'] for security releases. 'tags' => [], // Set to ['security'] for security releases.
'sha256' => [ 'sha256' => [
'tar.gz' => '56fce7529a9798fd0895bca3539d2a65b9cac5d23ffbdf6338419c62ed083519', 'tar.gz' => '56fce7529a9798fd0895bca3539d2a65b9cac5d23ffbdf6338419c62ed083519',
'tar.bz2' => 'e342918d3ecd422f10032df0ac3ffb0e17f568fad6cf8e232b6f7a6a1fdc3c9c', 'tar.bz2' => 'e342918d3ecd422f10032df0ac3ffb0e17f568fad6cf8e232b6f7a6a1fdc3c9c',
'tar.xz' => '130937c0fa3050cd33d6c415402f6ccbf0682ae83eb8d39c91164224ddfe57f1', 'tar.xz' => '130937c0fa3050cd33d6c415402f6ccbf0682ae83eb8d39c91164224ddfe57f1',
] ]
]; ];
/* PHP 7.4 Release */ /* PHP 7.4 Release */
$data['7.4'] = [ $data['7.4'] = [
'version' => '7.4.30', 'version' => '7.4.30',
'date' => '09 Jun 2022', 'date' => '09 Jun 2022',
'tags' => ['security'], // Set to ['security'] for security releases 'tags' => ['security'], // Set to ['security'] for security releases
'sha256' => [ 'sha256' => [
'tar.gz' => 'e37ea37e0f79109351ac615da85eb7c2c336101fc5bc802ee79a124a4310dc10', 'tar.gz' => 'e37ea37e0f79109351ac615da85eb7c2c336101fc5bc802ee79a124a4310dc10',
'tar.bz2' => 'b601bb12e53720469b60ea816776cac1c0696b09888a11ad2379b2eee835386e', 'tar.bz2' => 'b601bb12e53720469b60ea816776cac1c0696b09888a11ad2379b2eee835386e',
'tar.xz' => 'ea72a34f32c67e79ac2da7dfe96177f3c451c3eefae5810ba13312ed398ba70d', 'tar.xz' => 'ea72a34f32c67e79ac2da7dfe96177f3c451c3eefae5810ba13312ed398ba70d',
] ]
]; ];

View File

@@ -2,9 +2,9 @@
(function ($uri): void { (function ($uri): void {
// Special redirect cases not able to be captured in error.php // Special redirect cases not able to be captured in error.php
$shortcuts = [ $shortcuts = [
'/?:' => '/language.operators.comparison#language.operators.comparison.ternary', '/?:' => '/language.operators.comparison#language.operators.comparison.ternary',
'/??' => '/language.operators.comparison#language.operators.comparison.coalesce', '/??' => '/language.operators.comparison#language.operators.comparison.coalesce',
'/??=' => '/language.operators.assignment#language.operators.assignment.other', '/??=' => '/language.operators.assignment#language.operators.assignment.other',
]; ];
if (isset($shortcuts[$uri])) { if (isset($shortcuts[$uri])) {
header("Location: {$shortcuts[$uri]}"); header("Location: {$shortcuts[$uri]}");
@@ -53,7 +53,7 @@ include_once 'include/pregen-confs.inc';
include_once 'include/pregen-news.inc'; include_once 'include/pregen-news.inc';
include_once 'include/version.inc'; include_once 'include/version.inc';
mirror_setcookie("LAST_NEWS", $_SERVER["REQUEST_TIME"], 60*60*24*365); mirror_setcookie("LAST_NEWS", $_SERVER["REQUEST_TIME"], 60 * 60 * 24 * 365);
$content = "<div class='home-content'>"; $content = "<div class='home-content'>";
$frontpage = []; $frontpage = [];
@@ -69,7 +69,7 @@ foreach ($NEWS_ENTRIES as $entry) {
} }
foreach ($frontpage as $entry) { foreach ($frontpage as $entry) {
$link = preg_replace('~^(http://php.net/|https://www.php.net/)~', '', $entry["id"]); $link = preg_replace('~^(http://php.net/|https://www.php.net/)~', '', $entry["id"]);
$id = parse_url($entry["id"], PHP_URL_FRAGMENT); $id = parse_url($entry["id"], PHP_URL_FRAGMENT);
$date = date_create($entry['updated']); $date = date_create($entry['updated']);
$date_human = date_format($date, 'd M Y'); $date_human = date_format($date, 'd M Y');
$date_w3c = date_format($date, DATE_W3C); $date_w3c = date_format($date, DATE_W3C);
@@ -133,15 +133,15 @@ site_header("Hypertext Preprocessor",
], ],
'link' => [ 'link' => [
[ [
"rel" => "search", "rel" => "search",
"type" => "application/opensearchdescription+xml", "type" => "application/opensearchdescription+xml",
"href" => $MYSITE . "phpnetimprovedsearch.src", "href" => $MYSITE . "phpnetimprovedsearch.src",
"title" => "Add PHP.net search" "title" => "Add PHP.net search"
], ],
[ [
"rel" => "alternate", "rel" => "alternate",
"type" => "application/atom+xml", "type" => "application/atom+xml",
"href" => $MYSITE . "releases/feed.php", "href" => $MYSITE . "releases/feed.php",
"title" => "PHP Release feed" "title" => "PHP Release feed"
], ],
@@ -175,7 +175,7 @@ echo $content;
if (is_array($CONF_TEASER)) { if (is_array($CONF_TEASER)) {
$conftype = [ $conftype = [
'conference' => 'Upcoming conferences', 'conference' => 'Upcoming conferences',
'cfp' => 'Conferences calling for papers', 'cfp' => 'Conferences calling for papers',
]; ];
$announcements = ""; $announcements = "";
foreach ($CONF_TEASER as $category => $entries) { foreach ($CONF_TEASER as $category => $entries) {

View File

@@ -74,11 +74,11 @@ if (isset($_POST['action'])) {
$result = posttohost( $result = posttohost(
"https://main.php.net/entry/subscribe.php", "https://main.php.net/entry/subscribe.php",
[ [
"request" => $request, "request" => $request,
"email" => $_POST['email'], "email" => $_POST['email'],
"maillist" => $_POST['maillist'], "maillist" => $_POST['maillist'],
"remoteip" => $remote_addr, "remoteip" => $remote_addr,
"referer" => $MYSITE . "mailing-lists.php" "referer" => $MYSITE . "mailing-lists.php"
] ]
); );

View File

@@ -94,10 +94,10 @@ if ($process) {
$result = posttohost( $result = posttohost(
"https://main.php.net/entry/user-note.php", "https://main.php.net/entry/user-note.php",
[ [
'user' => $user, 'user' => $user,
'note' => $note, 'note' => $note,
'sect' => $_POST['sect'], 'sect' => $_POST['sect'],
'ip' => $_SERVER['REMOTE_ADDR'], 'ip' => $_SERVER['REMOTE_ADDR'],
'redirip' => $redirip 'redirip' => $redirip
] ]
); );
@@ -107,7 +107,7 @@ if ($process) {
if (strpos($result, '[TOO MANY NOTES]') !== false) { if (strpos($result, '[TOO MANY NOTES]') !== false) {
print "<p class=\"formerror\">As a security precaution, we only allow a certain number of notes to be submitted per minute. At this time, this number has been exceeded. Please re-submit your note in about a minute.</p>"; print "<p class=\"formerror\">As a security precaution, we only allow a certain number of notes to be submitted per minute. At this time, this number has been exceeded. Please re-submit your note in about a minute.</p>";
} elseif (($pos = strpos($result, '[SPAMMER]')) !== false) { } elseif (($pos = strpos($result, '[SPAMMER]')) !== false) {
$ip = trim(substr($result, $pos+9)); $ip = trim(substr($result, $pos + 9));
$spam_url = $ip_spam_lookup_url . $ip; $spam_url = $ip_spam_lookup_url . $ip;
print '<p class="formerror">Your IP is listed in one of the spammers lists we use, which aren\'t controlled by us. More information is available at <a href="' . $spam_url . '">' . $spam_url . '</a>.</p>'; print '<p class="formerror">Your IP is listed in one of the spammers lists we use, which aren\'t controlled by us. More information is available at <a href="' . $spam_url . '">' . $spam_url . '</a>.</p>';
} elseif (strpos($result, '[SPAM WORD]') !== false) { } elseif (strpos($result, '[SPAM WORD]') !== false) {

View File

@@ -2,7 +2,7 @@
include_once __DIR__ . '/../include/prepend.inc'; include_once __DIR__ . '/../include/prepend.inc';
$page = isset($_GET['page']) ? htmlspecialchars($_GET['page'], ENT_QUOTES, 'UTF-8') : ''; $page = isset($_GET['page']) ? htmlspecialchars($_GET['page'], ENT_QUOTES, 'UTF-8') : '';
$page = strtr($page, ["\r"=>"", "\n"=>""]); $page = strtr($page, ["\r" => "", "\n" => ""]);
// Redirect to new manual page // Redirect to new manual page
mirror_redirect("/manual/" . $page); mirror_redirect("/manual/" . $page);

View File

@@ -37,11 +37,11 @@ const CHALLENGES = [
// generate a challenge // generate a challenge
function gen_challenge() { function gen_challenge() {
$c = CHALLENGES[rand(0, count(CHALLENGES)-1)]; $c = CHALLENGES[rand(0, count(CHALLENGES) - 1)];
$a = rand(0, 9); $a = rand(0, 9);
$an = NUMS[$a]; $an = NUMS[$a];
$b = isset($c[2]) ? $c[2]($a) : rand(0, 9); $b = isset($c[2]) ? $c[2]($a) : rand(0, 9);
$bn = NUMS[$b]; $bn = NUMS[$b];
return [$c[0], $an, $bn, $c[1]($c[0], $an, $bn)]; return [$c[0], $an, $bn, $c[1]($c[0], $an, $bn)];

2
my.php
View File

@@ -6,7 +6,7 @@ include_once __DIR__ . '/include/prepend.inc';
header_nocache(); header_nocache();
// Languages array copy and options to list // Languages array copy and options to list
$langs = $ACTIVE_ONLINE_LANGUAGES; $langs = $ACTIVE_ONLINE_LANGUAGES;
$options = []; $options = [];
// We have post data, and it is an available language // We have post data, and it is an available language

View File

@@ -108,7 +108,7 @@ if (count($temp) > 0) {
if (count($maybe) > 0) { $head_options = ["noindex"]; } if (count($maybe) > 0) { $head_options = ["noindex"]; }
else { $head_options = []; } else { $head_options = []; }
site_header("Manual Quick Reference", $head_options+["current" => "help"]); site_header("Manual Quick Reference", $head_options + ["current" => "help"]);
// Note: $notfound is defined (with htmlspecialchars) inside manual-lookup.php // Note: $notfound is defined (with htmlspecialchars) inside manual-lookup.php
$notfound_enc = urlencode($notfound); $notfound_enc = urlencode($notfound);

View File

@@ -33,18 +33,18 @@ META
function language_chooser(string $currentLang): void { function language_chooser(string $currentLang): void {
$LANGUAGES = [ $LANGUAGES = [
'en' => 'English', 'en' => 'English',
'de' => 'Deutsch', 'de' => 'Deutsch',
'es' => 'Español', 'es' => 'Español',
'fr' => 'Français', 'fr' => 'Français',
'it' => 'Italiano', 'it' => 'Italiano',
'ja' => '日本語', 'ja' => '日本語',
'nl' => 'Nederlands', 'nl' => 'Nederlands',
'pt_BR' => 'Português do Brasil', 'pt_BR' => 'Português do Brasil',
'ru' => 'Русский', 'ru' => 'Русский',
'tr' => 'Türkçe', 'tr' => 'Türkçe',
'zh' => '简体中文', 'zh' => '简体中文',
'ka' => 'ქართული', 'ka' => 'ქართული',
]; ];
// Print out the form with all the options // Print out the form with all the options

View File

@@ -34,14 +34,14 @@ META
function language_chooser(string $currentLang): void { function language_chooser(string $currentLang): void {
$LANGUAGES = [ $LANGUAGES = [
'en' => 'English', 'en' => 'English',
'es' => 'Español', 'es' => 'Español',
'de' => 'Deutsch', 'de' => 'Deutsch',
'pt_BR' => 'Português do Brasil', 'pt_BR' => 'Português do Brasil',
'ru' => 'Русский', 'ru' => 'Русский',
'zh' => '简体中文', 'zh' => '简体中文',
'ka' => 'ქართული', 'ka' => 'ქართული',
'ja' => '日本語', 'ja' => '日本語',
]; ];
// Print out the form with all the options // Print out the form with all the options

View File

@@ -22,7 +22,7 @@ ob_start();
// Flatten major versions out of RELEASES. // Flatten major versions out of RELEASES.
$RELEASED_VERSIONS = array_reduce($RELEASES, 'array_merge', []); $RELEASED_VERSIONS = array_reduce($RELEASES, 'array_merge', []);
$FEED_UPDATED = 0; $FEED_UPDATED = 0;
krsort($RELEASED_VERSIONS); krsort($RELEASED_VERSIONS);
foreach ($RELEASED_VERSIONS as $version => $release) { foreach ($RELEASED_VERSIONS as $version => $release) {
$published = date(DATE_ATOM, strtotime($release["source"][0]["date"])); $published = date(DATE_ATOM, strtotime($release["source"][0]["date"]));

View File

@@ -46,9 +46,9 @@ else {
// Print out common header // Print out common header
$link = [ $link = [
"rel" => "search", "rel" => "search",
"type" => "application/opensearchdescription+xml", "type" => "application/opensearchdescription+xml",
"href" => $MYSITE . "phpnetimprovedsearch.src", "href" => $MYSITE . "phpnetimprovedsearch.src",
"title" => "Add PHP.net search" "title" => "Add PHP.net search"
]; ];
site_header("Search", ["link" => [$link], "current" => "help"]); site_header("Search", ["link" => [$link], "current" => "help"]);

View File

@@ -4,10 +4,10 @@ namespace phpweb\News;
class Entry { class Entry {
public const CATEGORIES = [ public const CATEGORIES = [
'frontpage' => 'PHP.net frontpage news', 'frontpage' => 'PHP.net frontpage news',
'releases' => 'New PHP release', 'releases' => 'New PHP release',
'conferences' => 'Conference announcement', 'conferences' => 'Conference announcement',
'cfp' => 'Call for Papers', 'cfp' => 'Call for Papers',
]; ];
public const WEBROOT = "https://www.php.net"; public const WEBROOT = "https://www.php.net";
@@ -118,8 +118,8 @@ class Entry {
self::ce($dom, "id", $archive, [], $item); self::ce($dom, "id", $archive, [], $item);
self::ce($dom, "published", date(DATE_ATOM), [], $item); self::ce($dom, "published", date(DATE_ATOM), [], $item);
self::ce($dom, "updated", date(DATE_ATOM), [], $item); self::ce($dom, "updated", date(DATE_ATOM), [], $item);
self::ce($dom, "link", null, ['href' => "{$href}#{$this->id}", "rel" => "alternate", "type" => "text/html"], $item); self::ce($dom, "link", null, ['href' => "{$href}#{$this->id}", "rel" => "alternate", "type" => "text/html"], $item);
self::ce($dom, "link", null, ['href' => $link, 'rel' => 'via', 'type' => 'text/html'], $item); self::ce($dom, "link", null, ['href' => $link, 'rel' => 'via', 'type' => 'text/html'], $item);
if (!empty($this->conf_time)) { if (!empty($this->conf_time)) {
$item->appendChild($dom->createElementNs("http://php.net/ns/news", "finalTeaserDate", date("Y-m-d", $this->conf_time))); $item->appendChild($dom->createElementNs("http://php.net/ns/news", "finalTeaserDate", date("Y-m-d", $this->conf_time)));
@@ -185,7 +185,7 @@ class Entry {
do { do {
++$count; ++$count;
$id = $filename . "-" . $count; $id = $filename . "-" . $count;
$basename = "{$id}.xml"; $basename = "{$id}.xml";
} while (file_exists(self::ARCHIVE_ENTRIES_ABS . $basename)); } while (file_exists(self::ARCHIVE_ENTRIES_ABS . $basename));
return $id; return $id;

View File

@@ -27,7 +27,7 @@ class Sorter {
$this->findMinMaxValues($notes); $this->findMinMaxValues($notes);
$this->voteFactor = $this->maxVote - $this->minVote $this->voteFactor = $this->maxVote - $this->minVote
? (1 - .3)/ ($this->maxVote - $this->minVote) ? (1 - .3) / ($this->maxVote - $this->minVote)
: .5; : .5;
$this->ageFactor = $this->maxAge - $this->minAge $this->ageFactor = $this->maxAge - $this->minAge
? 1 / ($this->maxAge - $this->minAge) ? 1 / ($this->maxAge - $this->minAge)
@@ -59,7 +59,7 @@ class Sorter {
$prio = [ $prio = [
'vote' => $this->calcVotePriority($note) * $this->voteWeight, 'vote' => $this->calcVotePriority($note) * $this->voteWeight,
'rating' => $this->calcRatingPriority($note) * $this->ratingWeight, 'rating' => $this->calcRatingPriority($note) * $this->ratingWeight,
'age' => ($note['xwhen'] - $this->minAge) * $this->ageFactor 'age' => ($note['xwhen'] - $this->minAge) * $this->ageFactor
]; ];
$note['sort'] = $prio['value'] = array_sum($prio); $note['sort'] = $prio['value'] = array_sum($prio);
} }

View File

@@ -41,7 +41,7 @@ if ($process) {
* Add, edit, or remove blacklisted users or domains * Add, edit, or remove blacklisted users or domains
* in include/email-validation.inc :: blacklisted(). * in include/email-validation.inc :: blacklisted().
*/ */
$uemail = isset($_POST['email']) ? strtolower($_POST['email']) : ''; $uemail = isset($_POST['email']) ? strtolower($_POST['email']) : '';
if (blacklisted($uemail)) { if (blacklisted($uemail)) {
$errors[] = 'An expected error has been encountered. Please don\'t try again later.'; $errors[] = 'An expected error has been encountered. Please don\'t try again later.';
} }

View File

@@ -2,7 +2,7 @@
$_SERVER['BASE_PAGE'] = 'support.php'; $_SERVER['BASE_PAGE'] = 'support.php';
include_once __DIR__ . '/include/prepend.inc'; include_once __DIR__ . '/include/prepend.inc';
$SIDEBAR_DATA =' $SIDEBAR_DATA = '
<div class="panel" style="position:fixed"> <div class="panel" style="position:fixed">
<div class="headline">Table of Contents</div> <div class="headline">Table of Contents</div>
<div class="body"> <div class="body">

View File

@@ -2,7 +2,7 @@
$_SERVER['BASE_PAGE'] = 'urlhowto.php'; $_SERVER['BASE_PAGE'] = 'urlhowto.php';
include_once __DIR__ . '/include/prepend.inc'; include_once __DIR__ . '/include/prepend.inc';
$SIDEBAR_DATA=' $SIDEBAR_DATA = '
<h3>URL examples</h3> <h3>URL examples</h3>
<p> <p>
We have many kind of URL shortcuts. Here are some We have many kind of URL shortcuts. Here are some