| 
									
										
										
										
											2004-04-13 08:46:28 +00:00
										 |  |  | <?xml version="1.0" encoding="iso-8859-1"?> | 
					
						
							|  |  |  | <!-- $Revision$ --> | 
					
						
							| 
									
										
										
										
											2004-04-18 17:34:12 +00:00
										 |  |  | <sect1 id="language.syntax.attributes"> | 
					
						
							|  |  |  |  <title>Attributes</title> | 
					
						
							|  |  |  |  <para> | 
					
						
							|  |  |  |   Most of the functions take attributes that specify or modify | 
					
						
							|  |  |  |   their behavior. Attributes to Smarty functions are much like HTML | 
					
						
							|  |  |  |   attributes. Static values don't have to be enclosed in quotes, but it | 
					
						
							|  |  |  |   is recommended for literal strings. Variables may also be used, and | 
					
						
							|  |  |  |   should not be in quotes. | 
					
						
							|  |  |  |  </para> | 
					
						
							|  |  |  |  <para> | 
					
						
							|  |  |  |   Some attributes require boolean values (true or false). These can be | 
					
						
							|  |  |  |   specified as either unquoted <literal>true</literal>, | 
					
						
							|  |  |  |   <literal>on</literal>, and <literal>yes</literal>, or | 
					
						
							|  |  |  |   <literal>false</literal>, <literal>off</literal>, and | 
					
						
							|  |  |  |   <literal>no</literal>. | 
					
						
							|  |  |  |  </para> | 
					
						
							|  |  |  |  <example> | 
					
						
							|  |  |  |   <title>function attribute syntax</title> | 
					
						
							|  |  |  |   <programlisting> | 
					
						
							| 
									
										
										
										
											2004-04-13 08:46:28 +00:00
										 |  |  | <![CDATA[ | 
					
						
							|  |  |  | {include file="header.tpl"} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | {include file=$includeFile} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | {include file=#includeFile#} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | {html_select_date display_days=yes} | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | <select name="company"> | 
					
						
							|  |  |  | {html_options values=$vals selected=$selected output=$output} | 
					
						
							|  |  |  | </select> | 
					
						
							|  |  |  | ]]> | 
					
						
							| 
									
										
										
										
											2004-04-18 17:34:12 +00:00
										 |  |  |   </programlisting> | 
					
						
							|  |  |  |  </example> | 
					
						
							| 
									
										
										
										
											2004-04-13 08:46:28 +00:00
										 |  |  | </sect1> | 
					
						
							|  |  |  | <!-- Keep this comment at the end of the file
 | 
					
						
							|  |  |  | Local variables: | 
					
						
							|  |  |  | mode: sgml | 
					
						
							|  |  |  | sgml-omittag:t | 
					
						
							|  |  |  | sgml-shorttag:t | 
					
						
							|  |  |  | sgml-minimize-attributes:nil | 
					
						
							|  |  |  | sgml-always-quote-attributes:t | 
					
						
							|  |  |  | sgml-indent-step:1 | 
					
						
							|  |  |  | sgml-indent-data:t | 
					
						
							|  |  |  | indent-tabs-mode:nil | 
					
						
							|  |  |  | sgml-parent-document:nil | 
					
						
							|  |  |  | sgml-default-dtd-file:"../../../../manual.ced" | 
					
						
							|  |  |  | sgml-exposed-tags:nil | 
					
						
							|  |  |  | sgml-local-catalogs:nil | 
					
						
							|  |  |  | sgml-local-ecat-files:nil | 
					
						
							|  |  |  | End: | 
					
						
							|  |  |  | vim600: syn=xml fen fdm=syntax fdl=2 si | 
					
						
							|  |  |  | vim: et tw=78 syn=sgml | 
					
						
							|  |  |  | vi: ts=1 sw=1 | 
					
						
							| 
									
										
										
										
											2004-04-18 17:34:12 +00:00
										 |  |  | --> |