Skip to content

Instantly share code, notes, and snippets.

View deivisonarthur's full-sized avatar

Deivison Arthur Lemos Serpa deivisonarthur

View GitHub Profile
Coleção Buyer
Email - Email do comprador.
GenderEnum - M = Masculino / F = Feminino
HomePhone/WorkPhone/MobilePhone = Telefone do comprador no formato 999(999)99999999
Coleção BuyerAddress
City - Cidade do comprador
Complement - Complemento do endereço
SELECT `e`.*, `at_prefix`.`value` AS `prefix`, `at_firstname`.`value` AS `firstname`, `at_middlename`.`value` AS `middlename`, `at_lastname`.`value` AS `lastname`, `at_suffix`.`value` AS `suffix`, CONCAT(IF(at_prefix.value IS NOT NULL AND at_prefix.value != '', CONCAT(LTRIM(RTRIM(at_prefix.value)), ' '), ''), LTRIM(RTRIM(at_firstname.value)), ' ', IF(at_middlename.value IS NOT NULL AND at_middlename.value != '', CONCAT(LTRIM(RTRIM(at_middlename.value)), ' '), ''), LTRIM(RTRIM(at_lastname.value)), IF(at_suffix.value IS NOT NULL AND at_suffix.value != '', CONCAT(' ', LTRIM(RTRIM(at_suffix.value))), '')) AS `name`, `at_default_billing`.`value` AS `default_billing`, `at_billing_postcode`.`value` AS `billing_postcode`, `at_billing_city`.`value` AS `billing_city`, `at_billing_telephone`.`value` AS `billing_telephone`, `at_billing_region`.`value` AS `billing_region`, `at_billing_country_id`.`value` AS `billing_country_id` FROM `customer_entity` AS `e`
LEFT JOIN `customer_entity_varchar` AS `at_prefix` ON (`at_prefi
#pagespeed INICIO
# PageSpeed
pagespeed on;
pagespeed ImageRecompressionQuality 65;
pagespeed EnableFilters combine_css,rewrite_css,sprite_images,combine_javascript,recompress_images,resize_images,collapse_whitespace,remove_comments,extend_cache,combine_heads,move_css_above_scripts,make_google_analytics_async,convert_png_to_jpeg,insert_image_dimensions,rewrite_javascript;
# let's speed up PageSpeed by storing it in the super duper fast memcached
<!-- BEGIN GOOGLE ANALYTICS CODEs -->
<script type="text/javascript">
//<![CDATA[
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-23053096-1']);
//_gaq.push(['_trackPageview', '/cielo/compra/confirmada/25144/']);
_gaq.push(['_trackPageview']);
@deivisonarthur
deivisonarthur / ga,php
Last active December 21, 2015 02:28
Forçando o GA na tela de sucesso do Magento
<?php
$order = Mage::getModel('sales/order')->loadByIncrementId($this->getOrderId());
$price = $order->getGrandTotal();
$frete = $order->getShippingAmount();
$subtotalDireto = $order->getSubtotal();
$estado = $order->getBillingAddress()->getRegion();
$cidade = $order->getBillingAddress()->getCity();;
$order = Mage::getModel('sales/order')->loadByIncrementId($this->getOrderId());
$price = $order->getGrandTotal();
$frete = $order->getShippingAmount();
$subtotalDireto = $order->getSubtotal();
echo "Subtotal: R$ ".number_format($subtotalDireto, 2, ',', '');
echo " - Frete: R$ ".number_format($frete, 2, ',', '');
echo " - Total: R$ ".number_format($price, 2, ',', '');
<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0" xmlns:g="http://base.google.com/ns/1.0">
<channel>
<title>Data feed Title</title>
<link>{base_url}</link>
<description>Data feed description.</description>
{each type="product"}
<item>
<g:id>{sku}</g:id>
<title><![CDATA[{name,[html_entity_decode]}]]></title>
<?php
/*
############### Exemplo do XML do Jacotei
Basta chamar o price com as funcões assim:
<parcelas>{price,[numerototalparcelas]}</parcelas>
<valor>{price,[valortotalparcelas]}</valor>
*/
<?php
/*
############### Exemplo do XML do Jacotei
Basta chamar o price com as funcões assim:
<parcelas>{price,[numerototalparcelas]}</parcelas>
<valor>{price,[valortotalparcelas]}</valor>
*/
<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0" xmlns:g="http://base.google.com/ns/1.0">
<channel>
<title>Data feed Title</title>
<link>{base_url}</link>
<description>Data feed description.</description>
{each type="product"}
<item>
<g:id>{sku}</g:id>
<title><![CDATA[{name,[html_entity_decode]}]]></title>