Zend Framework: view and table

defined is a special operator that takes the form of a method callto determin whether or

not the passed expression is defined. it returns a descriptionstring of the expression, or

nil if the expression is not defined. the :: is a unary operatorthat allows:constants,instance

methods and class methods defined within a class or module ,to beaccessed from

anywhere outside the class or module.

zend_view is a class for working with the view portion of themodel-view-controll

pattern.Essentially, using zend_view happens in two major steps: 1.your controller

creates an instance of zend_view and assaign variables to thatinstance.2.the controller

tells the zend_view to render a particular view, thereby handingcontrol over the view

script,which generates the view output.

zend_view has several options that may be set to configure thebehaviour of your view

scripts:
#basePath: indicate a base path from which to set the script,helperand filter path;
#encoding: indicate the character encoding to use withhtmlentities, htmlspecialchars()

and other operations.
#escape: indicate a callback to be used by escape;
#filter: include a filter to use after rendering a viewscript.

Typically, you will only ever need to call on assign(), render(),or one of the methods for

setting/adding filter,helper,and script paths.

Once your controller has assigned variables and called render(),zend_view then includes

the requested view script and executes it inside the scope of thezend_view

instance.Therefore, in your view scripts, reference to $thisactually point to the zend_view

instance itself.

zend_config is designed to simplify the access to, and the use ofconfiguration data within

application. It provides a nested object property based userinterface for accessing this

configuration data within application code.The configuration datamay come from a variety

of media supporting hierarchical data storage.Currently zend_configprovides adapter for

configuration data that are stored in text files withzend_config_ini and zend_config_xml.

The zend_db_select object represents a sql select query statement.The class has

methods for adding individual parts to the query.You can specifysome parts of the query

using php methods and data structures, and the class forms thecorrect sql syntax for

you.After you build a query, you can execute the query as if youhad written it as string.

The value offered by zend_db_select includes:
*object-oriented methods for specifying sql queries in apiece-by-piece manner;
*quoting identifiers and values, to help reduce risk of sql injectattacks.




  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值