This file contains 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
<customer_account_create> | |
<reference name="customer_form_register"> | |
<action method="setTemplate"><template>novoatributo/persistent/customer/form/register.phtml</template></action> | |
</reference> | |
</customer_account_create> | |
<customer_account_edit> | |
<reference name='customer_edit'> | |
<action method="setTemplate"><template>novoatributo/customer/form/edit.phtml</template></action> | |
</reference> | |
</customer_account_edit> |
This file contains 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 Apenas_Numeros(caracter) | |
{ | |
var nTecla = 0; | |
if (document.all) { | |
nTecla = caracter.keyCode; |
This file contains 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 foreach($this->getParcelas() as $parcela): ?> | |
<?php | |
if( $parcela['parcela'] <= 2 ){ | |
?> | |
<label style="clear: both !important; padding: 0px !important"><input style="width: 20px !important" type="radio" id="cielo_cc_parcelas_<?php echo $parcela['parcela']; ?>" name="payment[cc_parcelas]" class="validate-one-required-by-name" value="<?php echo $parcela['parcela']; ?>"><strong><?php echo $parcela['label']; ?></strong> <em><?php if( $parcela['parcela'] != 1 ): echo "(Sem juros)"; endif; ?></em> </label><br /> | |
<?php | |
} | |
if( $parcela['parcela'] == 3 && $total > 70 || $parcela['parcela'] == 3 && $total < 150 && $total > 70 ){ |
This file contains 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 foreach($this->getParcelas() as $parcela): ?> | |
<?php | |
if( $parcela['parcela'] <= 2 ){ | |
?> | |
<label style="clear: both !important; padding: 0px !important"><input style="width: 20px !important" type="radio" id="cielo_cc_parcelas_<?php echo $parcela['parcela']; ?>" name="payment[cc_parcelas]" class="validate-one-required-by-name" value="<?php echo $parcela['parcela']; ?>"><strong><?php echo $parcela['label']; ?></strong> <em><?php if( $parcela['parcela'] != 1 ): echo "(Sem juros)"; endif; ?></em> </label><br /> | |
<?php | |
} | |
if( $parcela['parcela'] == 3 && $total < 150 && $total > 70 ){ |
This file contains 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
$results = Mage::getModel('xyz/abc')->getCollection(); | |
$results->addFieldToSelect('name'); | |
$results->addFieldToSelect('keywords'); | |
$results->addOrder('name','ASC'); | |
$results->setPageSize(5); | |
$results->getSelect()->where("keywords like '%foo%' or additional_keywords like '%bar%'"); | |
$results->load(); |
This file contains 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
//for AND | |
$collection = Mage::getModel('sales/order')->getCollection() | |
->addAttributeToSelect('*') | |
->addFieldToFilter('my_field1', 'my_value1') | |
->addFieldToFilter('my_field2', 'my_value2'); | |
echo $collection->getSelect()->__toString(); | |
//for OR - please note 'attribute' is the key name and must remain the same, only replace //the value (my_field1, my_field2) with your attribute name |
This file contains 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
## railsbox.org:~ ozeias$ vim /usr/local/nginx/conf/vhosts/example.com.conf | |
# This is for a WordPress installed at /var/www/example.com/blog, and accessed at http://example.com | |
server { | |
listen 80; | |
server_name example.com; | |
root /var/www/example.com/blog; | |
index index.php; | |
access_log /usr/local/nginx/logs/example.com.access.log; |
This file contains 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
## railsbox.org:~ ozeias$ vim /usr/local/nginx/conf/vhosts/blog.example.com.conf | |
# This is for a WordPress installed at /var/www/example.com/blog, and accessed at http://blog.example.com | |
server { | |
listen 80; | |
server_name blog.example.com; | |
root /var/www/example.com/blog; | |
index index.php; | |
access_log /usr/local/nginx/logs/blog.example.com.access.log; |
This file contains 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
## railsbox.org:~ ozeias$ vim /usr/local/nginx/conf/vhosts/example.com.conf | |
# This is for a WordPress installed at /var/www/example.com/blog, and accessed at http://example.com/blog | |
server { | |
listen 80; | |
server_name example.com; | |
root /var/www/example.com; | |
index index.php; | |
access_log /usr/local/nginx/logs/example.com.access.log; |
This file contains 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; | |
-- Customers | |
TRUNCATE `customer_address_entity`; | |
TRUNCATE `customer_address_entity_datetime`; | |
TRUNCATE `customer_address_entity_decimal`; | |
TRUNCATE `customer_address_entity_int`; | |
TRUNCATE `customer_address_entity_text`; | |
TRUNCATE `customer_address_entity_varchar`; | |
TRUNCATE `customer_entity`; |
OlderNewer