Hi Jarno, On Thu, Mar 30, 2017 at 07:18:48AM +0300, Jarno Huuskonen wrote: > Hi, > > On Sat, Mar 25, Aleksandar Lazic wrote: > > how about to try this, it's untested. > > > > http-request set-var(req.mysticky) > > url_param(email),url_param(newsletter_id) > > stick on req.mysticky table detailspage > > I didn't get this to work. > > I didnt find a way to concat the two url_params. These are some examples > I tried: > http-request set-var(req.mysticky) %[urlp(em)]%[urlp(nl)] > http-request set-var(req.mysticky) %[urlp(em)],%[urlp(nl)] > http-request set-var(req.mysticky) urlp(em),urlp(nl) > http-request set-var(req.mysticky) urlp(em)urlp(nl) > > Using header seems to work: > http-request set-header X-Concat %[urlp(em)]%[urlp(nl)] > http-request set-var(req.mysticky) req.hdr(X-Concat) > > Is there a way to concat strings in set-var w/out using header ?
Not for now. With Thierry we've started to think about a stack-based expression evaluator which would make it trivial to concat strings and perform many other operations but we found that it will suffer from some deep problems like retrying failed fetches. Thus I think that for now we'll have to only implement a "concat" converter supporting a constant string and another one to concat a variable. Maybe we can call them "strcat()" for constant strings and "varcat()" for variable names. Is anyone interested in working on this ? Willy

