Skip to content

Instantly share code, notes, and snippets.

View anddimario's full-sized avatar

Andrea Di Mario anddimario

View GitHub Profile
googleapis
.discover('analytics', 'v3')
.execute(function(err, client) {
if (err) {
utils.applog('error', {from: "lib/fetch/analytics.js", value: err, reference: "getAnalytics", resource: user_id});
return;
}
// Array that contains all request
var requests_list = [
{metrics: "ga:visits,ga:newVisits,ga:percentNewVisits,ga:newVisits,ga:pageviews,ga:visitBounceRate,ga:pageviewsPerVisit,ga:avgTimeOnSite"},
@anddimario
anddimario / create_meta_product.php
Created November 9, 2019 08:49
Bulk creation of SEO meta title and description for Prestashop
<?php
// Info:
// http://doc.prestashop.com/pages/viewpage.action?pageId=51184692
// Used tables: ps_manufacturer, ps_category_lang, ps_product_lang, ps_product
// Run: php create_meta_product.php
// Clean:
// UPDATE ps_product_lang SET meta_title = "", meta_description="";
require(dirname(__FILE__).'/./config/config.inc.php');