1
0
mirror of https://github.com/php/web-php.git synced 2026-03-31 19:52:29 +02:00
Commit Graph

123 Commits

Author SHA1 Message Date
Gabor Hojtsy
d3b8ef7bf7 BC for README.mirror 2003-06-02 16:35:05 +00:00
Gabor Hojtsy
d0a585baf5 Fixing a bug spotted by Allowee [strangely this is not
needed on official mirror sites to make /manual redirect
to the default language]
2003-05-27 15:49:33 +00:00
Rasmus Lerdorf
ec4bf7f37b Attempt to fix bogus response codes for mirrors running older php versions 2003-05-25 17:42:06 +00:00
Rasmus Lerdorf
c139beb575 Swallow the warning for too many args on mirrors that are running older
versions of PHP
2003-05-25 17:33:43 +00:00
Rasmus Lerdorf
f50f4a6da4 Someone broke BC and a status: header liune is not automatically parsed
to set r->status, so we have to pass it in now.  Without this change were
were sending both a 404 and a 200 on the same response which caused all
sorts of weirdness.  Hopefully this won't break too many mirrors.
2003-05-25 17:18:30 +00:00
Gabor Hojtsy
eab7a75a1b Comment the BC code for pre 4.1.0 mirrors as we have
them disabled now, so autoglobal vars should work on
all mirrors without special preparation

Use $_SERVER['DOCUMENT_ROOT'] for includes
instead of a user defined constant, as the docroot
value is always available [even before prepend.inc]
This ensures consistency and causes no stat() calls

Add myphpnet_...() functions to load, get/set and save
the user preferences, and use them everywhere. This
enables us to easily add new preferences to the same
cookie. Every preference will last for a year this way,
and the cookie will only be set again, if someone
modifies his data on my.php

If this works nicely, then we can easily add a preferred
mirror site setting (and more)

[These changes seem to work on my local mirror]
2003-05-24 19:50:37 +00:00
Gabor Hojtsy
1429cf34b6 Include the manual page instead of redirecting to it.
My local test showed that it works perfectly.

Note that it is important that a 200 OK status is returned,
and that the possible multiple includes are handled with
include_once (in shared-manual.inc too!)
2003-05-24 11:30:34 +00:00
Ilia Alshanetsky
19d6196627 Optimized include logic.
# As it now stands phpweb uses EXTREMELY inefficient way of including files
# by relying on the include_path parameter. Which causes at least 2 useless
# stat() calls for every include. By prefixing all includes & requires for
# files from include/ with the __PHPWEB_INC_PATH__ constants this is avoided.
2003-05-23 13:35:56 +00:00
Wez Furlong
7f28440918 Be more aggresive with load balancing here 2003-05-23 00:10:11 +00:00
Wez Furlong
032a075a09 Add primitive load balancing. 2003-05-22 17:31:44 +00:00
Gabor Hojtsy
bfee72a3fd Move do-download code to the include dir, as we
have no official direct interface for direct downloads,
and it would be painfull to maintain one

Also make the download code much more modern using
$_SERVER and $_REQUEST vars, instead of globals,
also use i2c_realip() for more accurate() IP detection
2003-05-17 13:54:59 +00:00
Gabor Hojtsy
4825297d47 Search for the keyword in the URL without the leading slash 2003-04-23 19:28:25 +00:00
Colin Viebrock
2993ddc2a0 bad, bad boy! 2003-04-11 17:14:47 +00:00
Gabor Hojtsy
d866b6a797 More get URLs for the documentation 2003-04-11 15:55:53 +00:00
Gabor Hojtsy
5a78803785 Adding some get links for the doc howto and the downloads page 2003-04-11 15:04:26 +00:00
Gabor Hojtsy
d6bd07dce8 Adding some comments, and a CVS tag
Also move the external redirects to the array, as we know the
language now before that array is created, so it can be put there
2003-03-01 19:16:12 +00:00
Gabor Hojtsy
dd7ee2600a Updating code to use the new langchooser features.
=> use $LANG as the preferred language
 => use $_SERVER['STRIPPED_URI'] to handle the request

Also remove the download/from/mirror link handler, as it is not
applicapble anymore (/from/a/mirror is used now).
2003-03-01 18:16:59 +00:00
Gabor Hojtsy
c08b0995d4 Get rid of all extension problems, and introduce
download URLs looking even better ;)
2003-02-08 12:19:41 +00:00
Gabor Hojtsy
11b33300a8 Add something to the mirror selection URL, so dumb browsers won't think
that they are actually downloading a zip/exe file, expected after the
extension. Some browsers just does not seem to honor HTTP, and interpret
responses they way they like to...
2003-02-07 15:16:20 +00:00
Gabor Hojtsy
fa52694dc6 And now the URL parsing for the get URL with mirror data... 2003-02-02 20:30:01 +00:00
Gabor Hojtsy
f4475b84ff Commit the first element of the solution for wget problems (similar download
links to pear.php.net)
2003-02-02 20:07:16 +00:00
Gabor Hojtsy
5ded02979c Argh.... I disabled default languages for shortcuts on sites a while ago.
How nobody filed a bug report about it? Nobody uses shortcuts with the
site language default on the mirrors? Is that possible?
2003-01-25 19:23:07 +00:00
Gabor Hojtsy
dba7692764 This probably won't work without that slash... 2003-01-11 12:22:35 +00:00
Gabor Hojtsy
9972303bff Handle bugs and bugstats redirections through the central URL handler 2003-01-11 12:20:49 +00:00
Gabor Hojtsy
961d3ea521 Really replace that .html at the end, so that BC match will work again... 2003-01-08 20:51:38 +00:00
Gabor Hojtsy
c79ac3b684 Get to pear.php.net via /pear (for BC, and to "hide" the dir on php.net) 2003-01-08 19:18:53 +00:00
Gabor Hojtsy
0771b73a48 URL without starting slash in pregs, but URLs with starting
slash in redirects...
2003-01-08 19:11:20 +00:00
Gabor Hojtsy
c3a415c002 Use a slightly prepared $REQUEST_URI for all checks, do not mix
it with $REDIRECT_REDIRECT_ERROR_NOTES, and stuff. $REQUEST_URI
contains all the URI data we need.

Use pregs in all the checks...

Move dochowto link a bit up to it's right place...

Made manual move BC check a bit more intelligent, and redirect to the
right place for printer friendly pages for the first time...
2003-01-08 19:07:54 +00:00
Gabor Hojtsy
4f966f1d88 Add new mirror_redirect() function to redirect to some local or remote URI.
Use $MYSITE instead of $SERVER_NAME for local redirects. It's always the
"best name" for the mirror, most probably the mirrors real mirror name if
it's found.

Use this new function to greatly simplify redirects in the URL handler script.

Also use a switch instead of multiple IFs to react to some special shortcuts.

Still more to come...
2003-01-08 08:06:07 +00:00
Gabor Hojtsy
79b7928b9b Let's be consistent with port numbers. We only support port 80 at
the 90% of redirects, so let's support only port 80 in 100%.
I am going to simplify those redirects, so please hold on ;)

Simplify some BC redirects, do not print a HTML page anymore, as
all common browsers and tools handle redirects...

Use absolute path in file_exists() checks, and includes, as all other
places use that (for consistency).
2003-01-07 21:35:19 +00:00
Gabor Hojtsy
86de10e99c Use Status: instead of HTTP/1.1, because this does not imply any specific
HTTP version number...
2003-01-03 14:19:46 +00:00
Gabor Hojtsy
5a7c79460b Allow any case of pt_BR, and transform it to the right case if in need.
Preserve language setting when redirecting to search page...
2003-01-03 13:27:15 +00:00
Gabor Hojtsy
1eb930d05a Well, comas separate elements in arrays ;) 2002-12-28 15:07:58 +00:00
Gabor Hojtsy
a270ffdd9f Integrate projects redirect to general error handling routine,
to have [nearly] all special redirects at one place.

Remove redirect.php as it was not used
2002-12-28 15:03:28 +00:00
Gabor Hojtsy
fe189350df Support the FAQ display via the regular shortcut feature 2002-12-28 14:37:07 +00:00
Gabor Hojtsy
f22d5f2805 Search in the manual, and not in the whole site if
a shortcut URL cannot be matched to anything else
2002-12-16 17:57:00 +00:00
Gabor Hojtsy
67961428a9 The auto parameter was not used in search.php... 2002-12-14 16:55:25 +00:00
Gabor Hojtsy
c08f8281ba Remove include of configuration.inc. Nothing
from that file was used in this script...
2002-12-14 13:00:26 +00:00
Gabor Hojtsy
efb61b9562 1. Convert tabs to spaces
2. Always show the books page in the mirror's default
   lanaguage if available
3. Reorder redirects logically, put exit after the
   book redirect
2002-12-01 13:24:09 +00:00
Gabor Hojtsy
39b7b28814 Adding support for book quick URLs, like:
http://php.net/hu/books

To read hungarian books list ;)
2002-12-01 13:17:40 +00:00
James Cox
5daf92efaa adding real rd for howto..
# think this is the right way, or i might have broken it..
2002-11-25 04:12:14 +00:00
Gabor Hojtsy
3b9c5ed04f Adding register_globals and registerglobals shortcuts 2002-10-31 07:45:43 +00:00
Gabor Hojtsy
9cfc90d6aa The predefined vars page documents the globals issue
correctly (in a great warning on top of the page)
2002-10-28 17:11:49 +00:00
Derick Rethans
38f70c1767 - Make shortcut work with new Chora 2002-10-19 17:01:27 +00:00
Gabor Hojtsy
f72e44011f IMHO, it's more correct to only return a 200 if we really found
that page. Otherwise, it will go forward in the search process...
2002-08-14 09:40:20 +00:00
Sander Roobol
bc47395282 Override 404's on /manual/*/print/* (part of #18896) and a minor typo. 2002-08-14 09:32:04 +00:00
Gabor Hojtsy
9aaf91a606 Adding README.mirror BC redirection 2002-08-13 11:24:07 +00:00
Colin Viebrock
8a0d1d2f8d and PNG image 2002-08-09 15:25:03 +00:00
Gabor Hojtsy
76cedfe4b7 Adding first stage support for print with notes [printwn] pages 2002-08-03 13:03:53 +00:00
Gabor Hojtsy
591defa313 ref.icap.php is pointless here (because it will be in a subdir)... 2002-08-03 12:21:16 +00:00