- 浏览: 581894 次
- 性别:
- 来自: 上海
文章分类
- 全部博客 (332)
- PHP (92)
- JS/Css (38)
- Mysql (12)
- apache (7)
- magento (22)
- 杂淡 (1)
- snoopy (2)
- 安全 (1)
- YII (33)
- 网络编程 (3)
- HTML (4)
- editplus (1)
- phpcms (1)
- 软件 (1)
- kindeditor (2)
- android (35)
- java (1)
- Zend (21)
- Git (4)
- smarty (1)
- shell (0)
- svn (7)
- linux (1)
- 支付宝 (1)
- jquery (5)
- 微信 (3)
- thinkPHP (9)
- sqlyog (1)
- TCP/IP学习 (1)
- 服务器 (1)
- phpExcel (2)
- sql server (1)
- 我的工作 (0)
- 销售 (1)
- HTML5 (1)
- 接口开发 (0)
- memcache (2)
- jquery-weui (1)
- laravel (4)
最新评论
-
天使建站:
http://www.aijquery.cn/Html/bia ...
jquery searchableselect用法 -
天使建站:
http://www.aijquery.cn/Html/bia ...
jquery searchableselect用法 -
hudeyong926:
这技术太老了
PHP生成桌面快捷方式 -
hnlixf:
参考 http://www.jb51.net/article/ ...
ThinkPHP 3.3.2使用PHPExcel实现Excel数据导入导出完整实例 -
hudeyong926:
magento,清空购物车中所有的产品和session
There are different important functions that you can implement in your Collection object. The functions are present in Varien_Data_Collection_Db class. The class file is present in lib/Varien/Data/Collection/Db.php Here are some of the functions that you can use in your collection object:- /** * Get Zend_Db_Select instance */ $collection->getSelect(); /** * Get collection size */ $collection->getSelect()->getSize(); /** * Get sql select string or object */ $collection->getSelect()->getSelectSql(); /** * Add select order */ $collection->getSelect()->setOrder($field, $direction); /** * Add field filter to collection * * If $attribute is an array will add OR condition with following format: * array( * array('attribute'=>'firstname', 'like'=>'test%'), * array('attribute'=>'lastname', 'like'=>'test%'), * ) */ $collection->getSelect()->setOrder($field, $condition); /** * Set select distinct */ $collection->getSelect()->distinct($flag); /** * Get all data array for collection */ $collection->getSelect()->getData(); /** * Reset loaded for collection data array */ $collection->getSelect()->resetData(); /** * Print and/or log query */ $collection->getSelect()->printLogQuery(true, true); More functions below:- Varien_Data_Collection_Db class extends Varien_Data_Collection class. Here are some more functions present in Varien_Data_Collection class:- /** * Get current collection page */ $collection->getSelect()->getCurPage(); /** * Retrieve collection last page number */ $collection->getSelect()->getLastPageNumber(); /** * Retrieve collection page size */ $collection->getSelect()->getPageSize(); /** * Retrieve collection all items count */ $collection->getSelect()->getSize(); /** * Retrieve collection first item */ $collection->getSelect()->getFirstItem(); /** * Retrieve collection last item */ $collection->getSelect()->getLastItem(); /** * Retrieve collection items */ $collection->getSelect()->getItems(); /** * Clear collection */ $collection->getSelect()->clear(); You can also use the select functions as present in Zend_Db_Select class. This class file is present in lib/Zend/Db/Select.php Hope this helps. Thanks.
发表评论
-
magento,清空购物车中所有的产品和session
2013-01-23 14:03 2070在购物车中清除所有产品代码: foreach( Mage: ... -
magento布局文件formkey的作用
2013-01-17 16:02 3207magento表单提交时有个key,是如何引用进模板的: ... -
magento 添加 删除css js
2013-01-17 11:47 1301在addJs、addCss的代码一般在page/htm ... -
Magento中,调用静态块的几种方法
2013-01-11 15:46 3305在后台创建一个order_form静态块Block Ti ... -
Magento 后台配置中实现日期选择 (Date picker)
2013-01-10 17:33 982首先,创建一个新的Form Field 类: <?php ... -
Magento Admin Form 表单元素大全
2013-01-10 17:30 2953开发Magento后台的时候经 ... -
Magento getModel getSingleton等常用函数详解
2012-12-28 11:41 589http://blog.csdn.net/huashenghn ... -
magento截取字符串
2012-12-05 14:19 1076<?php echo $this->html ... -
magento 发邮件机制
2012-12-03 14:02 668http://koda.iteye.com/blog/6236 ... -
Magento获取Zend_Db_Select对象中的SQL语句
2012-11-28 15:59 870app/code/core/Mage/Catalog/M ... -
在Magento的注册流程中增加职业字段
2012-11-27 15:54 677http://blog.chinaunix.net/uid-4 ... -
Magento获取当前页面URL地址
2012-11-19 14:37 1318$currentUrl = $this->help ... -
Magento 通过xxAction改变模板
2012-11-13 13:37 628$this->loadLayout(); $th ... -
magento 资料总结(myjavawork)
2012-11-09 16:02 720http://www.cnblogs.com/myjavawo ... -
magento model sql
2012-11-07 18:06 651$sql = "CALL xxxxxx('{$ ... -
安装插件之后Magento后台404的解决办法
2012-10-26 18:46 1223导致该问题的原因是Magento预读了所有的后台Layo ... -
自定义Magento系统配置,后台配置
2012-10-26 13:46 7634Magento拥有十分强大的后台管理系统。作为一名开发人 ... -
magento 取URL常用方法
2012-10-19 15:13 4962To Retrieve URL path in STAT ... -
如何在magento模板文件中获取controller名称,action名称和module name
2012-10-19 13:47 2284/** * get Controller name ... -
Magento中为Block启用Cache方法
2012-09-02 00:54 1075在Block类的_construct(不是构造方法)方法 ...
相关推荐
MagentoBeginner's Guide.pdf [Packt]出品,最早的Magento精品书之一,原书地址:http://www.amazon.com/Magento-Beginners-Guide-William-Rice/dp/1847195946
NULL 博文链接:https://justcoding.iteye.com/blog/2100394
magento:magento-ce 2.4.0
通过SFTP或SSH导航到Magento [Magento]/app/code/ 。 上载带有扩展名的Dropday/OrderAutomation目录。 打开终端并导航到Magento根目录。 运行以下命令以启用Dropday扩展: php bin/magento module:enable Dropday_...
Magento:registered:2数据集成借助Datatric Connect扩展程序,可以轻松地将Magento:registered:2商店与Datatrics平台连接起来。安装在开始安装过程之前,我们建议您对webshop文件以及数据库进行备份。 有两种安装...
magento:Magento CE 1.x源代码
fresh-magento:新鲜的magento
docker-magento:Mark Shust的Magento Docker配置
magento:megento电子商务网站
ansible-magento要求: -流浪汉-可以指示: 克隆此仓库无所事事在浏览器中导航到magento.dev。MySQL 数据库:magento 用户名:magento 密码:password123 这是基于的工作而进行的一些更改,以简化启动和运行过程...
Apress.The.Definitive.Guide.to.Magento.Dec.2009.pdf Apress于2009重磅推出的Magento上手书籍,原书地址:http://www.apress.com/book/view/9781430272298
VueFrontCMS Connect App for Magento 显示你的 :red_heart: -给我们一个 :star: 帮助我们将这个项目发展到最好! VueFront是CMS不可知的SPA和PWA前端,适用于您的老式Blog和电子商务网站。 Magento通过最佳的电子...
马恩托 magento 项目
deployer-extended-magento:Magento的基于部署程序的部署,具有媒体和数据库同步
流浪者-magento:**已弃用**
$ cd /path/to/magento $ modgit init $ modgit add epicomtech_magento https://github.com/epicomtech/magento.git Antes deComeçar Epicom的API协议 通过电子邮件联系API,电子邮件地址: Conhecendo omó...
马真托Magento片段。
Gimmie Magento 插件 为 Magento 添加 Gimmie 奖励,让用户在购买和推荐朋友时获得积分并获得真正的奖励。 要安装此插件,我们提供。 建造 克隆此插件所需的所有子模块(gimmie php 项目) $git submodule init &&...
Tryton Magento集成 Magento电子商务平台与Tryton ERP的集成。 文献资料 可获取该项目的详细文档。 该文档是自动生成的,欢迎您对文档进行改进或翻译。 在开始任何事情之前,请创建一个问题,以避免重复工作。 ...
Magento Python API 用于连接到Magento Web服务的Python库。 用法 import magento url = 'http://domain.com/' apiuser = 'user' apipass = 'password' # Create an instance of API client = magento . API ( url ...