Warning: chmod(): Operation not permitted in /var/www/hopeinstoughton_www/wp-content/plugins/simple-universal-google-analytics/main.php on line 8
[0] in function chmod in /var/www/hopeinstoughton_www/wp-content/plugins/simple-universal-google-analytics/main.php on line 8
[1] in function include_once in /var/www/hopeinstoughton_www/wp-settings.php on line 560
[2] in function require_once in /var/www/hopeinstoughton_www/wp-config.php on line 85
[3] in function require_once in /var/www/hopeinstoughton_www/wp-load.php on line 50
[4] in function require_once in /var/www/hopeinstoughton_www/wp-blog-header.php on line 13
[5] in function require in /var/www/hopeinstoughton_www/index.php on line 17
403WebShell
403Webshell
Server IP : 94.177.8.99  /  Your IP : 216.73.217.165
Web Server : Apache/2.4.58 (Ubuntu)
System : Linux aries 6.8.0-134-generic #134-Ubuntu SMP PREEMPT_DYNAMIC Fri Jun 26 18:43:11 UTC 2026 x86_64
User : www-data ( 33)
PHP Version : 8.1.34
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /var/www/hopeinstoughton_www/wp-content/plugins/video-archive/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /var/www/hopeinstoughton_www/wp-content/plugins/video-archive/video-archive.js
function videoarchive_update($this, id, data) {
	let $ = jQuery.noConflict();
	let cc = $this.hasClass('ccap');
	let txt =	'Speaker: <b>' + data.n + '</b><br>'+
				'Date: <b>' + data.date + '</b><br>'+
				'Duration: <b>'  + data.len + '</b><br>'  +
				'<span class="bind-service" data-dt="' + data.date + '" data-tp="' + data.type + '"></span>';
	$('#summary').html(txt);
    if (data.hash) {
        $('div.videoupdate-container').html(
            '<div class="videoupdate-share">Share this video' + 
                '<div title="this link is only valid for 30 days">'+
                    '<img src="/~videoupdate/' + data.hash + '" width="80" height="80" data-pin-nopin="true" >' +
                    '<div class="caption"><a href="https://' + data.hash + '.stoughton.link">' + data.hash + '.stoughton.link</a></div>'+
                '</div>' +
				'<span style="color:#777;font-size:10pt">Link valid for 30 days</span>'+
            '</div>');
	}
	let $link = $('.bind-editlink');
	if ($link.length) {
		let src = $link.prop('href');
		let p = src.indexOf('cid=');
		if (p > -1) {
			$link.prop('href', src.substring(0, p) + 'cid=' + id);
		}
	}

	let $video = $('video.wp-video-shortcode').first();
	let player = $video.data('mediaelementplayer');
	let ht = player.height;
	
	for (let p in mejs.players) {
		try {
			mejs.players[p].media.stop();
		} catch(e) {
		}
		mejs.players[p].remove();
	}
//	if (!player.paused) player.pause();
//	player.remove();

	id = id.replace(':', '-');
	setTimeout(function(){
        let ccsource = false;
		$video = $('video.wp-video-shortcode').first();
        if (data.poster) {
            if (data.cc || 0) {
                ccsource = data.cap;
            };
            $video.attr('src', data.mp4);
            $video.attr('poster', data.poster);
        } else {
            $video.attr('src', 'https://media.hopeinstoughton.org/av/exhort/video/' + data.base + '.mp4');
            $video.attr('poster', '/thumbnail/' + id);
            if (cc) ccsource = '/av/exhort/vtt/' + data.base + '.vtt';
        }
		
		$video.find('track').remove();  // remove track tag (captions)
		if (ccsource) {
			$video.append('<track srclang="en" label="English" kind="subtitles" src="' + ccsource + '" />');
		}
		$video.mediaelementplayer();
		setTimeout(function(){
			var player = $video.data('mediaelementplayer');
			player.play();
		}, 0);
	}, 0);

}

function seekToTime(ts) {
	let $ = jQuery.noConflict();
	var $video = $('video.wp-video-shortcode').first();
	var player = $video.data('mediaelementplayer');
		// try and avoid pauses after seeking
		player.pause();
		player.currentTime = ts; // if this is far enough away from current, it implies a "play" call as well...oddly. I mean seriously that is junk.
		// however if it close enough, then we need to call play manually
		// some shenanigans to try and work around this:
		var timer = setInterval(function() {
			if (player.paused && player.readyState ==4 || !player.paused) {
				player.play();
				clearInterval(timer);
			}       
		}, 50);
}

function escape_xml(string) {
	return string
		.replace(/&/g, '&amp;')
		.replace(/</g, '&lt;')
		.replace(/>/g, '&gt;')
		.replace(/"/g, '&quot;')
		.replace(/'/g, '&apos;')
}

function _videoarchive_transcription(trans) {
	let output = '';
	for(let i = 0; i < trans.length; i++) {
		let entry = trans[i];
		let dtext = escape_xml(entry.t);
		output += `<a href="#" class="xp-waypoint ${entry.i}" data-wp="${entry.s}">${dtext}</a> `;
		if (entry.p) output += '<br /><br />';
	}
	return output;
}

function videoarchive_service() {
	let $ = jQuery.noConflict();
	$('span.bind-service').each(function() {
		let $this = $(this);
		$.ajax({
			type: 'POST',
			dataType: 'json',
			data: {
				service: $this.data('dt'),
				action: 'videoarchive',
				e: $this.data('tp'),
			},
			url: video_archive.ajaxurl,
		}).done(function(data) {
			let html = '';
			if (data && data.ref && data.link) {
				html += 'Reading: <a href="' + data.link + '#' + data.ref_start + '" target="_service"><b>' + data.ref + '</b></a><br />';
			} else if (data && data.ref) {
				html += 'Reading: <b>' + data.ref + '</b><br />';
			}
			if (data && data.link) {
				html += 'Entire Service: <a href="' + data.link + '" target="_service"><b>here</b></a>';
			}
			$this.html(html);
			if (data && data.transcript) {
				html = _videoarchive_transcription(data.transcript);
				$('#transcription').html(html);
				$('.xp-transcript').show();
				var $video = $('video.wp-video-shortcode').first();
				mediaWaypoints($, $('.xp-transcript'), $video);
			}
		});
	});
}

jQuery(document).on('click', 'a.videoselect', function(event) {
	event.preventDefault();
	let $ = jQuery.noConflict();
	let $this = $(this);
	let ds = this.dataset;
	let id = $this.closest('li').attr('id');
	$.ajax({
		type: 'POST',
		dataType: 'json',
		data: {
			id: id,
			action: 'videoarchive',
		},
		url: video_archive.ajaxurl,
	}).done(function(data) {
		videoarchive_update($this, id, data);
		videoarchive_service();
	});

}).on('click', 'a.audio-waypoint', function(e) {
	let $ = jQuery.noConflict();
	e.preventDefault();
	let $this = $(this);
	let ts = parseFloat($this.data('ts'));
	seekToTime(ts);
});


Youez - 2016 - github.com/yon3zu
LinuXploit