Live Helper Chat support forum.. Forum is locked. New place for questions - Github Discussions

You are not logged in.

Announcement

#1 2017-03-15 16:59:41

kjaber
Member
Registered: 2017-03-15
Posts: 2

Prefill fields without showing them

Thanks for this service.

I want to use prefill fields feature for username and email, but i don't want to show them !
so i set the following settings From >>  System configurationStart chat form settings >>

Name => only "This field is invisible but prefilled data is collected" checked
Email =>  only "This field is invisible but prefilled data is collected" checked
Message => both "This field is visible in the popup" and "This field is visible in the page widget" are checked

and used the following code :


var LHCChatOptions = {};
LHCChatOptions.opt = {widget_height:340,widget_width:300,popup_height:520,popup_width:500,domain:'192.168.112.221:8081/Portal/reliance'};
(function() {
var po = document.createElement('script'); po.type = 'text/javascript'; po.async = true;
var referrer = (document.referrer) ? encodeURIComponent(document.referrer.substr(document.referrer.indexOf('://')+1)) : '';
var location  = (document.location) ? encodeURIComponent(window.location.href.substring(window.location.protocol.length)) : '';
po.src = '//localhost/chat/index.php/chat/getstatus/(click)/internal/(position)/bottom_right/(ma)/br/(top)/350/(units)/pixels/(leaveamessage)/true?r='+referrer+'&l='+location;
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(po, s);
})();



LHCChatOptions .attr_prefill = new Array();
LHCChatOptions .attr_prefill.push({'name':'email','value':'sensitive info (email) removed by PeopleInside','hidden':true});
LHCChatOptions .attr_prefill.push({'name':'username','value':'Username here'});

lh_inst.refreshCustomFields()
lh_inst.lh_openchatWindow();

Note that I did not used
<div id="lhc_status_container_page">&nbsp;</div>
Because i need to keep the default widget

Still the username and email not synchronized in admin chat window.

Many Thanks smile

Last edited by PeopleInside (2017-03-15 17:54:03)

Offline

#2 2017-03-15 17:52:50

PeopleInside
Administrator
From: Italy
Registered: 2014-04-10
Posts: 4,046
Website

Re: Prefill fields without showing them

Hi kjaber,
welcome in the live helper chat.

Please note: do not post email address than is not yours, I will remove from your message.
I AM sorry to inform that I cannot help with your request as is out of my free limited support.

If you need help on solve this issue you need ask for the commercial support.
More info in my forum signature.
Thank you!  smile

Last edited by PeopleInside (2017-03-15 18:02:31)


lol PeopleInside - Live helper chat - free limited forum support!
wink For commercial support or GitHub [see FAQ here]
ops If you want to support this open source project, just donate [see support page]
glasses Something wrong with the forum? [contact a superhero]

Offline

#3 2018-11-14 08:51:15

nsoeryana
New member
Registered: 2018-09-10
Posts: 4

Re: Prefill fields without showing them

hi admin,

i want used prefill field, but not showing
i define  var LHCChatOptionsPage ={};

inside $(document).ready(function(){
     var LHCChatOptionsPage ={};
}


code like this.

many thanks. smile

Offline

#4 2018-11-14 16:15:53

PeopleInside
Administrator
From: Italy
Registered: 2014-04-10
Posts: 4,046
Website

Re: Prefill fields without showing them

Hi nsoeryana , sorry but I am unable to help about auto prefill field, with my basic support.
You can look at the documentation, try a search on the forum or consider the commercial support.


lol PeopleInside - Live helper chat - free limited forum support!
wink For commercial support or GitHub [see FAQ here]
ops If you want to support this open source project, just donate [see support page]
glasses Something wrong with the forum? [contact a superhero]

Offline

Board footer