cvs: phpweb /include shared-manual.inc
| From: | Gabor Hojtsy | Date: | Wed, 04 Jun 2003 09:12:12 +0000 |
| Subject: | cvs: phpweb /include shared-manual.inc | ||
| Groups: | php.mirrors | ||
| Request: | Send a blank email to php-mirrors+get-18491@lists.php.net to get a copy of this message | ||
goba Wed Jun 4 05:12:12 2003 EDT
Modified files:
/phpweb/include shared-manual.inc
Log:
Hide the left side bar and the top and bottom navbars
from mnogosearch, so the indexing will be a bit faster,
and the results will be more accurate. Mnogo will still
find all the pages starting from the TOCs and indexes
Also use $MYSITE instead of $SERVER_NAME and
$SERVER_PORT, as we have the mirrors detected
name in $MYSITE
Also remove some unused code from the user note
handling functions
Index: phpweb/include/shared-manual.inc
diff -u phpweb/include/shared-manual.inc:1.192 phpweb/include/shared-manual.inc:1.193
--- phpweb/include/shared-manual.inc:1.192 Mon Jun 2 05:49:46 2003
+++ phpweb/include/shared-manual.inc Wed Jun 4 05:12:11 2003
@@ -26,7 +26,8 @@
function makeBorderTOC($this) {
global $NEXT, $PREV, $UP, $HOME, $TOC, $PHP_SELF, $DOCUMENT_ROOT, $SIDEBAR_DATA;
- $SIDEBAR_DATA.= '<table border="0" cellpadding="0"
cellspacing="5" width="100%">';
+ $SIDEBAR_DATA .= '<!--UdmComment-->' . "\n" .
+ '<table border="0" cellpadding="0"
cellspacing="5" width="100%">';
$SIDEBAR_DATA.= '<tr valign="top"><td>' .
make_link('./', make_image('caret-t.gif', '^') . $HOME[1] ) .
@@ -60,8 +61,8 @@
"<br />\n";
}
- $SIDEBAR_DATA.= '</small></td></tr>';
- $SIDEBAR_DATA.= '</table>';
+ $SIDEBAR_DATA .= '</small></td></tr>';
+ $SIDEBAR_DATA .= '</table><!--/UdmComment-->';
}
// Print out manual navigation bar
@@ -69,7 +70,8 @@
global $NEXT, $PREV, $tstamp, $SERVER_NAME, $SERVER_PORT,
$PHP_SELF, $LANGUAGES, $INACTIVE_ONLINE_LANGUAGES, $REQUEST_URI, $www_static_root;
- echo '<table border="0" width="100%" bgcolor="#e0e0e0"
cellpadding="0" cellspacing="4">';
+ echo '<!--UdmComment-->' . "\n" .
+ '<table border="0" width="100%" bgcolor="#e0e0e0"
cellpadding="0" cellspacing="4">';
echo '<tr><td>';
if ($PREV[1]) {
@@ -119,7 +121,7 @@
}
echo '</td><td align="right"
valign="bottom"><small>Last updated: ' . $tstamp .
'</small></td></tr>';
- echo "</table>\n";
+ echo "</table>\n<!--/UdmComment-->\n";
}
@@ -213,18 +215,14 @@
// Print out all user notes for this manual page
function manualUserNotes($title, $id) {
- global $PHP_SELF, $SERVER_NAME, $SERVER_PORT;
- $cur = substr(dirname($PHP_SELF),-2);
- if($cur=='al') $cur='en';
+ global $PHP_SELF, $MYSITE;
# don't want .php at the end of the id.
if (substr($id,-4) == '.php') $id = substr($id,0,-4);
$notes = manualGetUserNotes($title, $id);
- $back_url = 'http://' . $SERVER_NAME .
- (($SERVER_PORT==80) ? '' : ':'.$SERVER_PORT ) .
- $PHP_SELF;
+ $back_url = substr($MYSITE, 0, -1) . $PHP_SELF;
// Link target to add a note to the current manual page,
// and it's extended form with a [+] image
@@ -380,18 +378,10 @@
// Print out all user notes for this manual page
function manualPrintUserNotes($title, $id) {
- global $PHP_SELF, $SERVER_NAME, $SERVER_PORT;
- $cur = substr(dirname($PHP_SELF),-2);
- if ($cur=='al') $cur='en';
-
- # don't want .php at the end of the id.
- if (substr($id,-4) == '.php') $id = substr($id,0,-4);
+ // Don't want .php at the end of the id.
+ if (substr($id, -4) == '.php') { $id = substr($id, 0, -4); }
$notes = manualGetUserNotes($title, $id);
-
- $back_url = 'http://' . $SERVER_NAME .
- (($SERVER_PORT==80) ? '' : ':'.$SERVER_PORT ) .
- $PHP_SELF;
echo "<hr size=\"1\" noshade><h2>User Contributed
Notes</h2>";