a project by: José Manuel Blasco Galdón
ytCropper, the javascript library to crop YouTube videos inside your website. It is an opensource project, so you can feel free to download it, change it and use it.
Download
Getting handle values

The ytCropper library has methods to obtain the handle values. The library has also one method that returns a embed YouTube video link prepared to play the interval specified in the cropper.

- ytCropper::getInitialValue()
Returns the first handle value in seconds (the first interval value).

- ytCropper::getFinalValue()
Returns the second handle value in seconds (the last interval value).


Example:
$("#generateButton").on("click",function(e)
{
        // Prevent the default behaviour of a tag
	e.preventDefault();
        // Obtain the first value and put it into #firstInput
	$("#firstInput").val(cropper.getInitialValue());
        // Obtain the first value and put it into #secondInput
	$("#secondInput").val(cropper.getFinalValue());
        // Obtain the embed link and put it into #generatedCode
	$("#generatedCode").val(cropper.getEmbedLink());
});


This code means that, when the generateButton is pressed, changes the #firstInput, #secondInput and #generatedCode with the first handle value, second handle value and embed YouTube link.

You can test it here: http://jsfiddle.net/BxQhy/11/


More information about this plugin on this wiki.


José Manuel Blasco Galdón, 10/04/2014