How to track Mailchimp links from merge tags - mailchimp

I've just created a custom template to be used on Mailchimp.
Some links come from custom merge tags and point to the website related to Mailchimp. The problem is that those links from merge tags are not being tracked by Mailchimp.
I found this and of course tried but it didn't work:
how can i tracking click in custom html template mailchimp?
As an example, one of my links looks like this:
<p mc:edit="product1_url">
<a class="product-button" href="http://mywebsite.com*|PRODURL1|*" target="_blank">BUY NOW</a>
</p>
The PRODURL1 merge tag is type text and contains a path to a product, so the resulting url looks like http://mywebsite.com/product/123456 and it works if a click it on the sent email.
Any experience or direction?
Thanks!!

Well, after trying and trying and trying more I've found out why it wasn't working.
First part of the links MUST include the /, the second part (contained on the merge tag) MUST NOT include the /).
So now with this configuration Mailchimp tracks the links:
<a class="product-button" href="http://mywebsite.com/*|PRODURL1|*" target="_blank">BUY NOW</a>
Of course now PRODURL1 = "products/123456". So the same url is rendered, but this time tracked by Mailchimp.

Related

Setting Mailchimp campaign content html not working

I tried to update my campaign html content using mailchimp api:
/campaigns/{campaign_id}/content
You can find more information about this api here: https://developer.mailchimp.com/documentation/mailchimp/reference/campaigns/content/#
Before sending a campaign, I tried to get campaign content html, modified it and then set campaign content html using above api. I just simply use BeautifulSoup to append a new tag to content body:
content.body.append(BeautifulSoup('<p>Mailchimp is freaking shittttt</p>'))
Then, some interesting things happen, the first campaign I created, it works fine, the tag added appears in my email. But, then the sub-sequence campaigns not working anymore, the tag added not appearing.
I observed something strange on my mailchimp campaign site, even though I set campaign html content, only Plain-Text Email gets changed (HTML Source still the old version) for both working and not working campaign.
Anyone got this issue before?
I had a similar issue and I had to take a slightly different approach to solve it. According to this answer by Joel H., "MailChimp doesn't allow updating the campaign's HTML content because the campaign type is based on a template. In order to update the HTML content, the campaign has to be set to custom HTML instead of a template."
That solution didn't suit me but it led me to another solution: creating a template, creating editable content areas within that template, and then using the API to retrieve and edit the text in those content areas.
Here is an attempt at adapting my code to solve your problem. I'm using Python 3 and the mailchimp3 client.
default_footer_content = client.templates.default_content.all(template_id=TEMPLATE_ID)['sections']['SECTION_NAME']
new_footer_content = default_footer_content.replace(PLACEHOLDER, 'Mailchimp is freaking shittttt')
client.campaigns.content.update(campaign_id=CAMPAIGN_ID, data={'template': {'id': TEMPLATE_ID, 'sections': {'SECTION_NAME': new_footer_contennt}}})
Some pointers on the above code:
You can find TEMPLATE_ID with the API or simply by copying the numbers at the end of the URL when editing the template in the web interface
You define SECTION_NAME by placing 'mc:edit="SECTION NAME"' in the appropriate place in the template
I've used .replace() rather than .append() so you will need to put PLACEHOLDER or similar at the appropriate place in the template
I hope that helps, happy to modify my answer if it needs more clarification. This is my first answer on Stack Overflow so constructive criticism appreciated :)

Markup tags in product descriptions

I'm trying to use markup tags to link to info pages within the "description" attribute of a product. However, it's not giving me a clean URL path when the description is printed to the page.
Trying:
Contact Us
does not give the expected url. I've confirmed i'm doing this outside of WYSIWYG mode too.
When the text is rendered is returned to the browser as this html:
Contact Us
A resulting click on the link then ends up as:
http://example.com/prod-category/my-product/%7B%7Bstore%20url=
From what I can tell the markup tags aren't designed to be used in this way. Is it possible to extend it so it could work? Otherwise I guess I need to include the actual URL in the description?
Thanks for suggestions.
You can´t use the double-curly syntax because the attributes value is not being processed by magento´s template filter, which does the magic. You can use them e.g. in CMS or email Templates out of the box.

personal ad - schema markup

We have a website where people can create personal ads in order to find language-partners.
Does anyone have an idea on how to markup these ads using schema.org?
By now we only have rel=author on each author-name of an ad. But it would be good if we could also markup the following elements of the ads:
the ad itself (the div that wraps the ad)
author-image
authoer location/homelocation
creation date
mothertongue
wanted/learn language
description
Thanks in advance for your help!
Uhm, not exactly an expert here, but I think you should wrap all that in a http://schema.org/Person and use the already existing tags for that, assuming the ad links to a user's homepage you can just add the link as a url for the person.
Assuming a div contains all that you just define it as:
<div itemprop="author" itemscope itemtype="http://schema.org/Person">
.... all the properties ....
</div>
If I'm not mistaken all the described properties are already defined in Person, in fact you can find most of them in the example at the bottom of the page, just take a look at http://schema.org/Person
Really can't give you any more information without an already existing markup sample.

(sharp) # sign in query string and SEO

I have a site Index.html and there is a categories menu generated from database. Menu consists of HTML anchors, but href attribute is always something like "Index.html#cat=xyz" because content of each category is generated through AJAX call.
<br />
<br />
<br />
From the AJAX side everything works, but I want to ask if for example Google or other search engine will index these links which contains # (sharp) sign. Thanks for answers.
You're asking the wrong question. If you want your links to be indexed, make them obvious to a crawler about the content. Multiple links to the same page won't help your SEO efforts. Consider creating a separate page for "contacts" "investor information" "careers" (or whatever your categories are) and publishing them. Then your link becomes
careers
etc. When a human sees this link (your actual end target) he'll be able to make a better choice whether or not it's the "right" result.
using it like that will not work good for search engins and for users not have javascript enabled.
you need to make it lie facebook url redirect with seo friendly
you will need to use jQuery Hash url
Regards
Use ajax and when the user click on the link use the attribute - onclick="LoadHref('cat','1');return false;"

Is there a way to tell Google, certain elements are irrelavent to page?

I have a page that shows the main product for that page, next to it though are "related products" which when you click on them you go to their page, and they have their own related products as well. The problem is that the related products are getting indexed by Google so when you search for product-A you may get the product-B page where product-A is a related item, instead of just getting the product-A page. I am trying to prevent this. Any ideas?
Thanks!
You can add rel="nofollow" in any links you don't want a bot to crawl. In this case, you can apply that tag to all your links and google won't follow them off your main page.
http://en.wikipedia.org/wiki/Nofollow
EDIT for clarification:
Page "A" is for widgets. You want this page to be returned for searches regarding widgets; on this page is a "related searches" section which links to Other Widgets. On all the anchor tags on page "A" which link to pages "B" and "C" (the related searches for Other Widgets), you'll put a rel="nofollow" tag. This will prevent Google from hitting page A and then following your "related searches" links off to pages "B" and "C".
This will NOT prevent pages "B" and "C" from being indexed on their own, it just prevents them from getting pulled in from page "A".
EDIT#2:
rel="nofollow" tells bots you don't want them to follow the link to the second page. Regardless of the anchor text on a link from A->B, if you've nofollowed it the bot won't "flow" pagerank to the linked-to page and should not follow the link to page "B" to index it due to that tag on the anchor. Note that this is not foolproof: Yahoo and other SE's may not treat nofollow like Google....so your best bet is to make sure that each page is strongly on-page-SEO'd such that it gets included in the index for the term you want it to be included for. Hope this helps...but like much of the SEO world there are few hard-and-fast rules which apply universally.
yes... put them at the bottom of the page for content,
if you want that to appear visually at the top of the page, use a css layout to re-arrange the page elements
also, as darksquid already said, add rel="nofollow" to links you don't want considered
another tip (pertaining to your comment on darksquid's post):
You could load the content via ajax, which would keep most search engine spiders from seeing it at all (since they don't generally execute javascript)
Use Google Applicance - googleoff / googleon Tags:
http://www.geekzilla.co.uk/ViewC8614968-56ED-4729-9C12-F01677DAC412.htm

Resources