<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                <table cellspacing="0" cellpadding="0" border="0" width="100%" summary="Header navigation table"><tbody><tr><th align="center" colspan="3">Smarty - the compiling PHPtemplate engine</th> </tr><tr><td valign="bottom" align="left" width="25%"><a accesskey="P" href="api.config.load.html">Prev</a></td> <td valign="bottom" align="center" width="50%">Chapter 13. Smarty Class Methods()</td> <td valign="bottom" align="right" width="25%"><a accesskey="N" href="api.createtemplate.html">Next</a></td> </tr></tbody></table> # createData()[建立數據對象] Name createData() ― creates a data object 創建一個數據對象 Description string createData(object parent); string createData(); This creates a data object which will hold assigned variables. It uses the following parameters: parent is an optional parameter. It is an uplink to the main Smarty object, a another user-created data object or to user-created template object. These objects can be chained. Templates can access variables assigned to any of the objects in it's parent chain. Data objects are used to create scopes for assigned variables. They can be used to have controll which variables are seen by which templates. 本函數創建一個數據對象,并將該對象賦值給變量。參數介紹如下: “parent”是個可選參數。它負責上行鏈接主Smarty對象、另一個用戶自建數據對象或用戶自建模板對象。這些對象支持鏈式,模板可以訪問賦值給其父鏈對象的變量。 數據對象為賦值變量創建作用域。它們可以用于控制哪些模板可以訪問哪些變量。 <table class="EXAMPLE" cellspacing="0" cellpadding="0" border="0" width="100%"><tbody><tr><td> <div class="EXAMPLE"><strong><a name="AEN31314" id="AEN31314"/>Example 13.14. createData()</strong><b><br/></b><table width="100%" bgcolor="#e0e0e0" border="0"><tbody><tr><td> <pre class="PROGRAMLISTING">&lt;?phpinclude('Smarty.class.php');$smarty = new Smarty;// create data object with its private variable scope 創建一個私有變量作用域的數據對象$data = $smarty-&gt;createData();// assign variable to data scope 賦值變量擁有$data的作用域$data-&gt;assign('foo','bar');// create template object which will use variables from data object 使用來自數據對象的變量創建模版對象$tpl = $smarty-&gt;createTemplate('index.tpl',$data);// display the template 顯示模板$tpl-&gt;display();?&gt;</pre></td> </tr></tbody></table><p> 參見<a href="api.display.html">display()</a>和<a href="api.createtemplate.html">createTemplate()</a>。</p> </div> </td> </tr></tbody></table> <table cellspacing="0" cellpadding="0" border="0" width="100%" summary="Footer navigation table"><tbody><tr><td valign="top" align="left" width="33%"><a accesskey="P" href="api.config.load.html">Prev</a></td> <td valign="top" align="center" width="34%"><a accesskey="H" href="index.html">Home</a></td> <td valign="top" align="right" width="33%"><a accesskey="N" href="api.createtemplate.html">Next</a></td> </tr><tr><td valign="top" align="left" width="33%">configLoad()<br/> 加載配置</td> <td valign="top" align="center" width="34%"><a accesskey="U" href="api.functions.html">Up</a></td> <td valign="top" align="right" width="33%">createTemplate()<br/> 建立模板</td> </tr></tbody></table>
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看