Hello,
I am testing a simple JSSP to show a specific recipient data and edit it.
I am able to display the data but failing editing the data. I don't get any error. How is it possible to log errors if any? Trying to create new data also failed. Following all possibilities here: https://blog.floriancourgey.com/2018/08/use-querydef-the-database-toolkit-in-adobe-campaign with no error.
Thank your for your help!
Here's the code:
<%
response.addHeader("Pragma", "no-cache");
response.addHeader("Cache-Control", "no-cache");
response.addHeader("Expires", new Date().toGMTString());
response.setContentType("text/html;charset=utf-8");
logonWithUser('...', '...');
var recipientId = request.getParameter("recipient_id");
%>
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
</head>
<body>
<%
var recipient = NLWS.nmsRecipient.load(recipientId);
%>
Firstname: <%=recipient.firstName%> // display OK
<%
recipient.firstName = 'New Firstname';
recipient.save(); // does not overwrite with new firstname
%>
</body>
</html>