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
| public function attributeValueExists($arg_attribute, $arg_value) | |
| { | |
| $attribute_model = Mage::getModel('eav/entity_attribute'); | |
| $attribute_options_model= Mage::getModel('eav/entity_attribute_source_table') ; | |
| $attribute_code = $attribute_model->getIdByCode('catalog_product', $arg_attribute); | |
| $attribute = $attribute_model->load($attribute_code); | |
| $attribute_table = $attribute_options_model->setAttribute($attribute); | |
| $options = $attribute_options_model->getAllOptions(false); |
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
| $productCollection = Mage::getModel('catalog/product')->getCollection(); | |
| foreach($productCollection as $_product) | |
| { | |
| echo "\n".'updating '.$_product->getSku()."...\n"; | |
| $product = Mage::getModel('catalog/product')->load($_product->getEntityId()); | |
| $product->setData('add_ten_pence', 1)->getResource()->saveAttribute($product, 'add_ten_pence'); | |
| } |
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
| /* | |
| * base64.js: An extremely simple implementation of base64 encoding / decoding using node.js Buffers | |
| * | |
| * (C) 2010, Nodejitsu Inc. | |
| * | |
| */ | |
| var base64 = exports; | |
| base64.encode = function (unencoded) { |
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
| var S = require('string'); | |
| var fs = require('fs'); | |
| var filendir = require('filendir') | |
| module.exports = function(grunt) { | |
| var coreWEBPath = "../../CoreWEB/", | |
| wwwPath = "Hertz/www", | |
| androidPhoneAssets = "Hertz/www/androidphone", | |
| contentSourceRoot = "https://172.25.23.8"; // prk-agavecell cell 3 machine |
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
| var S = require('string'); | |
| var fs = require('fs'); | |
| var filendir = require('filendir') | |
| module.exports = function(grunt) { | |
| var coreWEBPath = "../../CoreWEB/", | |
| wwwPath = "Hertz/www", | |
| androidPhoneAssets = "Hertz/www/androidphone", | |
| contentSourceRoot = "https://edyhertz.ngrok.com"; // prk-agavecell cell 3 machine |
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
| //luklukaha@gmail.com | |
| //where.iam() >> get file path and line number where .iam() called | |
| var where=new function(){ | |
| this.getErrorObject=function (){ | |
| try { throw Error('') } catch(err) { return err; } | |
| } | |
| this.iam=function(){ | |
| var err = this.getErrorObject(); | |
| var caller_line = err.stack.split("\n")[4]; |
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 | |
| session_start(); | |
| setcookie("payment_method","",time()-1); | |
| include_once "include/seating.lib.php"; | |
| include_once "include/class_admin.php"; | |
| include_once "include/class_organization.php"; | |
| include_once "include/class_user.php"; | |
| include_once "include/class_event.php"; | |
| $query="select * from ee_events_attendees where event_id='2696'"; |
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
| select b.cardnumber,b.FirstName,b.LastName,a.* from GL_HeldTables a,Members b where a.SDate >= '2015-01-01' and a.Memid=b.membershipid |
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
| #1. JS FRONTEND | |
| STORY : saya punya koleksi url dari sebuah API, saya mau mendapat semua hasil dari setiap url yang di pangil secara PARALEL | |
| atau bersamaan | |
| CATATAN : kita tidak ingin mengunakan modul/lib apa pun, semuanya native js | |
| TODO : buatlah function 'getAnyMember' yang akan memberikan callback berserta resultnya | |
| EXAMPLE RESPONSE EACH URL : | |
| {id:1,name:'jhon'} | |
| CLUE : | |
| var url=['http://api.example.com/gold/id/1','http://api.example.com/silver/id/2','http://api.example.com/silver/id/3','http://api.example.com/black/id/4'] |
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
| Object.defineProperty(global, '__stack', { | |
| get: function(){ | |
| var orig = Error.prepareStackTrace; | |
| Error.prepareStackTrace = function(_, stack){ return stack; }; | |
| var err = new Error; | |
| Error.captureStackTrace(err, arguments.callee); | |
| var stack = err.stack; | |
| Error.prepareStackTrace = orig; | |
| return stack; | |
| } |
OlderNewer