I am trying to extract a videolink from a streaming website.
So I use PHP and "file_get_contents" to open the videolink and then "explode" to find the link to the generated link
Its looks like config5/videoid/generatedhash/ but you can access it also with config5/videoid/
So when I open this link I see this:
document.write('<div id="mediaspace2" style="width:880px;height:495px">');
jwplayer.key="key";
document.write('<div id="mediaspace" itemprop="video"></div>');
var scrwid=window.screen.width;
var def=false;
if(scrwid<1200) def=true;
jwplayer("mediaspace").setup({
sources: [{
file: "http://linkto.mp4",
label: "1080p HD",
type: "mp4"
}
,{
file: "http://linkto.mp4",
label: "720p HD",
type: "mp4",
} ,{
file: "http://linkto.mp4",
label: "360p",
type: "mp4",
"default": def
}
and a lot more stuff
when i copy one link of my choice and open it in chrome everything is fine. but when i try to embed it with html5 video tags it opens a file named na.flv
ist like a security for the website
how can i decrypt it? :/
Related
When running an application that is built using webpack 2, sourcemaps are detected in chrome but original source is not loaded.
I'm using webpack beta21.
These files used to be detected automatically, ie when a breakpoint was put in the the output from webpack js file, the source view would jump to the original source input to webpack. But now I am stuck with this screen:
config:
var path = require("path");
var webpack = require("webpack");
var WebpackBuildNotifierPlugin = require('webpack-build-notifier');
const PATHS = {
app: path.join(__dirname, '../client'),
build: path.join(__dirname, '../public')
};
module.exports = {
entry: {
app: PATHS.app + '/app.js'
},
output: {
path: PATHS.build,
filename: '[name].js'
},
devtool: "source-map",
module: {
loaders: [
{
test: /\.js?$/,
loader: 'babel-loader',
include: [
path.resolve(__dirname, 'client'),
],
exclude: /node_modules/
},
{
test: /\.css/,
loader: "style!css"
}
]
},
resolve: {
// you can now require('file') instead of require('file.js')
extensions: ['', '.js', '.json']
} ,
plugins: [
new WebpackBuildNotifierPlugin()
]
};
Generated files with source maps won't automatically redirect to their original files, because there's potentially a 1-to-many relationship.
If you see the message Source Map Detected, the original file should already appear on the side file tree or the file explorer via Crl + P. If you don't know the original file name, you can open the source map file itself.
The source map path can be identified by a //# sourceMappingURL= comment or the X-SourceMap header:
Open up the source map via url and look for the sources property for the original file name:
The original file should be visible in the sources panel:
If you don't see the message Source Map Detected
You can manually add an external source map by right clicking and selecting Add Source Map:
Additional Resources
If that still doesn't work, you can try a Source Map Validator
For webpack specifically, you can configure the devtool property
If you're mapping to a workspace, that means you already have the source code. Including the source code in your source map is creating an unnecessary redundancy.
Use nosources-source-map instead.
The issue with external source maps was fixed in Chrome 52 but it looks like you've got your devtool set differently from mine, I use:
devtool: '#source-maps'
How are you building your source? If you're running with -d it will switch to inline source maps
After downloading a page from the web using HTTP, this Meteor server code using "email 1.1.16 package" sends that page over to my email successfully but I receive the row html string.
It is a report which I wish to view and maybe print, it would be nice if it is a pdf attachment so that I can just click to open it, or be able to view the page in a different tab.
how can I go about fixing this problem? Thanks
Email.send({
to: "abc#xyz.com",
from: "aaa#bbb.com",
subject: "My report",
text: rowHtml
});
edit
After ready Vasil's answer, the Blaze.toHTML "Renders a template or View to a string of HTML".
But I already have a html string, why do I need to convert it to html string again?.
var html = Blaze.toHTML(Blaze.With(data, function() { return Template.my_template; }));
Email.send({
to: "abc#xyz.com",
from: "aaa#bbb.com",
subject: "My report",
text: html
});
Using dynamic HTML templates in Meteor emails
All what I had to do is to change the line text: rowHtml to html: rowHtml according to the docs
Email.send({
to: "abc#xyz.com",
from: "aaa#bbb.com",
subject: "My report",
html: rowHtml
});
I run crouton on my chromebook and use the Crosh shell pretty frequently. Is there any way to specify Crosh as the default New Tab on a Chromebook?
I already attempted using the Crosh extension location as the New Tab URL (chrome-extension://pnhechapfaindjhompbnflcldabbghjo/html/crosh.html) but no luck.
Do you have your own extension? If not create it, with a manifest.json file like this:
{
"manifest_version": 2,
"name": "Crosh Newtab",
"version": "1",
"chrome_url_overrides" : {
"newtab": "main.html"
}
}
Create main.js and add it to main.html. In main.js, open Crosh and close the current window, like this:
chrome.tabs.create({
url: "chrome-extension://pnhechapfaindjhompbnflcldabbghjo/html/crosh.html"
}, function() { window.close() })
doesn't answer your question directly, but you could bookmark the crosh URL and pin it to your taskbar, then access it using shortcuts like Alt+3 (where "3" is the 3rd icon in the taskbar).
I'm working on an app written using Polymer components and was working on automating some of the unit tests for our custom components. Ideally I'd like to be able to have something like
files: [
'public/js/bower/platform/platform.js',
'node_modules/sinon/pkg/sinon-1.10.2.js',
'public/components/*.html',
{pattern: 'public/components/*.js', included: false, served: true},
{pattern: 'public/js/bower/**', included: false, served: true},
{pattern: 'public/js/*.js', included: false, served: true},
'test/components/polymer-*-tests.js'
],
in my karma.confg.js file, so that it loads any components and tests we add in the future without having to manually add them. However, while this correctly results in <link rel="import">s for all of the components in the components folder, only the first is being properly registered by Polymer (tests for the rest are all failing). If I manually add each component to the list, such as:
files: [
'public/js/bower/platform/platform.js',
'node_modules/sinon/pkg/sinon-1.10.2.js',
'public/components/poly-component-1.html',
'public/components/poly-component-2.html',
'public/components/poly-component-3.html',
{pattern: 'public/components/*.js', included: false, served: true},
{pattern: 'public/js/bower/**', included: false, served: true},
{pattern: 'public/js/*.js', included: false, served: true},
'test/components/polymer-*-tests.js'
],
then everything works fine. I've also gotten it to work if I add something similar to
var link = document.createElement('link');
link.rel = 'import';
link.href = 'base/public/components/<component-name>.html;
document.getElementsByTagName('head')[0].appendChild(link);
at the beginning of each test file, or creating a bootstrap script with
components = [
'polymer-component-1',
'polymer-component-2',
'polymer-component-3'];
for (var i = 0; i < components.length; i++) {
var link = document.createElement('link');
link.rel = 'import';
link.href = '/base/public/components/' + components[i] + '.html';
document.getElementsByTagName('head')[0].appendChild(link);
}
and making sure karma loads it before the tests. However, these three solutions all involve manual edits of files (or remembering to include some boilerplate at the beginning of test files that isn't normally there).
Does anyone have any ideas as to why using the wildcard pattern seems to not be working? Karma does appear to be adding the html imports properly to the context iframes, and the html and js files for the components are being loaded into the browsers. The components just seem to not be registering.
Not sure what error message looks like when you said "tests for the rest are all failing".
However, I personally found something similar, but I nailed it down to the problem that karma could possibly include my html twice. See the issue I logged it to karma-runner project for more info.
Is it possible to create an open-graph url for object which is not a www url? Like for network drive location for example?
I tried it and the embed feed seems to only load for www urls.
Here are my questions:
Is it possible to not use a normal www url for the object?
Where is the documentation what different config options are available for the open-graph?
Where is the documentation for the objectProperties config? I'd like to provide all of them manually and disable the system which tries to fetch them through embed.ly or what ever.
This works fine:
yam.connect.embedFeed({
container: "#embedded-feed",
network: "m-files.com",
feedType: "open-graph",
objectProperties: {
url: "https://www.microsoft.com",
type: "file",
title: "Yammer.pdf"
}
});
But for example this doesn't:
yam.connect.embedFeed({
container: "#embedded-feed",
network: "m-files.com",
feedType: "open-graph",
objectProperties: {
url: "\\192.168.1.8\Something\somefile.pdf",
type: "file",
title: "Yammer.pdf"
}
});