Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how to enable withcredentials for sending local cookies to server? #46

Open
hasnainshafqatmlt opened this issue Feb 4, 2022 · 0 comments

Comments

@hasnainshafqatmlt
Copy link

hasnainshafqatmlt commented Feb 4, 2022

Hi Team

I'm looking for a small help about enabling the cookies thing in video.
As like other 3rd party plugins for sending request to server e-g Axios
we do withCredentials: true and it automatically send local browser cookies to server.

I'm curious how I can enable that functionality in theoplayer configuration so that when it sends request to server then local cookies should be sent in headers automatically.

my code example is
function videoOptions (videoUrl: string, videoType?: string) => { return { source: { sources: [ { type: videoType || 'application/x-mpegurl', src: videoUrl } ] } } }

const player = window.THEOplayer && new window.THEOplayer.Player(this.$refs.theoplayer, { fluid: true, libraryLocation: '//cdn.theoplayer.com/dash/theoplayer/', license: 'abc', allowNativeFullscreen: true, mutedAutoplay: true, useCredentials: true }) player.source = this.options && this.options.source;

<TheoPlayer :options="videoOptions('www.abc_file.mp4')" :full-screen='true' :autoplay='true' />

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant