GithubHelp home page GithubHelp logo

wapplersystems / cleverreach Goto Github PK

View Code? Open in Web Editor NEW
7.0 7.0 35.0 540 KB

TYPO3 Extension for using newsletter service CleverReach

License: GNU General Public License v2.0

PHP 100.00%
php typo3 typo3-cms-extension

cleverreach's People

Contributors

dennismetz avatar dhoffmann1979 avatar jonasklause avatar nemo64 avatar schliesser avatar svewap avatar uncentereddiv avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

cleverreach's Issues

Path error ext_tables.php

14 days ago the
cleverreach/ext_tables.php
was changed.
$pageTsConfig = '<INCLUDE_TYPOSCRIPT: source="FILE:EXT:cleverreach/Configuration/TypoScript/TSconfig/Page/powermail.tsconfig">';

Now the path dont match anymore
cleverreach/Configuration/TypoScript/TsConfig/Page/powermail.tsconfig

[Bugfix] Option to set globalAttributes

At the moment there is no way to define an attribute as global.

added new property in form.yaml to define localization state.
default of this is local.

properties:  
    cleverreachField: yourfield  
    cleverreachAttributeLocalization: global

#28

How to transmit attributes to CleaverReach

I installed the extension and successfully added a new recipient to my CleverReach list. But how can I sent attributes (lastname, firstname, gender, i.e.) to CleverReach? In the code I found the cleverreachField Property:

https://github.com/svewap/cleverreach/blob/de297bc6e3f3077e50b815ff872d6e7cc7b866a1/Classes/Form/Finishers/CleverreachFinisher.php#L56

But how do I set this property inside the Powermail form editor? I found nothing in that regard in the editor docs.

Compatibility with PHP 7.3

Your extension depends on PHP 7.0 - 7.2
Typo3 9 works with PHP 7.3, could you please check against PHP 7.3?

v12 compatibility: rename file to ext_typoscript_setup.typoscript

Hi,

I just tested the release/v12 branch and it seems to work fine.
The only issue is that the file /cleverreach/ext_typoscript_setup.txt has to be renamed into /cleverreach/ext_typoscript_setup.typoscript
Otherwise the finisher is not registered and cannot be selected in the form configuration.

Regards!
Ulrike

Suggestion new feature for triggering the subscription (with patch)

In many forms you will want to have a checkbox like "I want to subscribe to the newsletter too". And only if the checkbox was checked by the user the subscription should be triggered (legacy version: subscription will always be triggered if there is a cleverreach-email-field defined).

I added a patch for this, would be great if you could include this in the next release.

The patch adds a feature for BE-Users
to define checkboxes as "the cleverreach trigger field" in the form editor of the form framework.

trigger.patch.zip

Will there ever be a new release?

I did fix an identifier which makes this extension for my use case unusable (#9) but the change is still not released which means i have use a dev version which i kind of dislike.

subscribers not added

Hi,
I installed cleverreach extension in our typo3 and added cleverreach API settings. We used CleverReach Optin form(ext:forms) and included in typo3 page. For getting client id, group id, form id, i created cleverreach account and created demo list, form and app. After this I submitted form with valid email id. But nothing will happen and i didnt get any mail or no subscribers added in cleverreach demo list. How can do this..

Problem with confirmation mail / name

Hello,

I have installed and configured the extension (0.1.6). I use the Forms Ext., I can register a user but there is no confirmation mail. Also the name is not passed correctly although I have specified the correct field.

API Response

Hi,

Eine finish Page die den APi Response ausgeben kann wäre nice.
Also z.B. Kunde der sich anmeldet ist schon angemeldet!

PHP Warning: Undefined array key "cleverreach"

Typo3: 11.5.24
Webserver Apache
PHP Version: 8.1.16
DB: MySQL 10.5.15

I'm getting an error every time i submit the form.

PHP Warning: Undefined array key "cleverreach" in /home/www/[...]/typo3conf/ext/cleverreach/Classes/Powermail/Finisher/CleverReach.php line 68

Undefined array key "cleverreach"

Hello,

I am currently getting the following error message:

Undefined array key "cleverreach" in cleverreach/Classes/Powermail/Finisher/CleverReach.php line 70

System: TYPO3 v12
PHP: 8.1
cleverrReach: 12.0.0

When checking the Finisher, I noticed that the flexForm values cleverreachFormId and cleverreachGroupId are read, but the SingelSelect of cleverreach is not. Unfortunately, the individual options are not displayed here yet.

I then checked the cleverreach/Configuration/TsConfig/Page/powermail.tsconfig and saw that the SingleSelect items have not yet been adapted to the new requirements of the TCA.

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.0 {
  0 = ---
  1 =
}

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.1 {
  0 = Anmelden
  1 = optin
}

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.2 {
  0 = Abmelden
  1 = optout
}

[Line 16-29]

For everything to work, the would need to be adjusted as follows:

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.0 {
  label = ---
  value =
}

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.1 {
  label = Anmelden
  value = optin
}

tx_powermail.flexForm.addField.settings\.flexform\.main\.cleverreach.config.items.2 {
  label = Abmelden
  value = optout
}

[Line 16-29]

Once this is changed, the extension works fine under TYPO3 v 12, so I would ask you to include this customization.

With kind regards

Not compatible with HTTP proxies

The extension uses a custom REST client to perform Cleverreach requests. This implementation does however not respect any anything set in $GLOBALS['TYPO3_CONF_VARS']['HTTP'] and does therefore not work, if TYPO3 uses a proxy for outgoing HTTP requests.

I recommend to use the TYPO3 API (RequestFactory - see https://docs.typo3.org/m/typo3/reference-coreapi/main/en-us/ExtensionArchitecture/HowTo/RestRequests/Index.html) for HTTP requests which always ensures, that configured HTTP settings are applied.

Fehler bei Abmeldung mit Powermail

Hallo,

ich bekomme bei der Abmeldung über Powermail immer die Nachricht:
"E-Mail: Diese Email-Adresse befindet sich nicht in unserer Liste"
Da ich mich aber kurz vorher mit der E-Mail Adresse angemeldet habe und auch von CleaverReach eine Bestätigung bekommen habe, kann das nicht sein.
Muss ich irgend etwas beachten damit es funktioniert?

Vielen Dank
Mathias

TYPO3 8.7 Compatibility

The extension isn't anymore compatible with TYPO3 8.7 as the dependency injection has been changed in Commit: 94ea0dc

This change is not yet included in the 0.1.5 release/tag, so it's still working with 8.7

Your next release 0.1.6 breaks compatibility to 8.7 because the dependencies aren't injected anymore:

Core: Exception handler (WEB): Uncaught TYPO3 Exception: Call to a member function getRestUrl() on null | Error thrown in file /.../typo3conf/ext/cleverreach/Classes/CleverReach/Api.php in line 57.

The new dependency injection works from TYPO3 9.0 upwards:
https://docs.typo3.org/c/typo3/cms-core/master/en-us/Changelog/9.0/Feature-82869-ReplaceInjectWithTYPO3CMSExtbaseAnnotationInject.html

where to set API-key?

Hello Sven

Til now I used a fork of your formhandler_cleverreach-extension, but know I like to switch to EXT:cleverreach for upgrading to TYPO3 9.5.9.

As far as I know an API-key has to be set. But I wasn't able to find any point to enter this in extension constants.
Is it necessary to set cleverreach-admin-username and cleverreach-admin-password - I think this is unsecure ^10.

best regards
EnzephaloN

TYPO3 9 EXT:form compatibility of validators

OptIn and OutOut validators for EXT:form need a class property $supportedOptions to define the validators options, otherwise they are not working in TYPO3 9. This is what I added to both classes, now they are working:

    /**
     * @var array
     */
    protected $supportedOptions = [
        'groupId' => [0, 'The group id', 'integer'],
    ];

v12: PHP Warning: Undefined array key "HTTP_REFERER"

Hi,

I am using:
TYPO3 v12
PHP 8.1 with warnings active
Branch feature/v12

If I reload a form that has a cleverreach finisher configured and has been already submitted, I get a PHP warning: Undefined array key "HTTP_REFERER" in file /cleverreach/Classes/CleverReach/Api.php for line 292 in the function sendSubscribeMail.

If that line is adjusted as follows, the warning disappears:

 $doidata = [
            'user_ip' => $_SERVER['REMOTE_ADDR'],
            'user_agent' => $_SERVER['HTTP_USER_AGENT'],
            'referer' => key_exists('HTTP_REFERER',$_SERVER) ? $_SERVER['HTTP_REFERER'] : '',
        ];

Could you adjust the code?

Thanks!
Ulrike

Respect Form Group ID in Powermail Validators

The Powermail Validators doesn't respect the Form Group ID, only the ID which is set in the TS.
If you have multiple forms with different Group IDs the Validator doesn't work.

Example:
Opt-Out Form - Group ID: 123456
TS Group ID: 654321

The Opt-Out Validator is using Group ID 654321 and will throw the error that the user is not present in the group, even when he is.

Tried to fix this by myself - but i'm not deep enough into Powermail Validators ;)

Small improvement idea how to add TSconfig

I just saw how you add PageTSConfig in ext_tables.php and would guess you a different solution to not use getUrl():

// $pageTsConfig = \TYPO3\CMS\Core\Utility\GeneralUtility::getUrl(\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath($_EXTKEY) . 'Configuration/TypoScript/TsConfig/Page/powermail.ts');

$pageTsConfig = '<INCLUDE_TYPOSCRIPT: source="FILE:EXT:cleverreach/Configuration/TSconfig/Page/powermail.ts">';
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig($pageTsConfig);

Powermail finisher Problem

When the form is to be sent, the following message appears:

Fatal error: Declaration of WapplerSystems\Cleverreach\Powermail\Finisher\CleverReach::initializeFinisher() must be compatible with In2code\Powermail\Finisher\AbstractFinisher::initializeFinisher(): void in /path-to/typo3conf/ext/cleverreach/Classes/Powermail/Finisher/CleverReach.php on line 124

The latest Github version is used in conjunction with the latest TYPO3 version 10.

powermail.tsconfig should be in `/Configuration/TsConfig/Page/`

According to the TSconfig Coding Guidelines and the registration in cleverreach/Configuration/TCA/Overrides/sys_template.php, tsconfig files like Configuration/TsConfig/Page/powermail.tsconfig should be placed under <extension>/Configuration/TsConfig/Page/.

Currently, powermail.tsconfig is in <extension>/Configuration/TypoScript/TsConfig/Page/, so the registration for static includes does not work.

Setting firstname, lastname?

Is there a way to set firstname and lastname by this extension?

Inside the Api.php there is a function setAttributeOfReceiver which is never used.

In the addReceiversToGroup one could do something like this:

        foreach ($aReceivers as $receiver) {
            $attributes = $receiver['attributes'];
            if (isset($attributes['email'])){
                foreach($attributes as $key => $value){
                    $this->setAttributeOfReceiver($attributes['email'], $key, $value);
                }
            }
        }

Maybe...?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.