This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| function sign($method, $url, $data, $consumerSecret, $tokenSecret) | |
| { | |
| $url = urlEncodeAsZend($url); | |
| $data = urlEncodeAsZend(http_build_query($data, '', '&')); | |
| $data = implode('&', [$method, $url, $data]); | |
| $secret = implode('&', [$consumerSecret, $tokenSecret]); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Created by Rafael Corrêa Gomes | |
| // Reference http://devdocs.magento.com/guides/m1x/api/rest/introduction.html#RESTAPIIntroduction-RESTResources | |
| // Custom Resource | |
| $apiResources = "products?limit=2"; | |
| // Custom Values | |
| $isAdminUser = true; | |
| $adminUrl = "admin"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SET FOREIGN_KEY_CHECKS = 0; //important | |
| TRUNCATE TABLE `gift_message`; | |
| TRUNCATE TABLE `quote`; | |
| TRUNCATE TABLE `quote_address`; | |
| TRUNCATE TABLE `quote_address_item`; | |
| TRUNCATE TABLE `quote_id_mask`; | |
| TRUNCATE TABLE `quote_item`; | |
| TRUNCATE TABLE `quote_item_option`; | |
| TRUNCATE TABLE `quote_payment`; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| DELETE eav_attribute_option_value FROM eav_attribute_option,eav_attribute_option_value WHERE eav_attribute_option.attribute_id > 133 and eav_attribute_option.option_id = eav_attribute_option_value.option_id; | |
| DELETE FROM eav_attribute WHERE attribute_id > 133; | |
| DELETE FROM eav_attribute_label WHERE attribute_id > 133; | |
| DELETE FROM eav_attribute_option WHERE attribute_id > 133; | |
| DELETE FROM eav_attribute_group WHERE attribute_set_id > 25; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ssh : | |
| upload file : | |
| scp [source file] [username]@[destination server]:. | |
| import sql : | |
| ssh remote_user@remote_server mysql -p testpass -u username testdb < c:\folder\test.sql |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class commonuse | |
| { | |
| /* common class for multiple uses */ | |
| /* search_multidemsional @sagar : 20072016 */ | |
| /* | |
| $value="abc"; | |
| $array=array("car"=>array("modules"=>array("engine"=>array("power"=>"40hpwrs")))); |