discordjs-youtube-tutorials
discordjs-youtube-tutorials copied to clipboard
Transcript Bot html embed
The transcript bot creates the html file all fine.
The transcript bot works fine in my server, was wondering if the bot could create a HTML of a channel in the channel itself after the channel has been closed?
You must fetch the messages of that channel.
Then create basic HTML file code (In a Javascript String or something) then add those messages in the body
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>HTML Transcript</title>
</head>
<body>
<div class="container">
<div id="MESSAGE_ID">
<span id="author">Arthur</span>
<span id="content">Text message etc etc</span>
</div>
</div>
</body>
</html>
You should add those messages dynamically
So you should create an array where the html code (for only messages) and map that array into the HTML String