40

If you really wanted to you could also clean just one or more cache types. This is actually how the admin section does it. Under Mage_Adminhtml_CacheController::massRefreshAction You can see that it loops through all the parameters types and calls the following $tags = Mage::app()->getCacheInstance()->cleanType($type); Mage::dispatchEvent('...


25

Please try the following code to flush the cache programatically Mage::app()->cleanCache() or Mage::app()->getCacheInstance()->flush();


8

Add the AUTH variable into the Pipelines Variable settings. Using Bitbucket, you can use this file below called bitbucket-pipelines.yml image: rafaelcgstz/magento2 pipelines: branches: master: - step: name: Composer install caches: - composer artifacts: ...


6

A quick external script to clear all cache: <?php require_once './app/Mage.php'; umask(0); Mage::app('default'); Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID); try { $allTypes = Mage::app()->useCache(); foreach($allTypes as $type => $value) { Mage::app()->getCacheInstance()->cleanType($type); ...


3

Unfortunately, The Magento Test Automation Framework was built for Magento 1.5-1.7. The Magento Testing Framework is for Magento 2.x. That means that there is a funny little section of the Magento 1.x world that cannot properly leverage a full testing framework. These are the areas of unit and functional testing. There are others out there, but these ...


3

Our we could use n98-magerun. Especially since you should never flush the cache during execution of deployment scripts. Also look at the sys:setup:incremental subcommand for more controlled execution of the Magento setup scripts.


3

Interesting question. I will try and provide an unbiased answer on all of the CI tools that I have experience with: Jenkins - Provides the ability to self host the CI server and configure the build to any needs you may have. When I used Jenkins it was using the standard PHP template set to ignore the obvious paths, Core etc. It can run Selenium and I had ...


2

saveAction(): won't catch products added outside of an actual admin creating the product. _afterSave(): called any time the product is saved. Just be wary of that. The above information are foundational to deciding which is better for you (and your client's) purposes.


2

<?php $mageFilename = 'app/Mage.php'; require_once $mageFilename; Varien_Profiler::enable(); Mage::setIsDeveloperMode(true); ini_set('display_errors', 1); umask(0); Mage::app('default'); Mage::register('isSecureArea', 1); function generateUniqueId($length = null){ $rndId = crypt(uniqid(rand(),1)); $rndId = strip_tags(stripslashes($rndId)); $rndId =...


2

Im not aware of any custom extension that will provide this functionality. I may be wrong as I have not googled to see what is available. However depending on your level of ability in code the process is not that complicated. If all you want to do is mark pages from draft to live then a simple cron job will do the trick: Process being: * Load all cms ...


2

The short version of the answer to your first questions is, sadly, no. There is no publicly available suite of pre-developed functional tests for Magento EE 1.14 that you can use right now. The comments on this answer clarify it a bit. That being said, there are some resources you can leverage for creating functional tests for your Magento version. The ...


2

In Your Module try this in Vendor/HelloWorld/Model/ProductReviews.php <?php namespace Vendor\HelloWorld\Model; use Magento\Framework\Model\AbstractModel; class ProductReviews extends AbstractModel{ protected $_ratingFactory; protected $_productFactory; protected $_ratingFactory; protected $_reviewFactory; public function ...


1

Create a custom page using routes.xml app/code/Vendor/Module/etc/frontend/routes.xml <?xml version="1.0" ?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:App/etc/routes.xsd"> <router id="standard"> <route frontName="custom" id="custom"> &...


1

As usual, immediately after asking the question, i figure out the answer. I need to add a file ~/.composer/auth.json with the following: { "http-basic": { "repo.magento.com": { "username":"<your public key>", "password":"<your private key>" } } } Then I need to ensure that i create the folder, ...


1

create an auth.json file inside your Magento installation directory and put this inside: { "http-basic": { "repo.magento.com": { "username": "<public-key>", "password": "<private-key>" } } }


1

I assume you modify the code based on that module, place the following codes after line 18 $new_sku = ""; in app/code/local/Learn/Autosku/Model/Observer.php: $manufacturer_name = $product->getAttributeText('manufacturer'); if ($manufacturer_name.length > 0) $new_sku .= substr($manufacturer_name, 0, 4); P.S: Depends on your requirement, if you don'...


1

There are multiple ways to do this. You could add the text in the phtml file and maybe add some variables here and there. That way, all products have an identical description. You could also do a check here: If a product has a value for the description, you could show that description. If not, show the default description. In that case you'll make the ...


1

In Magento admin panel Catalog->Categories -> Manage Categories-> Select a category. There will be option to provide the page title, meta keyword and description for each and every category


1

Easiest way to do this is with a cronjob. You'll need to write your own module and define a cron in there config.xml <config> <modules> <[Namespace]_[Module]> <version>1.0.0</version> </[Namespace]_[Module]> </modules> <global> <models> <[...


1

Short answer: Use Store Views, giving alternate names to each attribute options per store view (allows inheritance when values are blank) If you want to manage eBay and Amazon with Magento I've found it invaluable to configure multiple Store Views (eg. English, eBay En, Amaozn En). This way when you add attribute options you can then leave the other store ...


1

It sounds like your against the technology of S3 which leaves you very limited options for auto scaling. You could look into setting up a hard ware raid with hot plugable devices and then mount yor media folder into this raid setup. Doing so you can in principle add unlimited hard drives (only limited by the physical number of bays) and it will ...


1

At the agency I work for we have a collection of Selenium tests that we use for mosts webshops. Generally if you stick to, for example, the RWD template for all shops you will have the same selectors. So, if you use the same template as basis for all shops you should be fine


1

I have to work this way daily to keep various servers in sync. The trick is to make a module with upgrade scripts. Let's pretend you have this module: app/code/local/Jeff/Content/etc/config.xml <config> <modules> <Jeff_Content> <!-- keep this number in mind --> <version>1.0.0</version&...


1

You will need to understand this article about importing products programatically and then make it work with a CSV and a cronjob. Without medium/high knowledge of the platform this will cost you some time, so as an advice from a business/time perspective, hire someone who can do this (this is not the correct place for hiring people).


1

If you want to change a configuration from the admin while running a cronjob you will have to code it yourself. You can use Magento cronjob or create your own in your server with crontab -e in most of the *nix distributions. Here is a guide from Inchoo to achieve that. From there: $inchooSwitch = new Mage_Core_Model_Config(); /* *turns notice on */ $...


1

If you Really need to clear all cache storages means use the following code, Mage::app()->getCacheInstance()->flush(); Here Flush function calls the default magento cache functionality, If you need more clarifications means refer the following url. https://stackoverflow.com/questions/15028159/magento-flush-cache-storage


Only top voted, non community-wiki answers of a minimum length are eligible