Skip to content
Browse files

Framed docs can now select a named anchor in a page

  • Loading branch information...
1 parent bfe8931 commit 20f47494ae22fda00eeabc17c57f7f197177e12a moodler committed Jan 6, 2003
Showing with 8 additions and 3 deletions.
  1. +8 −3 doc/index.php
View
11 doc/index.php
@@ -2,15 +2,20 @@
require("../config.php");
- optional_variable($file, ""); // docs file to view
+ optional_variable($file, ""); // docs file to view
optional_variable($frame, ""); // docs file to view
- optional_variable($lang, ""); // override current language
+ optional_variable($sub, ""); // sub-section (named anchor)
+ optional_variable($lang, ""); // override current language
if (!empty($lang)) {
$SESSION->doclang = $lang;
save_session("SESSION");
}
+ if (!empty($sub)) {
+ $sub = "#$sub";
+ }
+
if (empty($file)) {
$include = false;
if (empty($frame)) {
@@ -38,6 +43,6 @@
<FRAME NAME="top" SRC="top.php">
<FRAMESET COLS="200,*">
<FRAME NAME="contents" SRC="contents.php">
- <FRAME NAME="main" SRC="index.php?file=<?PHP echo "$file"; ?>">
+ <FRAME NAME="main" SRC="index.php?file=<?PHP echo "$file$sub"; ?>">
</FRAMESET>
</FRAMESET>

0 comments on commit 20f4749

Please sign in to comment.
Something went wrong with that request. Please try again.