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
working code sample | |
<div class="col col-md-3 col-sm-6 col-xs-12 press-item editorial digital wrapper featured"> | |
<div class="pressitemholder press-padder"> | |
<a href="{{media url='wysiwyg/press/Online_WhoWhatWear-2.9.16.jpg'}}" title="WHO WHAT WEAR February 2016" class="lightbox pressanchor"></a> | |
<img src="{{media url="wysiwyg/press/Online_WhoWhatWear-2.9.16.jpg"}}" alt="" /> | |
<div class="press-item-title"> | |
<div class="press-title-wrap"> | |
<span class="maintitle">WHO WHAT WEAR</span> | |
<span class="subtitle">February 2016</span> | |
</div> |
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
/* Smartphones (portrait and landscape) ----------- */ | |
@media only screen | |
and (min-device-width : 320px) | |
and (max-device-width : 480px) { | |
/* Styles */ | |
} | |
/* Smartphones (landscape) ----------- */ | |
@media only screen | |
and (min-width : 321px) { |
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
/* --------------------------------------------------------- */ | |
/* BASIC CSS ----------------------------------------------- */ | |
/* --------------------------------------------------------- */ | |
/* YOUR STYLES */ | |
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 | |
//get featured image ID | |
$thumb_ID = get_post_thumbnail_id( $post->ID ); | |
//attachement loop - with exclude argument for featured image | |
$args = array( | |
'orderby' => 'menu_order', | |
'post_type' => 'attachment', | |
'post_parent' => get_the_ID(), | |
'post_mime_type' => 'image', |
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 | |
if($_product->getTypeId() == "configurable"): | |
$conf = Mage::getModel('catalog/product_type_configurable')->setProduct($_product); | |
$simple_collection = $conf->getUsedProductCollection()->addAttributeToSelect('*')->addFilterByRequiredOptions(); | |
foreach($simple_collection as $simple_product){ | |
echo $simple_product->getSku() . " - " . $simple_product->getName() . " - " . Mage::helper('core')->currency($simple_product->getPrice()) . "<br>"; | |
} | |
endif; | |
?> |
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
<script> | |
//we create new function | |
spConfig.setInitialState = function(dropdown_id) { | |
//select dropdown | |
var dropdown = $(dropdown_id); | |
//remove empty option from dropdown so it is not selectable after initial selection | |
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
function fireEvent(element,event) | |
{ | |
if (document.createEventObject) | |
{ | |
// dispatch for IE | |
var evt = document.createEventObject(); | |
return element.fireEvent('on'+event,evt); | |
} | |
else | |
{ |
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
## rewrite everything else to index.php | |
RewriteRule .* index.php [L] | |
RewriteCond %{REQUEST_URI} !^/index.php/admin/ | |
RewriteCond %{REQUEST_URI} !^/index.php/admin | |
RewriteRule ^index.php/(.*) /$1 [R=301,QSA,L] |
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 | |
require_once('app/Mage.php'); | |
Mage::app()->setCurrentStore(Mage::getModel('core/store')->load(Mage_Core_Model_App::ADMIN_STORE_ID)); | |
$installer = new Mage_Sales_Model_Mysql4_Setup; | |
$attribute = array( | |
'type' => 'text', | |
'label'=> 'Custom Title', | |
'input' => 'textarea', | |
'global' => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_GLOBAL, | |
'visible' => true, |
NewerOlder