mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 08:58:56 +00:00
Modified example
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@171541 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
dae628fa5d
commit
3b6e247f35
1 changed files with 2 additions and 3 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
<!-- $Revision: 1.3 $ -->
|
||||
<!-- $Revision: 1.4 $ -->
|
||||
<sect1 id="language.oop5.autoload">
|
||||
<title>Autoloading Objects</title>
|
||||
<para>
|
||||
|
@ -27,13 +27,12 @@
|
|||
<![CDATA[
|
||||
<?php
|
||||
function __autoload($class_name) {
|
||||
include_once($class_name . '.php');
|
||||
require_once $class_name . '.php';
|
||||
}
|
||||
|
||||
$obj = new MyClass1();
|
||||
$obj2 = new MyClass2();
|
||||
?>
|
||||
|
||||
]]>
|
||||
</programlisting>
|
||||
</example>
|
||||
|
|
Loading…
Reference in a new issue