How do I customize the Bot Framework Web Chat title? [duplicate]

随声附和 提交于 2021-01-29 05:31:39

问题


I embedded the WebChat in a demo page and copied the CSS file, but I don't knwo wehre to change the title of the webchat?

<link href="BotStyle.css" rel="stylesheet" />
<div id="BotChatGoesHere"></div>

<script src="https://cdn.botframework.com/botframework-webchat/latest/botchat.js"></script>

<!-- If you do not want to use Cognitive Services library, comment out the following line -->
<script src="https://cdn.botframework.com/botframework-webchat/latest/CognitiveServices.js"></script>

回答1:


You could use javascript or jquery to programmatically change the text. Either

document.getElementsByClassName("wc-header")[0].innerHTML = "<span>Chat</span>";

or

$(".wc-header span").innerText = "Hello";


来源:https://stackoverflow.com/questions/52534169/how-do-i-customize-the-bot-framework-web-chat-title

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!