Skip to content

Instantly share code, notes, and snippets.

Zohar Babin zoharbabin

Block or report user

Report or block zoharbabin

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View kaltura-simple-js-image-upload.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
</head>
<body>
<input type="file" id="uploadfiles" accept="*.*" multiple />
<progress id="uploadprogress" style="display: none;" value="0" max="100"></progress>
<script>
View addurl.py
resource = KalturaUrlResource()
resource.url = "https://www.youtube.com/watch?v=cPAbx5kgCJo"
result = client.media.addContent(entryId, resource)
View addcontent.py
resource = KalturaUploadedFileTokenResource()
resource.token = tokenId
mediaEntry = client.media.addContent(mediaEntry.id, resource)
View upload.py
fileData = open('IMG_9227.m4v', 'r')
result = client.uploadToken.upload(tokenId, fileData)
View createtkn.py
uploadToken = KalturaUploadToken()
result = client.uploadToken.add(uploadToken)
tokenId = result.id
View createtoken.py
uploadToken = KalturaUploadToken()
result = client.uploadToken.add(uploadToken)
tokenId = result.id
View addentry.py
entry = KalturaMediaEntry()
entry.mediaType = KalturaMediaType.VIDEO
entry.name = "Sample Video"
entry.description = "yet another sample video in my arsenal"
mediaEntry = client.media.add(entry)
View startsession.py
from KalturaClient import *
config = KalturaConfiguration(<PARTNER ID>)
client = KalturaClient(config)
ks = client.session.start(
<ADMIN SECRET>,
<YOUR EMAIL ADDRESS>,
KalturaSessionType.ADMIN,
<PARTNER ID>
)
@zoharbabin
zoharbabin / lazyloadkaltura.html
Created Jul 11, 2019
Lazy load many Kaltura videos sample reference
View lazyloadkaltura.html
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<style>
* {
box-sizing: border-box;
}
You can’t perform that action at this time.