Hi,
I try to find a way to extract mp4 content received and manipulated by the browser.
I need to extract it without make a new call to the server. I try to use the devtools.network API.
Inside the onRequestFinished event, I call the function getContent to get the content.
The problem is the value I got is always null and I don't know why...
Thank for your help, here my code :
chrome.devtools.network.onRequestFinished.addListener(
function(request) {
if(request.response.content.mimeType == "video/mp4" &&
request.getContent(function(content){
if(content == null) {
console.log("Why content is null! :( ... and my content size is suppose to be :");
console.log(request.response.content.size);
}
sendFileToMyOwnServer("video123.mp4", content);
});
}
}
);
function sendFileToMyOwnServer(title, content) {
type: 'POST',
contentType: 'video/mp4',
data: content});
}