Skip to content

Instantly share code, notes, and snippets.

@reidblomquist
reidblomquist / gist:b02ffcef8449f87ff5dc
Created June 10, 2014 19:25
Magento user agent regex XML from magento/app/code/core/Mage/Core/etc/system.xml
<ua_regexp translate="comment">
<label></label>
<frontend_model>adminhtml/system_config_form_field_regexceptions</frontend_model>
<backend_model>adminhtml/system_config_backend_design_exception</backend_model>
<sort_order>2</sort_order>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
<comment>Match expressions in the same order as displayed in the configuration.</comment>
</ua_regexp>
@reidblomquist
reidblomquist / gist:aa9df1581a7ee8c82910
Last active August 19, 2021 14:41
Force cancel orders in Magento
The following SQL queries should set an orders status to canceled:
UPDATE sales_flat_order SET state = 'canceled', status = 'canceled' WHERE increment_id IN (order#1,order#2,etc);
UPDATE sales_flat_order_grid SET status = 'canceled' WHERE increment_id IN (order#1,order#2,etc);
<cache>
<slow_backend>database</slow_backend>
<fast_backend>memcached</fast_backend>
<fast_backend_options>
<servers>
<server>
<host>unix:///tmp/memcached.sock</host>
<port>0</port>