Can I play iTunes song previews in an HTML page? - javascript

I need to show on my site search results from the iTunes Store, including previews of audio tracks.
I could use the iTUnes search api to return JSON info with cover image, title and other info. But for previews url I have problems (like following http://a5.mzstatic.com/us/r1000/007/Music/2f/18/8c/mzm.dsmmvsnn.aac.p.m4a).
It is not direct link to file but to some streaming server (not sure it is RTSP, network sniffer shows some other). It could not be dowloaded directly by browser, flash and HTML5 players don’t support it, and it couldn't be opened even using QuickTime Player. So I haven't found any way to embed it to site web page like I do for regular audio/video links.
The only program that could open such urls is iTunes. But as far as I could see it couldn't be used as embed/object in browser/web page.
Any ideas how it could be implemented?

As far as I understand iTunes not allows previews to be played for countries with no iTunes store.
So preview plays in Itunes application and not in quick time or any other player. So such case really difficult to catch (if it will not play in itunes app it will be clear and easy to detect, but in this case not).
After using proxy or just testing from other location all become working. And could be integrated using many flash players.

Related

I would like to create a music website like mp3 juice/mp3 paw

I want to to create a website that fetch data from YouTube when you search from it in away that any data uploaded to YouTube you can search it in that webapp and find it be available for streaming or downloading more like the way mp3 juice is or tubidy
I tried different codes, online search but I didn't find anything helpful the best I could get was and I coded it was a link pasting site where you paste the URL of the video then it downloads...I want something that people can just search and have there search displayed there any help is very much appreciated (from any language)
If you are looking to create a website that fetches data from YouTube, you will need to use the YouTube API. The YouTube API allows you to search for videos, retrieve video information, and embed videos in your website. You can find more information about the YouTube API here: https://developers.google.com/youtube/v3/getting-started.
Once you have set up the API, you will need to create a web application that can make requests to the YouTube API and display the results. You can use any language you are comfortable with, such as JavaScript, PHP, or Python.
You will also need to create a user interface for your website, which will allow users to search for videos and view the results. You can use HTML, CSS, and JavaScript to create the user interface.
Finally, you will need to create a way for users to stream or download the videos they find. This will require you to create a streaming or download service, which can be done using a variety of technologies, such as HTML5, Flash, or a third-party service.
Good luck!

Preventing user to see video URL in HTML?

I have an web page where users can view videos.
But the problem is when I inspect the page, it shows the video url.
So is there any idea how we can hide video source like youtube and other videos portal ?
There is no way to hide the video URL entirely without resorting to browser plugins. You can obscure it though, but in most cases they won't be worth it.
Using Media Source Extensions you can deliver segments of video data using obscured urls. And the URL won't be immediately visible in the source of the page. This is similar to what Youtube or Netflix does but requires massive engineering work on the backend. This is also the technique used to play MEPG-DASH with e.g. dash.js or shaka-player.
Set it using Javascript, so it's not viewable with view source, it won't help with inspecting though.
If your issue is people copying the stream URL and using it in their own players, then you might look at protecting it with some sort of tokens security. This is supported by almost any CDN out there, and there are plenty of open source systems to do it in most programming languages.
Lastly, if the issue is that you don't want anyone to copy the content, you can apply DRM protection. One of the easiest and straightforward ways to get started with that, might be using Azure Media Services.

chrome extension: how to mute all audio from certain tab

I have been searching for something in chrome extension reference to find anything that would allow me to manipulate audio level of a tab. Only option that has come to my mind is make script have it go through all elements in page and either remove them or mute them if possible.
But i feel there has to be a way to reroute all audio streams to nothing, like break them from output which is speakers if using audio api of html5...however no avail either with chrome extension apis or web audio api.
Goal: mute all sounds on page (flash, audio element, etc.)
You cannot do this now, although this will hopefully change in the near-term future.
At the moment, there is nothing in the Chrome APIs, although I did propose a tabaudio API back in February (and am working on a new draft -- as well as an implementation -- right now.)
Can you give me an idea as to what you want this functionality for? (They ask for potential uses when proposing APIs.)
Perhaps the closest that you can do is something similar to what the MuteTab Chrome extension does (written by me, http://www.github.com/jaredsohn/mutetab), which basically scans the page for object, embed, audio, video, and applet tags and hides them from the page. Unfortunately, this misses web audio. Also, instead of muting, it "stops" it by removing it from the page, which could block the video or game associated with the sound. Alternatively, if you just care about HTML5 video or audio or Flash that has an API (such as YouTube), you could could use JavaScript to pause or mute things.
There's now a Chrome extension allowing to mute websites by URL using blacklist/whitelist approach called "Mute Tabs by URL".
It does require you to allow it to read your 'browsing history', but description swears that it doesn't store your URLs anywhere, and event points to a location of source code, so you can verify it for yourself

HTML5 - play a video from web url but for security reason do not allow to download or copy the url

I have a BANK video file, and the file is confidential so they only give the link to a customer who can open it in Google chrome browser just to watch the video.
But that customer can only view it
(cant easily download it, or copy the main video link)
How to do that?
i tried but its very easy for anyone to copy the video URL how do you hide those and lock those?
You cannot. There are currently no DRM features for HTML 5 video (not that DRM features are all that effective anywhere that has implemented them).

javascript to discover .flv url from any embedded flash video?

Is there any javascript library out there that can find the url to the flash video file (.flv) on current page where it has an embedded flash video player? Ex. opens collegehumor.com video link, shows flash video url.
I have been looking through codes from chrome extensions which discovers flash video links for download but no dice.
Browser extensions can look into Flash internals and monitor your HTTP activity to see where data is being pulled from, however Javascript running in the document does not have permission to read either of those.
Some Flash apps expose some of their internals to Javascript, but they need to specifically write in that functionality, and for third parties this would be documented, presumably as an API. As far as I can tell, collegehumor doesn't provide any of that.

Categories

Resources