32 |
* |
* |
33 |
* @author Walter A. Boring IV <waboring@buildabetterweb.com> |
* @author Walter A. Boring IV <waboring@buildabetterweb.com> |
34 |
* @package phpHtmlLib |
* @package phpHtmlLib |
35 |
|
* @tutorial Container.cls |
36 |
* |
* |
37 |
*/ |
*/ |
38 |
|
|
61 |
* The flags that tell us |
* The flags that tell us |
62 |
* how to render the tag |
* how to render the tag |
63 |
* its contents, and the close |
* its contents, and the close |
64 |
|
* @access private |
65 |
*/ |
*/ |
66 |
var $_flags = _NEWLINEAFTERCONTENT; |
var $_flags = _NEWLINEAFTERCONTENT; |
67 |
|
|
74 |
* added to the container. This |
* added to the container. This |
75 |
* works in the same manner as |
* works in the same manner as |
76 |
* the push() method. |
* the push() method. |
77 |
|
* |
78 |
|
* {@source } |
79 |
|
* |
80 |
|
* @tutorial Container.cls#constructor |
81 |
*/ |
*/ |
82 |
function Container() { |
function Container() { |
83 |
//We do the adding to the content var |
//We do the adding to the content var |
101 |
* It just walks through each of the |
* It just walks through each of the |
102 |
* class' data and renders it with the |
* class' data and renders it with the |
103 |
* appropriate indentation. |
* appropriate indentation. |
104 |
|
* |
105 |
|
* {@source } |
106 |
* |
* |
107 |
* @param int - the indentation level for |
* @param int - the indentation level for |
108 |
* the container. |
* the container. |
159 |
* Same as add(). |
* Same as add(). |
160 |
* NOTE: only exists for 1.1.x compatibility |
* NOTE: only exists for 1.1.x compatibility |
161 |
* |
* |
162 |
|
* {@source } |
163 |
|
* |
164 |
* @deprecated |
* @deprecated |
165 |
* @param mixed $content - either string, or tag object. |
* @param mixed $content - either string, or tag object. |
166 |
* @access public |
* @access public |
176 |
* adds content to tag as a FIFO. |
* adds content to tag as a FIFO. |
177 |
* You can have n number of parameters. |
* You can have n number of parameters. |
178 |
* each one will get added in succession to the content. |
* each one will get added in succession to the content. |
179 |
|
* |
180 |
|
* {@source } |
181 |
|
* |
182 |
|
* @tutorial Container.cls#add |
183 |
|
* |
184 |
* @param mixed $content - either string, or tag object. |
* @param mixed $content - either string, or tag object. |
185 |
* @access public |
* @access public |
186 |
*/ |
*/ |
200 |
* Same as add_reference |
* Same as add_reference |
201 |
* NOTE : only exists for compatibility with 1.1.x |
* NOTE : only exists for compatibility with 1.1.x |
202 |
* |
* |
203 |
|
* {@source } |
204 |
* @deprecated |
* @deprecated |
205 |
* |
* |
206 |
* @access public |
* @access public |
235 |
|
|
236 |
/** |
/** |
237 |
* destroy existing content and start with new content. |
* destroy existing content and start with new content. |
238 |
|
* |
239 |
|
* {@source } |
240 |
* |
* |
241 |
* @access public |
* @access public |
242 |
* @param mixed $content can be tag object, or raw (string). |
* @param mixed $content can be tag object, or raw (string). |
251 |
/** |
/** |
252 |
* counts the number of content objects |
* counts the number of content objects |
253 |
* |
* |
254 |
|
* {@source } |
255 |
* @access public |
* @access public |
256 |
* @return int |
* @return int |
257 |
*/ |
*/ |
259 |
return $this->_data_count; |
return $this->_data_count; |
260 |
} |
} |
261 |
|
|
262 |
|
|
263 |
|
/** |
264 |
|
* get the nth element from content array |
265 |
|
* |
266 |
|
* {@source } |
267 |
|
* |
268 |
|
* @param int $cell the cell to get |
269 |
|
* @return mixed |
270 |
|
*/ |
271 |
|
function &get_element( $cell ) { |
272 |
|
return $this->_content[$cell]; |
273 |
|
} |
274 |
|
|
275 |
|
|
276 |
/** |
/** |
277 |
* This method is used to set the bitmask |
* This method is used to set the bitmask |
280 |
* |
* |
281 |
* NOTE: the child class can override this |
* NOTE: the child class can override this |
282 |
* to set the options |
* to set the options |
283 |
|
* |
284 |
|
* {@source } |
285 |
|
* @access private |
286 |
|
* |
287 |
*/ |
*/ |
288 |
function _set_flags() { |
function _set_flags() { |
289 |
$this->_flags = _NEWLINEAFTERCONTENT | _INDENT; |
$this->_flags = _NEWLINEAFTERCONTENT | _INDENT; |
292 |
|
|
293 |
/** |
/** |
294 |
* function to set the indent flag |
* function to set the indent flag |
295 |
|
* |
296 |
|
* {@source } |
297 |
* |
* |
298 |
* @access public |
* @access public |
299 |
* @param boolean $flag TRUE or FALSE |
* @param boolean $flag TRUE or FALSE |
311 |
* This flag gets the current value |
* This flag gets the current value |
312 |
* of the indent flag |
* of the indent flag |
313 |
* |
* |
314 |
* @access public |
* {@source } |
315 |
* |
* |
316 |
* @return boolean |
* @return boolean |
317 |
*/ |
*/ |
323 |
/** |
/** |
324 |
* This function turns on the collapse flag |
* This function turns on the collapse flag |
325 |
* |
* |
326 |
* @access public |
* {@source } |
327 |
|
* |
328 |
|
* @tutorial Container.cls#collapse |
329 |
* |
* |
330 |
* @param boolean - the collapse flag |
* @param boolean - the collapse flag |
331 |
* @param boolean - the indent flag |
* @param boolean - the indent flag |
349 |
/** |
/** |
350 |
* returns leading indent for tag |
* returns leading indent for tag |
351 |
* |
* |
352 |
|
* {@source } |
353 |
* @access private |
* @access private |
354 |
* |
* |
355 |
* @param int the indentation level for this tag. |
* @param int the indentation level for this tag. |