I have soundmanager2 as player for mp3 sounds.
When I loading .swf file from same server as webapp its playing mp3 files normally
When I load .swf file from another server its not okay
The only change i added is:
soundManager.setup({
url: 'http://s3.amazonaws.com/mybucket/swf/'
})
In firebug>Net bookmark i can see that swf loaded but no mp3 load (when i click play in site)
I added crossdomain.xml but this not helped.
Worked according to this sample: http://www.schillmania.com/projects/soundmanager2/doc/getstarted/
Assume my webapp running locally at: http://local.dev
and swf served in another localapp running under http://local.media
so when i do:
url: 'http://local.media/swf/'
from local.dev app, its not loading nor playing.
Even for amazon it has to have crossdomain.xml :-\ even if i managed ACL well
Related
I'm trying to find a solution for forcing audio files to download on mobile using PHP.
I tried using the MIME type 'AddType audio/mpeg .mp3' in my .htaccess file to no effect. Direct downloads work fine on desktop but not on mobile - it always redirects to the default Wordpress player to download instead of just downloading after clicking the link.
I've searched various solutions and this is the closet I got Forcing to download a file using PHP
My files are hosted outside of my domain. This is the PHP file I'm using but it's not working.
$file_name = 'file.mp3';
$file_url = 'https://mcdn.podbean.com/mf/web/' . $file_name;
header('Content-Type: audio/mpeg');
header("Content-Transfer-Encoding: Binary");
header("Content-disposition: attachment; filename="my-file.mp3");
readfile($file_url);
exit;
These files are hosted with another provider on another domain. Nothing you can do will force the direct download unless they were hosted on a platform like AWS where you can create your own bucket and link it to your domain. That's costly.
Podbean suggested I change "web" in the podcast URL to "download." I used the Find and Replace All Wordpress plugin and it automatically changed them all. Just make sure you search for whatever proceeds the word you want to change so you don't replace a common word like "web" elsewhere in your database.
Always backup your database before making mass changes.
With over 800 episodes it worked perfectly after clearing the cache.
My website has some of its files temporarly saved in the web browser cache.
Concerning CSS and images files, no problem but for some files it's a real security issue.
Is there a way to prevent some files from :
- being downloaded from the cache ?
- being visible in the cache ?
or crypt them maybe
Thanks.
David
Well you can configure your webserver so it sends certain http headers for certain file types such as javascript. For example for Apache web server we can use mod_expires module.
Another option is to add a random string to the end of each file that should not be cached by the web browser. for example the file script_name.js can be server as script_name.js?somerandomstring
I'm using IIS to serve mp4 videos. I get a 404 on mac/safari. It works in chrome and firefox on the same macs. The MIME is video/mp4 .
I've ran tests locally to rule out the video encoding, and the videojs. I've taken the request path directly as well, skipping the html and js, with the same results. Safari will not load the direct url to the video either.
I'm not sure where to look next?
It turns out Safari does range requests for media. IIS itself can handle this, but we are using mvc routing - and we didn't provide any handling for this. The solution is to build an action result that handles range request. We're pulling a solution based on this article
I'm using Orchard 1.7.2. I created widget with MediaPickerField for video file. On the front-end i trying to get this video by url (../Media/Default/Video/video.mp4) and play it using html5 video player. But i get 404 error when trying to load it. I tried fix it like here but after that i get 500 error. I got this errors only on video files and only on server. On local machine everything working fine.
Well, i fix it by adding MIME Type on IIS. There were no mime type for mp4. So i added .mp4 extension and video\mp4 mime type.
Similiar question: https://stackoverflow.com/questions/22311597/get-vk-video-direct-links-on-client-side-ip-html5
VK.com is a Russian social network sites which also allows you to host videos. They allow you to embed their videos but because of their cross-domain policy, you can't use ajax/flash requests to get the video page on the client side. However, this swf file does that without loading a cross-domain file? (I sniffed the network traffic, it seems as if the flash file doesn't request a crossdomain.xml file but rather directly load the vk.com page http://vk.com/video_ext.php?oid=196471971&id=167752304&hash=9fd63185df970616)
The URL for the swf file is
http://www.jethdfilmizle.com/veka.swf?file=vk.com%2Fvideo_ext.php%3Foid%3D189406059%26id%3D163663575%26hash%3D388c8150742ccb2f&otobaslat=0
Can anybody explain how this works?