File: mirrors_ini.php

package info (click to toggle)
php-doc 20061001-1
  • links: PTS
  • area: non-free
  • in suites: etch, etch-m68k
  • size: 45,764 kB
  • ctags: 1,611
  • sloc: xml: 502,485; php: 7,645; cpp: 500; makefile: 297; perl: 161; sh: 141; awk: 28
file content (41 lines) | stat: -rw-r--r-- 957 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php

/* 
   This file is part of the Windows Compiled HTML Help
   Manual Generator of the PHP Documentation project.
   
   This script generates mirrors.ini from mirrors.inc ( can be
   downloaded from http://MIRROR.php.net/include/mirrors.inc )
*/

// Load the mirrors file in
include_once "mirrors.inc";

// Get mirror site addresses
$mirrors = array_keys($MIRRORS);

// Write out mirror information
$fp = fopen($RELEASE_DIR . "/mirrors.ini", "w");

fwrite($fp,
"# =================================================
# PHP Manual CHM version mirror list configuration
# =================================================

# Possible mirrors for online functions (only those
# mirrors are listed, which were active when this
# list was generated)

[mirrors]
");

// Write out all active mirror sites
foreach ($MIRRORS as $mirror => $mirrorinfo) {
    if ($mirrorinfo[7] == MIRROR_OK) {
	    fwrite($fp, "mirror = \"$mirror\"\n");
    }
}

fclose($fp);

?>