Find attribute_id
SELECT * FROM eav_attribute where attribute_code = 'is_anchor'
Update all of them with anchor_id from above (usually is ID 51)
UPDATE `catalog_category_entity_int` set value = 1 where attribute_id = 51
#!/bin/sh | |
# Cleanup docker files: untagged containers and images. | |
# | |
# Use `docker-cleanup -n` for a dry run to see what would be deleted. | |
untagged_containers() { | |
# Print containers using untagged images: $1 is used with awk's print: 0=line, 1=column 1. | |
# NOTE: "[0-9a-f]{12}" does not work with GNU Awk 3.1.7 (RHEL6). | |
# Ref: https://github.com/blueyed/dotfiles/commit/a14f0b4b#commitcomment-6736470 | |
docker ps -a | tail -n +2 | awk '$2 ~ "^[0-9a-f]+$" {print $'$1'}' |
# Ask for the user password | |
# Script only works if sudo caches the password for a few minutes | |
sudo true | |
# Install kernel extra's to enable docker aufs support | |
sudo apt-get -y install linux-image-extra-$(uname -r) | |
# Add Docker PPA and install latest version | |
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 36A1D7869245C8950F966E92D8576A8BA88D21E9 | |
sudo sh -c "echo deb https://get.docker.io/ubuntu docker main > /etc/apt/sources.list.d/docker.list" |
<disable_local_modules>true</disable_local_modules> |
<?php | |
chdir(dirname(__FILE__)); | |
require_once '../app/Mage.php'; | |
Mage::app(); | |
umask(0); | |
require_once 'countries.php'; // import lists with all countries | |
// UK Island shipping rates; http://www.crearegroup-ecommerce.co.uk/blog/magento-advice/shipping-rates-to-the-uk-islands.php |
Source: https://magento.stackexchange.com/questions/95/debugging-layout-xml-loading | |
You can log the compiled layout XML directives which are used to generate blocks. Create an observer on controller_action_layout_generate_blocks_before, and in the observer method log the update XML from the transported layout object: | |
public function logCompiledLayout($o) | |
{ | |
$req = Mage::app()->getRequest(); | |
$info = sprintf( | |
"\nRequest: %s\nFull Action Name: %s_%s_%s\nHandles:\n\t%s\nUpdate XML:\n%s", | |
$req->getRouteName(), |
insert into core_config_data (`scope`, scope_id, `path`, `value`) values('default', 0, 'dev/log/active', '1') on duplicate key update `value`='1'; | |
insert into core_config_data (`scope`, scope_id, `path`, `value`) values('default', 0, 'admin/security/session_cookie_lifetime', '360000') on duplicate key update `value`='360000'; | |
insert into core_config_data (`scope`, scope_id, `path`, `value`) values('default', 0, 'web/cookie/cookie_lifetime', '360000') on duplicate key update `value`='360000'; | |
insert into core_config_data (`scope`, scope_id, `path`, `value`) values('default', 0, 'admin/security/password_is_forced', '0') on duplicate key update `value`='0'; | |
insert into core_config_data (`scope`, scope_id, `path`, `value`) values('default', 0, 'admin/security/password_is_forced', '0') on duplicate key update `value`='0'; | |
update core_config_data set value = 'http://project.192.168.50.100.xip.io/' where path like '%base_url'; | |
update core_config_data set value = '' |
curl -s --insecure https://api-3t.sandbox.paypal.com/nvp -d | |
"USER={YourUserID} | |
&PWD={YourPassword} | |
&SIGNATURE={YourSignature} | |
&METHOD=SetExpressCheckout | |
&VERSION=98 | |
&PAYMENTREQUEST_0_AMT=10 | |
&PAYMENTREQUEST_0_CURRENCYCODE=USD | |
&PAYMENTREQUEST_0_PAYMENTACTION=SALE | |
&cancelUrl=http://www.example.com/cancel.html |
Follow each step manually and any bugs during (resource) model instantiation will become obvious.
Since many people find model and resource model instantiation to be one of the more challenging things in Magento 1, these are all the steps Magento does to resolve the factory name to the real PHP class name.
To debug, simply follow each step manually until you find a non-match. This works really well in my experience.
Less guessing, more and faster results.
In the examples I use a factory name of "example/thing".
php -i | grep extension_dir |