cvs: peardoc /en/package/database/db-nestedset intro.xml /ja/package/database/db-nestedset intro.xml

[email protected] ("Brett Bieber")
Newsgroups php.pear.doc
Message-ID <cvssaltybeagle1198117197@cvsserver>
saltybeagle		Thu Dec 20 02:19:57 2007 UTC

  Modified files:              
    /peardoc/ja/package/database/db-nestedset	intro.xml 
    /peardoc/en/package/database/db-nestedset	intro.xml 
  Log:
  Doc Bug #12676 DSN example was incorrect, remove parens from require statements fix example.
  
http://cvs.php.net/viewvc.cgi/peardoc/ja/package/database/db-nestedset/intro.xml?r1=1.3&r2=1.4&diff_format=u
Index: peardoc/ja/package/database/db-nestedset/intro.xml
diff -u peardoc/ja/package/database/db-nestedset/intro.xml:1.3 peardoc/ja/package/database/db-nestedset/intro.xml:1.4
--- peardoc/ja/package/database/db-nestedset/intro.xml:1.3	Sat Oct 27 14:37:57 2007
+++ peardoc/ja/package/database/db-nestedset/intro.xml	Thu Dec 20 02:19:57 2007
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<!-- $Revision: 1.3 $ -->
+<!-- $Revision: 1.4 $ -->
 <!-- EN-Revision: 1.5 Maintainer: takagi Status: ready -->
 <refentry id="package.DB_NestedSet">
  <refnamediv>
@@ -62,12 +62,12 @@
     それをデータベースに格納して表示します。
    </para>
    <programlisting role="php"><![CDATA[
-require_once('DB/NestedSet.php');
-require_once('DB/NestedSet/Output.php');
-require_once('HTML/Menu.php');
+require_once 'DB/NestedSet.php';
+require_once 'DB/NestedSet/Output.php';
+require_once 'HTML/Menu.php';
 $DatabasePointer = mysql_connect("localhost", "user", "pwd");
 mysql_select_db("database", $DatabasePointer);
-$dsn = 'mysql://database:pwd@localhost/user';
+$dsn = 'mysql://user:pwd@localhost/database';
 // テーブルに必要なカラム
 $params = array(
 	'id'        => 'id',
@@ -99,6 +99,7 @@
     'titleField' => 'name',
     'urlField' => 'url');
 $output =& DB_NestedSet_Output::factory($params, 'Menu');
+$structure = $output->returnStructure();
 $menu = & new HTML_Menu($structure, 'sitemap');
 $menu->forceCurrentUrl($currentUrl);
 $menu->show();
http://cvs.php.net/viewvc.cgi/peardoc/en/package/database/db-nestedset/intro.xml?r1=1.5&r2=1.6&diff_format=u
Index: peardoc/en/package/database/db-nestedset/intro.xml
diff -u peardoc/en/package/database/db-nestedset/intro.xml:1.5 peardoc/en/package/database/db-nestedset/intro.xml:1.6
--- peardoc/en/package/database/db-nestedset/intro.xml:1.5	Thu Oct 25 12:31:15 2007
+++ peardoc/en/package/database/db-nestedset/intro.xml	Thu Dec 20 02:19:57 2007
@@ -1,4 +1,4 @@
-<!-- $Revision: 1.5 $ -->
+<!-- $Revision: 1.6 $ -->
 <refentry id="package.DB_NestedSet">
  <refnamediv>
   <refname>Introduction</refname>
@@ -58,12 +58,12 @@
     saved to the database and displayed.
    </para>
    <programlisting role="php"><![CDATA[
-require_once('DB/NestedSet.php');
-require_once('DB/NestedSet/Output.php');
-require_once('HTML/Menu.php');
+require_once 'DB/NestedSet.php';
+require_once 'DB/NestedSet/Output.php';
+require_once 'HTML/Menu.php';
 $DatabasePointer = mysql_connect("localhost", "user", "pwd");
 mysql_select_db("database", $DatabasePointer);
-$dsn = 'mysql://database:pwd@localhost/user';
+$dsn = 'mysql://user:pwd@localhost/database';
 // needed colums in table:
 $params = array(
 	'id'        => 'id',
@@ -95,6 +95,7 @@
     'titleField' => 'name',
     'urlField' => 'url');
 $output =& DB_NestedSet_Output::factory($params, 'Menu');
+$structure = $output->returnStructure();
 $menu = & new HTML_Menu($structure, 'sitemap');
 $menu->forceCurrentUrl($currentUrl);
 $menu->show();
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.