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

Undefined vars preventing passport video #8

Open
bymoulton opened this issue Jun 22, 2018 · 3 comments
Open

Undefined vars preventing passport video #8

bymoulton opened this issue Jun 22, 2018 · 3 comments

Comments

@bymoulton
Copy link

In the file build-passport-player.php, on line 26, are two undefined vars, PASSPORT_ENABLED and $coveWindow. They appear to be placeholders for if the user is a member or not, but are never actually set anywhere.

@tamw-wnet
Copy link
Collaborator

Hey @bymoulton -- that's really sample code that you'd add to your theme and customize as necessary, but here's what to do with them -- PASSPORT_ENABLED would want to be TRUE, and $coveWindow would be the derived value you'd get from the Media Manager API for the asset record -- a value of 'public', 'all_members', or 'station_members'. If you take a look at https://github.com/tamw-wnet/pbs-media-manager-wordpress I have a function in the main class, derive_asset_availability_from_asset_data(), that will do that derivation for you.

@tamw-wnet
Copy link
Collaborator

I really need to go and do more to document that script better and clean out stuff that refers to very site-specific code I have. It wouldn't be a big job at all to fix it to better refer to the object info we get directly from the Media Manager API.

@tamw-wnet
Copy link
Collaborator

@bymoulton I've added a file to the pbs-media-manager-wordpress plugin that should mostly get you a working passport player. See build-media-manager-video-player.php -- the function has NOT been tested but I think it should be pretty close.

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

2 participants