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

You are not logged in.

Announcement

#1 2020-04-15 19:49:54

caminomaster
Member
Registered: 2020-04-09
Posts: 24

How to link widget with operator, same domain but different pages.

Requirement:
Website has different pages, each one needs it's own operator and it's own widget. (i.e pages A and B).

Issue:
I made it work using one department for each user, and an identifier to avoid open chat in page A to load in page B. (i.e page A operator,department and identifier 1, page B operator,department and identifier 2).

Updated to last version, with widget v2, now it isn't working (i mean, open chat in page A loads in pages B and C...)


I'll be glad to know how can i achieve this. If it's possible without having to create a department for each user, so much better (the less complex, the better).

Thanks in advance

Last edited by caminomaster (2020-04-15 19:51:10)

Offline

#2 2020-04-16 07:22:36

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

1587021690_img-20200415-wa0005.jpg

Now we had this issue!

Offline

#3 2020-04-16 07:39:06

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Sorry,
But I really don't understand your workflow big_smile

Offline

#4 2020-04-16 08:39:05

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

In simple words, imagine i need to do like in
https://livehelperchat.com/how-do-i-con … -246a.html
But for different pages, same domain. (Each page has it's own operator)

Pic i showed above is strangely showing operator window inside embedded widget!

Last edited by caminomaster (2020-04-16 08:44:20)

Offline

#5 2020-04-16 08:43:24

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

Re: How to link widget with operator, same domain but different pages.

Hi caminomaster,
I think remdex for help you need to have steps to replicate what you are reporting.

You should also try to see if you are able to reproduce with the demo https://livehelperchat.com/demo-12c.html


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

#6 2020-04-16 08:45:06

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Well, once invitation is matched it's always kept the same. It was even in the old widget version.

If you want just to assign to different oprator once chat is started you can just pass operator id directly.

https://doc.livehelperchat.com/docs/jav … pt-options

Offline

#7 2020-04-16 08:55:59

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

These are two demo pages:
https://eos.caminomaster.co/agentes/mia/
https://eos.caminomaster.co/agentes/sara/
Each one has its own operator.

Visitor should be able to talk with each one separately,

Offline

#8 2020-04-16 09:00:19

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

Re: How to link widget with operator, same domain but different pages.

Page mia you create department mia assigned to mia operator than embed code and in department selection (embed code) you select only mia.
This embed code should be inserted in the mia page.

Follow the same process for the sara page by replacing all mia steps with sara.

If you generate embed code for a single department is no possible the widget chat load also in other page, i think.


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

#9 2020-04-16 09:01:28

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Hi,

Once chat session is started it continues page over page. That's intended behavior. As I see you are passing parameter which is fine pending chat should be assigned only to selected department/operator.

If you want that on page refresh session would be lost and new chat should be started you can just pass "fresh" parameter also you can find it in documentation.

Offline

#10 2020-04-17 08:36:35

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

Thanks to you for each reply.

I've checked my settings (there was a little dept. assignment error), re tested again, finding that:

  • Page embed code (legacy) works fine, each chat loads on it's own page/department at same time, as PeopleInside guessed. (both in v3.30 and v3.23, where it worked for me before).

  • But with Widget embed code (new) loads one chat across all pages.

Facts given, i can say it's a bug on new version, and i guess it can be fixed.

Last edited by caminomaster (2020-04-17 08:39:42)

Offline

#11 2020-04-17 08:40:03

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

Re: How to link widget with operator, same domain but different pages.

Hi, you maybe need the steps for reproduce the suspect bug.
Also be sure to be able to reproduce with the demo.

You need to demonstrate to remdex with the steps to replicate.


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

#12 2020-04-17 09:08:00

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

Steps to recreate issue:

Create departments A and B, each one:
    hidden: true,
    auto assignment active.
Create operators Ana - assigned to A, and Betty - assigned to B.

CASE A:
Generate page embed LEGACY codes:
    one with Ana, dept. A
    other with Betty, dept. B
Embed codes in pages of same domain.
-> Each one should work separated, at same time.

CASE B:
Generate same codes, but with NEW (React) option.
-> Same chat will load in every page.

(can't test it in demo, since there's no operator role available)

Last edited by caminomaster (2020-04-17 09:09:55)

Offline

#13 2020-04-17 10:31:36

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

Re: How to link widget with operator, same domain but different pages.

Thanks caminomaster,
I'M sure remdex will see and update you in the next days.

If there is a bug should be fixed or just reported on GitHub.
Have a nice day smile


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

#14 2020-04-17 11:50:20

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

It's intended behaviour and won't be changed. You can pass https://doc.livehelperchat.com/docs/jav … pt-options
fresh : true

And it won't save chat in cookie so each page will have it's own chat smile

Offline

#15 2020-04-20 11:54:41

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

Thanks, Remdex.

In fact, what we don't want is to lose chat on page refresh or tab close.

I'm glad to tell you i've achieved this through template, changing session storage vars smile
I changed cookie path too just in case, but it seems it prefers session over cookies... (in fact, all what i wanted could be achieved just using cookie path, for each page)

Last edited by caminomaster (2020-04-20 11:56:42)

Offline

#16 2020-04-20 12:12:52

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Hi,

That's not bad idea, perhaps need to add argument to javascritp options big_smile

Offline

#17 2020-04-20 13:15:36

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Implemented. See cookie_per_page per page argument smile

https://doc.livehelperchat.com/docs/jav … -arguments

Offline

#18 2020-04-22 12:48:54

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

That's nice  smile

Will it work just for v2 widget, or in embed legacy too?

Using legacy embed i've seen it uses sessionStorage instead cookies (maybe i'll need to set cookie time to make it persistent)

Last edited by caminomaster (2020-04-22 13:00:14)

Offline

#19 2020-04-22 14:10:48

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Only with new widget as argument is for new widget.

Offline

#20 2020-04-23 05:53:53

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

I've updated lhc to 3.33.

Now testing new widget with cookie_per_page:true but page reload resets chat. sad
Also, prefill field is getting data but hidden:true is not working. hmm

P.S: How can I add custom translation preventing it to be overriden on upgrade?

Offline

#21 2020-04-23 05:56:09

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

1. Make sure you have only one cookie on page lhc_per
2. In 3.33v there is now option to hide if prefilled for back office defined fields.
3. Read documentationhow to override templates
That's all I can help.

Offline

#22 2020-04-28 05:10:09

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

I want to allow this:

  • Visitor can start a chat even if department isn't online (e-mail not required)

  • when operator gets online, chat is already assigned to him, so he can reply to visitor. (assumimg visitor still have chat open)

What currently happens:

  • visitor sends message and gets a "Thank you for your feedback..." message

  • Operator has not pending chats when logged in, needs admin to transfer chat to him hmm

Last edited by caminomaster (2020-04-28 05:12:27)

Offline

#23 2020-04-28 05:26:15

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

Offline

#24 2020-04-28 05:57:46

caminomaster
Member
Registered: 2020-04-09
Posts: 24

Re: How to link widget with operator, same domain but different pages.

In fact i'm using operator id as js argument, but it doesn't work if operator offline, when he gets online has no messages pending nor assigned.

On the other hand, I want visitor to open chat anyway, getting chat open awaiting response, instead of getting a 'thank you' message. How can I achiveve this?

Offline

#25 2020-04-28 05:59:33

remdex
Administrator
From: Lithuania
Registered: 2012-09-23
Posts: 3,661
Website

Re: How to link widget with operator, same domain but different pages.

After this operator also should be assigned properly.
https://doc.livehelperchat.com/docs/dep … line-hours

Offline

Board footer