stblink VIP
Total posts: 501
15 Июль 2013 08:48

http://www.acyba.com/en/support/documentation/149-acymailing-plugin-contactacymailing.html#params

I wanted to insert "subscribe to our newsletter" when a user uses E-mail field to send an e-mail. Similar to screenshots on the link i provided.

They have support for com_contact but i believe Cobalt e-mail field does not use it. Is there any way? or it has to be Acymailing plugin to do this?

Последние изменения: 02 Март 2014


Sergey
Total posts: 13,748
16 Июль 2013 04:47

That should be both I think. We can add this integration if they have documentation how to add шею how programmatically subscribe user. Then we will add it.


pepperstreet VIP
Total posts: 3,837
16 Июль 2013 20:25

Following ;-)


stblink VIP
Total posts: 501
17 Июль 2013 08:41

This link provides the url options for URL Subscription.

Using this example:

> > > > > > > > > > > > > > >
>

Where the last value (1) is the newsletter ID that will be used to insert the user.

Of course that, with this method i believe everyone can "guess" if a site is using acymailing and decides to have nothing to do and use it to insert e-mails, that's why confirmation link should always be activated.

If using commercial version they have the url option "seckey=YOUR_KEY" so that this doesn't happen.

Still have to test the code though, don't really know if it's working.


Sergey
Total posts: 13,748
18 Июль 2013 08:22

I am not sure how to finish it. We need name to subscribe user. Where do we take the name? And if user is logged in then it is not connected to entered email.


Sergey
Total posts: 13,748
18 Июль 2013 08:23

I added integration to next version but it only adds to mailing list current user and use user registered email.


stblink VIP
Total posts: 501
18 Июль 2013 09:10

Hmmm i see what you mean.

This is what is intended. To send the "e-mail" field threw url to Acymailing.

I already tested this url and it's working:

http://ww.mysite.com/index.php?option=com_acymailing& ;ctrl=sub&task=optin&hiddenlists=1,4&user[email]=Этот адрес электронной почты защищен от спам-ботов. У вас должен быть включен JavaScript для просмотра. document.getElementById('cloak370f20a164d76b86ddeaea3fbe7900fe').innerHTML = ''; var prefix = 'ma' + 'il' + 'to'; var path = 'hr' + 'ef' + '='; var addy370f20a164d76b86ddeaea3fbe7900fe = 'yourname' + '@'; addy370f20a164d76b86ddeaea3fbe7900fe = addy370f20a164d76b86ddeaea3fbe7900fe + 'example' + '.' + 'com'; var addy_text370f20a164d76b86ddeaea3fbe7900fe = 'yourname' + '@' + 'example' + '.' + 'com';document.getElementById('cloak370f20a164d76b86ddeaea3fbe7900fe').innerHTML += ''+addy_text370f20a164d76b86ddeaea3fbe7900fe+''; &user[name]=yourname&redirect= http://www.google.com& ;lang=en

But... this example has 2 lists (1 and 4) and on Acymailing i only have one list with ID 1. I got an error but it was a redirect error regarging the last setting from the url.

I tested without redirect and dispite the e-mail already existed in Acymailing it said successfully subscribed, so there are really no errors that interfer with the Cobalt e-mail send process for what i've seen.

A complete Acymailing integration would be to have options to turn on/off options mentioned here and insert some settings.

But if for now the options set in bold would be available it would be nice:

index.php?option=com_acymailing&ctrl=sub&task=optin&hiddenlists=1,2,3&user[email]=Этот адрес электронной почты защищен от спам-ботов. У вас должен быть включен JavaScript для просмотра. document.getElementById('cloak5d8fdc3fd009ecda09d5016be6f37a18').innerHTML = ''; var prefix = 'ma' + 'il' + 'to'; var path = 'hr' + 'ef' + '='; var addy5d8fdc3fd009ecda09d5016be6f37a18 = 'john' + '@'; addy5d8fdc3fd009ecda09d5016be6f37a18 = addy5d8fdc3fd009ecda09d5016be6f37a18 + 'example' + '.' + 'com'; var addy_text5d8fdc3fd009ecda09d5016be6f37a18 = 'john' + '@' + 'example' + '.' + 'com';document.getElementById('cloak5d8fdc3fd009ecda09d5016be6f37a18').innerHTML += ''+addy_text5d8fdc3fd009ecda09d5016be6f37a18+''; &**seckey=Hlkfj897sqiduh7805

**

I don't know how it would work the redirect option in this case, it would be a matter of testing it later.


stblink VIP
Total posts: 501
18 Июль 2013 09:19

I am not sure how to finish it. We need name to subscribe user. Where do we take the name? And if user is logged in then it is not connected to entered email.

We don't need the name, well i mean, if for a complete integration then yes but it would be available from the NAME field on E-mail form. Although not everyone requires it.

If i'm logged in, on Acymailing module i can see my e-mail already filled on the input field. But in this case it would be the e-mail inserted on the Cobalt e-mail field.


Sergey
Total posts: 13,748
18 Июль 2013 09:43

I see. I made this integration.


stblink VIP
Total posts: 501
18 Июль 2013 09:48

Thanks!

Работает на Cobalt