Chuyển đến nội dung chính

Bài đăng

Đang hiển thị bài đăng từ 2015

Fix XML Validate of PhpStorm in magento 2

PhpStorm 9 with magento 2 dev-1.0.0beta Follow this steps Step1 Step2 Step3 Step4 Step5 Step6 Thanks for visit , share this post if you like

GetUrl in Magento 2

review file \Magento\Store\Model\Store.php public function getBaseUrl($type = \Magento\Framework\UrlInterface::URL_TYPE_LINK, $secure = null) { $cacheKey = $type . '/' . ($secure === null ? 'null' : ($secure ? 'true' : 'false')); if (!isset($this->_baseUrlCache[$cacheKey])) { $secure = $secure === null ? $this->isCurrentlySecure() : (bool)$secure; switch ($type) { case \Magento\Framework\UrlInterface::URL_TYPE_WEB: $path = $secure ? self::XML_PATH_SECURE_BASE_URL : self::XML_PATH_UNSECURE_BASE_URL; $url = $this->getConfig($path); break; case \Magento\Framework\UrlInterface::URL_TYPE_LINK: $path = $secure ? self::XML_PATH_SECURE_BASE_LINK_URL : self::XML_PATH_UNSECURE_BASE_LINK_URL; $url = $this->getConfig($path); ...

Magento 2.0 CLI commands

cache  cache:clean  cache:disable  cache:flush  cache:enable  indexer:reindex dev:css:deploy  Compile css to less sampledata:install adminusername Install sample luma theme setup:uninstall re-install magento , clean sampledata , clean db Command should begin with php bin/magento

Dev Tips #Rewrite Prevent duplicate request AJAX when rewrite in Magento

RewriteRule . /index.php [L] # skip POST requests RewriteCond %{REQUEST_METHOD} POST RewriteRule ^ - [L] # browser requests PHP RewriteCond %{THE_REQUEST} ^[A-Z]{3,9}\ /([^\ ]+)\.php RewriteRule ^/?(.*)\.php$ /$1 [L,R=301] # check to see if the request is for a PHP file: RewriteCond %{REQUEST_FILENAME}\.php -f RewriteRule ^/?(.*)$ /$1.php [L] RewriteRule ^index.php/admin/(.*)$ /admin/$1 [L,R] Rewrite xóa index.php trên url bằng htaccess

Implement Sticky menu in magento 1.9

HTML CODE: getChildHtml('global_messages') ?> getChildHtml('content') ?> getChildHtml('left') ?> getChildHtml('description_cate')?> JS CODE: CSS CODE: .clearer {clear:both;} .main-inner:before, .main-inner:after {content:"";display:table;display:block;width:100%} .main-inner:after {clear:both} .main-inner {height:100%;position:relative;width:100%;display:block;margin-bottom:10px;} .is_stuck{position:fixed;}