hello,
I am new to php and apache..any help is appreciated.

I am designing a music website..I am designed the music player with flash.I have xml file like this where my flash player play the songs from the url..I have a folder named songs.

<song>
<track>Princess Song</track>
<artist>Artist Two</artist>
<url>songs/princess.mp3</url>
</song>

My document root folder is public_html(web accessible directory)

I have to restrict the download of my songs direct from http and have to prevent to downloading the songs.

if i move the songs folder outside the public_html folder,.for example /root/songs

<song>
<track>Princess Song</track>
<artist>Artist Two</artist>
<url>/root/songs /princess.mp3</url>
</song>

whether my flash player works or not?.`

how to config the .htaccess file to provide access for the xml file to play the songs outside the document root or public_html accessible directory.

else

I am placed the flash player in Iframe..whether it possible to move the flash player outside the document root or public_html accessible directory and provide the path in home.php access the flash player.

how to config the .htaccess file to provide access to the flash file outside the document root or public_html directory?.

Thanks a lot..

with regards,
Eswaran Saravanan,
University west
sweden.

Recommended Answers

All 4 Replies

the .htaccess file won't be read by apache outside the document root. if your just trying to restrict access, you could use authentication, not sure if you could get flash to work with that though.

generally, you put something outside the document root that you don't want the web to have access to, but it seems like you want it to be web accessible?

hello thanks for your reply,

Any suggestion to restrict the download of my songs direct from http and have to prevent to downloading the songs.If i kept the songs folder inside the web accessible directory,they can easily download the songs.In apache how can I restrict the access of download.

Thanks a lot,

with regards,
Eswaran Saravanan,
University west
sweden.

Thanks a lot for your kind reply..

with regards,
Eswaran Saravanan,
University west
sweden.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.