/[cvs]/nfo/php/libs/com.newsblob.phphtmllib/doc/phpHtmlLib/tutorial_Container.cls.html
ViewVC logotype

Annotation of /nfo/php/libs/com.newsblob.phphtmllib/doc/phpHtmlLib/tutorial_Container.cls.html

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (hide annotations)
Thu May 6 16:57:01 2004 UTC (20 years, 3 months ago) by jonen
Branch: MAIN
CVS Tags: HEAD
File MIME type: text/html
 updated all to v2.4.1 - Apr 01, 2004

1 jonen 1.1 <?xml version="1.0" encoding="iso-8859-1"?>
2     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3     <html xmlns="http://www.w3.org/1999/xhtml">
4     <head>
5     <!-- template designed by Marco Von Ballmoos -->
6     <title>Container</title>
7     <link rel="stylesheet" href="../media/stylesheet.css" />
8     <meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
9     </head>
10     <body>
11     <div class="page-body">
12     <table class="tutorial-nav-box">
13     <tr>
14     <td style="width: 30%">
15     <span class="nav-button-disabled">Previous</span>
16     </td>
17     <td style="text-align: center">
18     </td>
19     <td style="text-align: right; width: 30%">
20     <a href="../phpHtmlLib/tutorial_XMLTagClass.cls.html" class="nav-button">Next</a>
21     </td>
22     </tr>
23     <tr>
24     <td style="width: 30%">
25     </td>
26     <td style="text-align: center">
27     </td>
28     <td style="text-align: right; width: 30%">
29     <span class="detail">XMLTagClass</span>
30     </td>
31     </tr>
32     </table>
33    
34     <div><a name=""></a><div class="ref-title-box"><h1 class="ref-title">Container</h1>
35     <h2 class="ref-purpose">This is the base class for all of phpHtmlLib</h2></div>
36     <div class="ref-synopsis"><span class="author">by Walter A. Boring IV
37     <div class="author-blurb"><a href="mailto:waboring@3gstech.com">mailto:waboring@3gstech.com</a></div></span>
38     <div class="notes">March 2004, Walter A. Boring IV</div>
39     <div class="release-info">(phpHtmlLib 2.4.x)</div></div>
40     <span><a name="description"></a><h2 class="title">Description</h2><p>This class is nothing more then a container widget. It lets you
41     push data into it, and it will render each item indented properly so it works with the rest of the libs.</p>
42     <p>This is helpfull when you have a function that wants to return multiple Tag Objects
43     or widgets. Just wrap them in this container
44     and they will all get rendered with the current indentation level.</p></span>
45     <span><a name="example"></a><h2 class="title">Example</h2><p><pre class="example"><pre>
46     $c = container('this is a', html_b('test') );
47     $c-&gt;add( html_br() );
48     print $c-&gt;render();</pre></pre></p></span>
49    
50     <span><a name="constructor"></a><h2 class="title">Constructor call</h2><p><p>This lets you pass in data that you want automatically
51     added to the container. You can add as man items in the
52     call the constructor. Then you can use the add() method
53     to add more items later.</p>
54     <pre class="example"><pre>$c = container('this is a', html_b('test'));</pre></pre></p></span>
55     <span><a name="add"></a><h2 class="title">add Method</h2><p><p>This lets you add new data to the container. You can pass in
56     strings, integers and other Container child objects that implement the
57     render() method.</p>
58     <pre class="example"><pre>$c = container();
59     $c-&gt;add('testing', 1, 2, 3);</pre></pre>
60     <p>The output:
61     <pre class="example"><pre>testing
62     1
63     2
64     3</pre></pre></p></p></span>
65    
66     <span><a name="collapse"></a><h2 class="title">Collapse</h2><p><p>This method is used to force the output to exist on 1 line, instead
67     of a newline for every element added.</p>
68     <pre class="example"><pre>$c = container();
69     $c-&gt;set_collapse();
70     $c-&gt;add('testing', 1, 2, 3);</pre></pre>
71     <p>The output:
72     <pre class="example"><pre>testing123</pre></pre></p></p></span></div>
73    
74     <table class="tutorial-nav-box">
75     <tr>
76     <td style="width: 30%">
77     <span class="nav-button-disabled">Previous</span>
78     </td>
79     <td style="text-align: center">
80     </td>
81     <td style="text-align: right; width: 30%">
82     <a href="../phpHtmlLib/tutorial_XMLTagClass.cls.html" class="nav-button">Next</a>
83     </td>
84     </tr>
85     <tr>
86     <td style="width: 30%">
87     </td>
88     <td style="text-align: center">
89     </td>
90     <td style="text-align: right; width: 30%">
91     <span class="detail">XMLTagClass</span>
92     </td>
93     </tr>
94     </table>
95    
96     <p class="notes" id="credit">
97     Documentation generated on Thu, 1 Apr 2004 09:37:05 -0800 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.0RC2</a>
98     </p>
99     </div></body>
100     </html>

MailToCvsAdmin">MailToCvsAdmin
ViewVC Help
Powered by ViewVC 1.1.26 RSS 2.0 feed