`
kirenenko04
  • 浏览: 152277 次
  • 性别: Icon_minigender_2
  • 来自: 上海
社区版块
存档分类
最新评论
文章列表
if(!Mage::getSingleton("customer/session")->isLoggedIn()){ $session = Mage::getSingleton("customer/session");// Store The Current Page Url Where User will be redirected once loggedin $session->setBeforeAuthUrl(Mage::helper("core/url")->getCurrentUrl() ...
Once and a while you may want to get a collection of the regions that are associated with a country in Magento. For example, the United States is of course a collection of… states. In Magento these are referred to as regions (Japan’s prefectures would hence be referred to as regions as well.)   So ...
Frontend:   you can see these form html elems: They are country_id, country, province, and province_id elems   <div class="content-input"> <label>Region:</label> <select id="province_id" name="province_id" title="<? ...
I’m sure most fo you will agree that Magento’s frontend validation for form input fields is a nice feature. All it takes is for you to add some CSS classes to the input fields and then upon form submission validation is triggered that outputs, by default, red colored messages that point the possible ...

Mime Types

Suffixes applicable Media type and subtype(s) .3dm x-world/x-3dmf .3dmf x-world/x-3dmf .a application/octet-stream .aab application/x-authorware-bin .aam application/x-authorware-map .aas application/x-authorware-seg .abc text/vnd.abc .acgi text/html .afl video/a ...
Many time we required to get current controller or action name or module name. Its very easy job to get get route name, module name, controller and action name for magento from current URL, anywhere in controller or even with template files.   Mage::app()->getRequest()->getControllerName(); ...
Open /app/code/core/Mage/Adminhtml/Block/Sales/Order/Grid.php Create the file structure of : /app/code/local/Mage/Adminhtml/Block/Sales/Order/Grid.php Copy the contents of the Core file, and paste into the Local version. Find the protected function _prepareCollection.  You are going to modify th ...
$file = fopen($file_path, 'r'); stream_filter_append($file, "convert.iconv.gbk/utf-8");  
This is one of the easiest way to show Either Error message or Success message in magento for one time.If you are thinking to show an error message or success message one time when a page load then it is the best method to use in mganeto. Show Error Message in frontend $message = $this->__('Ema ...
1.A Realm is a Demandware instance used only by developers? Realm 是 Demandware 实例 只有开发人员使用的吗? F   2.Merchants use Business Manager to manage products and catalogs? 商人使用业务管理器来管理产品和目录?  T   3.You can import SiteGenesis through site import at any time without risk? 你可以用site import功能导入SiteGenes ...
需求: 在shopping cart页面 每一个Item 前增加checkobx控件, 让购买者可以选中需要购买的物品。 然后点击购买按钮执行购买流程。 再完成购买或者回到上一页按钮的时候恢复原本的item到购物车内。   解决思路:利用临时表存储未选中的item数据。 在完成结算或者取消结算的时候从临时表中恢复数据到正式表。   解剖一下相关表结构 magento 关于cart item的表有两个:`sales_flat_quote_item`,`sales_flat_quote_item_option` 这两个表前一个的主见是后一个的外键 item_id 。 为了 ...

Best Selling

  /*Get overall Bestselling products*/ public function getBestsellingProducts() { // number of products to display $productCount = 5; // store ID $storeId = Mage::app()->getStore()->getId(); // get most viewed products for current category ...
First look at Html code for header sidebar <li class="top-cart"> <div class="block-title"> <strong id="cartHeader"><a href="http://lifemore.svn-test.com/index.php/checkout/cart/">shopping bag (<span>1</span&g ...
We just need extends 'Mage_Adminhtml_Block_Catalog_Category_Tab_Attributes' and Rewrite function _prepareForm(); add These code into function : if ($this->getAddHiddenFields()) { $fieldset->addField('position', 'text', array( 'label'=>'Position', 'name' => 'position ...
$('#postcode').keydown(function (e) { if (e.keyCode == 13) { $('#find_button').click(); return false; } });  
Global site tag (gtag.js) - Google Analytics