Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 15th, 2005, 02:49 PM
Authorized User
 
Join Date: Mar 2004
Posts: 74
Thanks: 0
Thanked 0 Times in 0 Posts
Default ENCODING DECODING

Hi all,
I have my video file names stored in database table. when i load page i show them as a link. I have also set up windows media server where i store the actual files and once clicked on the link, serve the video to the user.
the code is like
<asp:HyperLink NavigateUrl="mms://myServerName/FolderName/V1.wmv"
Runat="server" id="HyperLink1">watch video</asp:HyperLink>

what i don't want is i don't want to show user the the actual file name on the status bar when they point cursor to link, instead i want to encode the url. i tried it, it fails to load video on Media Player.

Your help or chunk of code is appreciated
 
Old October 15th, 2005, 05:59 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

What exactly do you think you mean with "encode the url"?

What do you want to show on the status bar??

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
 
Old October 16th, 2005, 11:55 PM
Authorized User
 
Join Date: Mar 2004
Posts: 74
Thanks: 0
Thanked 0 Times in 0 Posts
Default

What i meant by encoding URL is i don't want users to see the actual file name or file path in status bar.

your help would be appreciated
 
Old October 17th, 2005, 01:41 AM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

You can't hide the link to the file directly; after all the browser needs to know which fie to download.

You could clear the status bar when the mouse hovers over the link so you can't directly see what file it is linking to. However, a simple right-click on the link, or View Source will reveal the link anyways.....

A better alternative might be to have a generic download page, like Download.asp that accepts the Id of a file users can download. Inside that file, look at the Id, find the related file and stream it to a browser. Take a look here for some ideas on how to do this:

http://Imar.Spaanjaars.Com/QuickDocId.aspx?QUICKDOC=189

This still doesn't really hide the file name though. Download.asp?Id=123 will always get you the same file though....

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.





Similar Threads
Thread Thread Starter Forum Replies Last Post
code for decoding a binary dat file myth.12887 C++ Programming 2 May 18th, 2007 09:40 PM
encoding paarupalli J2EE 0 March 2nd, 2007 04:14 AM
Decoding Base64 Encoded Data and saving the image mookashi XML 14 August 3rd, 2006 05:52 PM
encoding alihussein3 Javascript How-To 1 October 28th, 2003 05:23 AM
decoding encoding starsol Beginning PHP 2 June 29th, 2003 08:01 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.