Willkommen, Gast
Benutzername: Passwort: Angemeldet bleiben:

THEMA: Getting a survey response into Admin Notification subject line or attribute

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105695

  • jsavage
  • jsavages Avatar
  • OFFLINE
  • Fresh Lemon
  • Beiträge: 19
  • Dank erhalten: 1
  • Karma: 1
I have seen how it is possible to pre-populate survey answers with attributes.
Is it possible to do the reverse and place a response into an attribute? This is simply to make it easier to get an indication of high level results in the email box or in the Token Management Area.

Lets take the simplest example - a survey with one question and a Yes/No answer. My survey has an additional attrribute called response1.

1. How can I get the answer to Question 1 rto be placed back into the attribute response1 ?

2. if that is not possible, then how about displaying the answer Y/N in the subject line of the notification?

Thanks all,

James
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105707

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 4207
  • Dank erhalten: 791
  • Karma: 360
You cannot write survey responses to the tokens table without an AJAX call to a remote PHP script.

However, in the email editor you can use Expression Manager to pipe responses into the subject line (or in the mail body) like this:

Response submission for survey {SURVEYNAME}. Q1 answer: {q1.shown}

Capture3_2014-02-27.png



.
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
Der Administrator hat öffentliche Schreibrechte deaktiviert.
Folgende Benutzer bedankten sich: jsavage

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105710

  • DenisChenu
  • DenisChenus Avatar
  • OFFLINE
  • Moderator Lime
  • Beiträge: 6362
  • Dank erhalten: 827
  • Karma: 245
tpartner schrieb:
You cannot write survey responses to the tokens table without an AJAX call to a remote PHP script.
Or with the new event : afterSurveyComplete ;)
manual.limesurvey.org/Plugin_events

Denis
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105714

  • tpartner
  • tpartners Avatar
  • OFFLINE
  • LimeSurvey Team
  • Beiträge: 4207
  • Dank erhalten: 791
  • Karma: 360
That would be great if I could actually get a plugin to work.
Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

LimeSurvey is open-source and run entirely by volunteers so please consider donating to support the project.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105719

  • jsavage
  • jsavages Avatar
  • OFFLINE
  • Fresh Lemon
  • Beiträge: 19
  • Dank erhalten: 1
  • Karma: 1
sounds promissing. Will take a look.
James
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105723

  • DenisChenu
  • DenisChenus Avatar
  • OFFLINE
  • Moderator Lime
  • Beiträge: 6362
  • Dank erhalten: 827
  • Karma: 245
tpartner schrieb:
That would be great if I could actually get a plugin to work.
I don't actually test afterSurveyComplete, but did you try ShowResponse plugin ?
You need to move it from plugins/demo/ to plugins/ directory.

He use pluginManager->getAPI()->getResponse, seems promising :)
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Getting a survey response into Admin Notification subject line or attribute 7 Monate 4 Tage her #105740

  • jsavage
  • jsavages Avatar
  • OFFLINE
  • Fresh Lemon
  • Beiträge: 19
  • Dank erhalten: 1
  • Karma: 1
OK - Have that plug in activated but I haven't found any documentation for it. I would even be happy to write the documentation if I could only someone could explain how it is supposed to be used.

Kind regards,

James
Der Administrator hat öffentliche Schreibrechte deaktiviert.
Moderatoren: ITEd
Ladezeit der Seite: 0.185 Sekunden
Donation Image