Results Page:
EOB;
- $start = 0;
- for($z = 1; $z < 11; $z++) {
- if($start > $res['ResultSet']['totalResultsAvailable']) {
- break;
- }
+ $start = 0;
+ for($z = 1; $z < 11; $z++) {
+ if($start > $res['ResultSet']['totalResultsAvailable']) {
+ break;
+ }
- $class = '';
- if ($start == $start_result) {
- $class = 'current';
- }
+ $class = '';
+ if ($start == $start_result) {
+ $class = 'current';
+ }
- printf('%d ', $class, urlencode($q), $start, $profile, urlencode($l), $z);
- $start += $per_page;
- }
- echo ' ';
+ printf('%d ', $class, urlencode($q), $start, $profile, urlencode($l), $z);
+ $start += $per_page;
+ }
+ echo '';
endif;
}
diff --git a/include/site.inc b/include/site.inc
index dd147e22f8..500b463c71 100644
--- a/include/site.inc
+++ b/include/site.inc
@@ -76,11 +76,11 @@ function mirror_provider($site = false)
if (!$site) { $site = $MYSITE; }
if (isset($MIRRORS[$site])) {
- return $MIRRORS[$site][1];
+ return $MIRRORS[$site][1];
}
if (isset($MIRRORS[$_SERVER['SERVER_ADDR']])) {
- return $MIRRORS[$_SERVER['SERVER_ADDR']][1];
+ return $MIRRORS[$_SERVER['SERVER_ADDR']][1];
}
return false;
diff --git a/mailing-lists.php b/mailing-lists.php
index 9ecb0522cc..b6ade39d97 100644
--- a/mailing-lists.php
+++ b/mailing-lists.php
@@ -93,7 +93,7 @@
if (!empty($error)) {
echo "$error
";
} else {
-?>
+ ?>
A request has been entered into the mailing list processing queue. You
should receive an email at shortly describing
@@ -237,71 +237,71 @@
];
- // array of lists (list, name, short desc., moderated, archive, digest, newsgroup)
- $internals_mailing_lists = [
-
- 'PHP and Zend Engine internals lists',
- [
- 'internals', 'Internals list',
- 'A medium volume list for those who want to help out with the development of PHP',
- false, 'php-internals', true, "php.internals",
- ],
- [
- 'internals-win', 'Windows Internals list',
- 'A low volume list for those who want to help out with the development of PHP on Windows',
- false, false, true, "php.internals.win",
- ],
- [
- 'php-cvs', 'Git commit list',
- 'All commits to internals (php-src) and the Zend Engine are posted to this list automatically',
- true, true, false, "php.cvs",
- ],
- [
- 'git-pulls', 'Git pull requests',
- 'Pull requests from Github',
- false, false, false, "php.git-pulls",
- ],
- [
- 'php-qa', 'Quality Assurance list',
- 'List for the members of the PHP-QA Team',
- false, true, false, "php.qa",
- ],
- [
- 'php-bugs', 'General bugs',
- 'General bug activity are posted here',
- false, false, false, "php.bugs",
- ],
- [
- 'standards', 'PHP Standardization and interoperability list',
- 'Development of language standards',
- false, false, false, "php.standards",
- ],
-
- 'PHP internal website mailing lists',
- [
- 'php-webmaster', 'PHP php.net internal infrastructure discussion',
- 'List for discussing and maintaining the php.net web infrastructure.
+// array of lists (list, name, short desc., moderated, archive, digest, newsgroup)
+$internals_mailing_lists = [
+
+ 'PHP and Zend Engine internals lists',
+ [
+ 'internals', 'Internals list',
+ 'A medium volume list for those who want to help out with the development of PHP',
+ false, 'php-internals', true, "php.internals",
+ ],
+ [
+ 'internals-win', 'Windows Internals list',
+ 'A low volume list for those who want to help out with the development of PHP on Windows',
+ false, false, true, "php.internals.win",
+ ],
+ [
+ 'php-cvs', 'Git commit list',
+ 'All commits to internals (php-src) and the Zend Engine are posted to this list automatically',
+ true, true, false, "php.cvs",
+ ],
+ [
+ 'git-pulls', 'Git pull requests',
+ 'Pull requests from Github',
+ false, false, false, "php.git-pulls",
+ ],
+ [
+ 'php-qa', 'Quality Assurance list',
+ 'List for the members of the PHP-QA Team',
+ false, true, false, "php.qa",
+ ],
+ [
+ 'php-bugs', 'General bugs',
+ 'General bug activity are posted here',
+ false, false, false, "php.bugs",
+ ],
+ [
+ 'standards', 'PHP Standardization and interoperability list',
+ 'Development of language standards',
+ false, false, false, "php.standards",
+ ],
+
+ 'PHP internal website mailing lists',
+ [
+ 'php-webmaster', 'PHP php.net internal infrastructure discussion',
+ 'List for discussing and maintaining the php.net web infrastructure.
For general PHP support questions, see "General Mailing Lists" or the support page ',
- false, false, false, "php.webmaster",
- ],
-
- 'PHP documentation mailing lists',
- [
- 'phpdoc', 'Documentation discussion',
- 'List for discussing the PHP documentation',
- false, true, false, "php.doc",
- ],
- [
- 'doc-cvs', 'Documentation changes and commits',
- 'Changes to the documentation are posted here',
- true, "php-doc-cvs", false, "php.doc.cvs",
- ],
- [
- 'doc-bugs', 'Documentation bugs',
- 'Documentation bug activity (translations, sources, and build system) are posted here',
- true, 'php-doc-bugs', false, "php.doc.bugs",
- ],
- ];
+ false, false, false, "php.webmaster",
+ ],
+
+ 'PHP documentation mailing lists',
+ [
+ 'phpdoc', 'Documentation discussion',
+ 'List for discussing the PHP documentation',
+ false, true, false, "php.doc",
+ ],
+ [
+ 'doc-cvs', 'Documentation changes and commits',
+ 'Changes to the documentation are posted here',
+ true, "php-doc-cvs", false, "php.doc.cvs",
+ ],
+ [
+ 'doc-bugs', 'Documentation bugs',
+ 'Documentation bug activity (translations, sources, and build system) are posted here',
+ true, 'php-doc-bugs', false, "php.doc.bugs",
+ ],
+];
// Print out a table for a given list array
function output_lists_table($mailing_lists): void
diff --git a/manual/add-note.php b/manual/add-note.php
index 1398e5d006..5f8388c243 100644
--- a/manual/add-note.php
+++ b/manual/add-note.php
@@ -125,8 +125,8 @@
// There was no error returned
else {
echo '
Your submission was successful -- thanks for contributing! Note ',
- 'that it will not show up for up to a few hours, ',
- 'but it will eventually find its way.
';
+ 'that it will not show up for up to a few hours, ',
+ 'but it will eventually find its way.';
}
// Print out common footer, and end page
@@ -147,7 +147,7 @@
// Any needed variable was missing => display instructions
else {
-?>
+ ?>
Adding a note to the manual
@@ -332,7 +332,7 @@
// There is no section to add note to
if (!isset($_POST['sect'], $_POST['redirect'])) {
echo 'To add a note, you must click on the "Add Note" button (the plus sign) ',
- 'on the bottom of a manual page so we know where to add the note!
';
+ 'on the bottom of a manual page so we know where to add the note!';
}
// Everything is in place, so we can display the form
diff --git a/manual/vote-note.php b/manual/vote-note.php
index fa8de7c7e2..de495c4790 100644
--- a/manual/vote-note.php
+++ b/manual/vote-note.php
@@ -15,95 +15,95 @@
$master_url = "https://main.php.net/entry/user-notes-vote.php";
if ($_SERVER['REQUEST_METHOD'] == 'POST') {
- if (isset($_SERVER['HTTP_X_JSON']) && $_SERVER['HTTP_X_JSON'] == 'On' && !empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
- $response = [];
- $hash = substr(md5($_REQUEST['page']), 0, 16);
- $notes_file = $_SERVER['DOCUMENT_ROOT'] . "/backend/notes/" . substr($hash, 0, 2) . "/$hash";
- if (!file_exists($notes_file)) {
- $response["success"] = false;
- $response["msg"] = "Invalid request.";
- }
- else {
- $data = [
- "noteid" => $_REQUEST['id'],
- "sect" => $_REQUEST['page'],
- "vote" => $_REQUEST['vote'],
- "ip" => $_SERVER['REMOTE_ADDR'],
- ];
- if (($r = posttohost($master_url, $data)) === null || strpos($r,"failed to open socket to") !== false) {
- $response["success"] = false;
- $response["msg"] = "Could not process your request at this time. Please try again later...";
- }
- else {
- $r = json_decode($r);
- if (isset($r->status, $r->votes) && $r->status) {
- $response["success"] = true;
- $response["update"] = (int)$r->votes;
- } elseif (isset($r->status, $r->message) && !$r->status) {
- $response["success"] = false;
- $response["msg"] = $r->message;
- } else {
- $response["success"] = false;
- $response["msg"] = "The server did not respond properly. Please try again later...";
- }
- }
- }
- echo json_encode($response);
- exit;
- }
- if (!empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
- if (!empty($_POST['challenge']) && !empty($_POST['func']) || empty($_POST['arga']) || empty($_POST['argb'])) {
- if (!test_answer($_POST['func'], $_POST['arga'], $_POST['argb'], $_POST['challenge'])) {
- $error = "Incorrect answer! Please try again.";
- }
- else {
- if ($_REQUEST['vote'] === 'up') {
- $N[$_REQUEST['id']]->upvotes++;
- }
- elseif ($_REQUEST['vote'] === 'down') {
- $N[$_REQUEST['id']]->downvotes++;
- }
+ if (isset($_SERVER['HTTP_X_JSON']) && $_SERVER['HTTP_X_JSON'] == 'On' && !empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
+ $response = [];
$hash = substr(md5($_REQUEST['page']), 0, 16);
$notes_file = $_SERVER['DOCUMENT_ROOT'] . "/backend/notes/" . substr($hash, 0, 2) . "/$hash";
- if (file_exists($notes_file)) {
- $data = [
- "noteid" => $_REQUEST['id'],
- "sect" => $_REQUEST['page'],
- "vote" => $_REQUEST['vote'],
- "ip" => $_SERVER['REMOTE_ADDR'],
- ];
- if (($r = posttohost($master_url, $data)) !== null && strpos($r,"failed to open socket to") === false) {
- $r = json_decode($r);
- if (isset($r->status, $r->votes) && $r->status) {
- $thankyou = true;
- } else {
- $error = "Invalid request.";
+ if (!file_exists($notes_file)) {
+ $response["success"] = false;
+ $response["msg"] = "Invalid request.";
+ }
+ else {
+ $data = [
+ "noteid" => $_REQUEST['id'],
+ "sect" => $_REQUEST['page'],
+ "vote" => $_REQUEST['vote'],
+ "ip" => $_SERVER['REMOTE_ADDR'],
+ ];
+ if (($r = posttohost($master_url, $data)) === null || strpos($r,"failed to open socket to") !== false) {
+ $response["success"] = false;
+ $response["msg"] = "Could not process your request at this time. Please try again later...";
+ }
+ else {
+ $r = json_decode($r);
+ if (isset($r->status, $r->votes) && $r->status) {
+ $response["success"] = true;
+ $response["update"] = (int)$r->votes;
+ } elseif (isset($r->status, $r->message) && !$r->status) {
+ $response["success"] = false;
+ $response["msg"] = $r->message;
+ } else {
+ $response["success"] = false;
+ $response["msg"] = "The server did not respond properly. Please try again later...";
+ }
+ }
+ }
+ echo json_encode($response);
+ exit;
+ }
+ if (!empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
+ if (!empty($_POST['challenge']) && !empty($_POST['func']) || empty($_POST['arga']) || empty($_POST['argb'])) {
+ if (!test_answer($_POST['func'], $_POST['arga'], $_POST['argb'], $_POST['challenge'])) {
+ $error = "Incorrect answer! Please try again.";
+ }
+ else {
+ if ($_REQUEST['vote'] === 'up') {
+ $N[$_REQUEST['id']]->upvotes++;
+ }
+ elseif ($_REQUEST['vote'] === 'down') {
+ $N[$_REQUEST['id']]->downvotes++;
+ }
+ $hash = substr(md5($_REQUEST['page']), 0, 16);
+ $notes_file = $_SERVER['DOCUMENT_ROOT'] . "/backend/notes/" . substr($hash, 0, 2) . "/$hash";
+ if (file_exists($notes_file)) {
+ $data = [
+ "noteid" => $_REQUEST['id'],
+ "sect" => $_REQUEST['page'],
+ "vote" => $_REQUEST['vote'],
+ "ip" => $_SERVER['REMOTE_ADDR'],
+ ];
+ if (($r = posttohost($master_url, $data)) !== null && strpos($r,"failed to open socket to") === false) {
+ $r = json_decode($r);
+ if (isset($r->status, $r->votes) && $r->status) {
+ $thankyou = true;
+ } else {
+ $error = "Invalid request.";
+ }
+ }
+ else {
+ $error = "Invalid request.";
+ }
+ }
+ else {
+ $error = "Invalid request.";
+ }
}
- }
- else {
- $error = "Invalid request.";
- }
}
else {
- $error = "Invalid request.";
+ $error = "You did not answer the spam challenge question.";
}
- }
}
else {
- $error = "You did not answer the spam challenge question.";
+ $error = "Invalid request.";
}
- }
- else {
- $error = "Invalid request.";
- }
}
else {
- // Site header
- site_header("Vote On User Notes");
- $headerset = true;
+ // Site header
+ site_header("Vote On User Notes");
+ $headerset = true;
- if (!empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
-?>
+ if (!empty($_REQUEST['id']) && !empty($_REQUEST['page']) && ($N = manual_notes_load($_REQUEST['page'])) && array_key_exists($_REQUEST['id'], $N) && !empty($_REQUEST['vote']) && ($_REQUEST['vote'] === 'up' || $_REQUEST['vote'] === 'down')) {
+ ?>
Voting
@@ -122,17 +122,17 @@
The Note You're Voting On
+ $backID = htmlspecialchars($_REQUEST['id']);
+ $backPAGE = htmlspecialchars($_REQUEST['page']);
+ manual_note_display($N[$_REQUEST['id']], false);
+ ?>
EOL;
-if (!$headerset) {
- site_header("Error - Voting");
- $headerset = true;
-}
-?>
+ if (!$headerset) {
+ site_header("Error - Voting");
+ $headerset = true;
+ }
+ ?>
Voting
@@ -170,24 +170,24 @@
+ if ($error != "Invalid request.") {
+ ?>
The Note You're Voting On
+ $backID = htmlspecialchars($_REQUEST['id']);
+ $backPAGE = htmlspecialchars($_REQUEST['page']);
+ manual_note_display($N[$_REQUEST['id']], false);
+ ?>
+ site_header("Thank you for voting!");
+ $headerset = true;
+ ?>
Thanks for voting!
To go back to the user notes page click here .
diff --git a/quickref.php b/quickref.php
index 8fd1479bfa..94644cbcfb 100644
--- a/quickref.php
+++ b/quickref.php
@@ -131,7 +131,7 @@ function quickref_table($functions, $sort = true): void
'
Full website search ',
-]);
+ site_footer([
+ "sidebar" => '
Full website search ',
+ ]);
}
diff --git a/releases/5_3_3.php b/releases/5_3_3.php
index 516ddd3762..06a0025791 100644
--- a/releases/5_3_3.php
+++ b/releases/5_3_3.php
@@ -31,7 +31,7 @@ public function Bar() {
}
}
?>');
- ?>
+?>
There is no impact on migration from 5.2.x because namespaces were only introduced in PHP 5.3.
diff --git a/releases/8.0/index.php b/releases/8.0/index.php
index 08a72b721c..01da505548 100644
--- a/releases/8.0/index.php
+++ b/releases/8.0/index.php
@@ -1,5 +1,5 @@
PHP 8.1
RFC
= message(
- 'documentation',
- $lang,
- ) ?>
+ 'documentation',
+ $lang,
+ ) ?>
@@ -98,9 +98,9 @@ PHP
RFC
= message(
- 'documentation',
- $lang,
- ) ?>
+ 'documentation',
+ $lang,
+ ) ?>
@@ -248,9 +248,9 @@ PHP
RFC
= message(
- 'documentation',
- $lang,
- ) ?>
+ 'documentation',
+ $lang,
+ ) ?>
@@ -286,9 +286,9 @@ PHP
RFC
= message(
- 'documentation',
- $lang,
- ) ?>
+ 'documentation',
+ $lang,
+ ) ?>
diff --git a/releases/8.3/index.php b/releases/8.3/index.php
index 3035c038b6..510973e0b3 100644
--- a/releases/8.3/index.php
+++ b/releases/8.3/index.php
@@ -1,5 +1,5 @@
\n
%1\$s \n
\n Released: %s \n Announcement: ",
- ($pos = strpos($ver, " ")) ? substr($ver, 0, $pos) : $ver,
- $date);
+ ($pos = strpos($ver, " ")) ? substr($ver, 0, $pos) : $ver,
+ $date);
if ($announcement) {
if (is_array($announcement)) {
@@ -237,11 +237,11 @@ function mk_rel(int $major,
continue;
}
printf(' %s ',
- $major, $src["filename"], $src["name"]);
+ $major, $src["filename"], $src["name"]);
}
foreach ($windows as $src) {
printf('%s ',
- ($major == 5 ? "php5" : "win32"), $src["filename"], $src["name"]);
+ ($major == 5 ? "php5" : "win32"), $src["filename"], $src["name"]);
}
}
diff --git a/search.php b/search.php
index fb963474c4..c665e66f84 100644
--- a/search.php
+++ b/search.php
@@ -33,7 +33,7 @@
mirror_redirect($MYSITE . "results.php?q={$ucp}&p={$_FORM['show']}&l=$LANG");
break;
- // Covers the rest
+ // Covers the rest
default:
$p = urlencode($_FORM['show']);
mirror_redirect($MYSITE . "results.php?q={$ucp}&l=$LANG&p=$p");
diff --git a/submit-event.php b/submit-event.php
index 55b51ce8a0..fecf895a85 100644
--- a/submit-event.php
+++ b/submit-event.php
@@ -82,7 +82,7 @@
}
if (!checkdate($_POST['smonth'], $_POST['sday'], $_POST['syear'])) {
- $errors[] = "You must specify a valid start date.";
+ $errors[] = "You must specify a valid start date.";
}
else {
$sdate = mktime(0, 0, 1, $_POST['smonth'], $_POST['sday'], $_POST['syear']);
@@ -231,7 +231,7 @@
"Training"]; // 2 = conference.. which should be on php.net/conferences instead
- display_options($cat, $_POST['category']);
+display_options($cat, $_POST['category']);
?>
@@ -269,8 +269,8 @@ function display_options($options, $current): void
{
foreach ($options as $k => $v) {
echo '', htmlentities($v, ENT_QUOTES | ENT_IGNORE, 'UTF-8'), " \n";
+ ($k == $current ? ' selected="selected"' : ''),
+ '>', htmlentities($v, ENT_QUOTES | ENT_IGNORE, 'UTF-8'), "\n";
}
}
diff --git a/supported-versions.php b/supported-versions.php
index a6c6ffe9e7..8fa6130036 100644
--- a/supported-versions.php
+++ b/supported-versions.php
@@ -51,11 +51,11 @@
$release): ?>
+ $initial = get_branch_release_date($branch);
+ $until = get_branch_bug_eol_date($branch);
+ $eol = get_branch_security_eol_date($branch);
+ $now = new DateTime('now');
+ ?>
diff --git a/thanks.php b/thanks.php
index d1919665b3..2649527db0 100644
--- a/thanks.php
+++ b/thanks.php
@@ -267,12 +267,12 @@
+foreach ($historical_mirrors as $m) {
+ ?>
:
+}
+?>
PHP.net is very grateful for all their support.