Hi, I am trying to display file on a website simply using the preview like this:
<div class="preview-container"></div>
<script>
var preview = new Box.Preview();
preview.show("FILEID", "DEVELOPER_ACCESS_TOKE", {
container: ".preview-container",
});
</script>
Using the developer access toke works great, but it has a 60minute ligfe span, so I found this page which is about creating a JWT, so I implemented it and it creates a code as $access_code
but its super long and therefore doesn’t work with the previewer when using like this:
<div class="preview-container"></div>
<script>
var preview = new Box.Preview();
preview.show("FILEID", $access_token, {
container: ".preview-container",
});
</script>
Any idea what I am doing wrong?