473,386 Members | 1,803 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Presenting MOV-files and images from a DB

I'd like to build up a HTML-document using
a database BUT the tricky part is that one
of the elements is a MOV-file. The other
three, four are GIF-files.

Is such data storable in a database at
all? Or would it be more suitable to
create dynamic anchors to a directory
where all the MOV's and GIF's are put?

I'm imaging that when a request like:
http://localhost/fileID_A3DF.aspx
is issued, the document created will be
something like:

<other stuff>
<img src="A3DF.gif>
<embed src = "A3DF.mov" height = 135
width = 155></embed>
<other stuff>

I'm assuming that a part of the file name,
namely "fileID_A3DF.aspx", can easily be
extracted and its four last characters
used as an in-parameter, i.e. "A3DF" in a
call to a database.

Please comment if you can suggest any
improvements to that approach.

--
Regards
Konrad Viltersten
--------------------------------
sleep - a substitute for coffee for the poor
ambition - lack of sense to be lazy

Jun 27 '08 #1
6 936
"K Viltersten" <tm**@viltersten.comwrote in message
news:67*************@mid.individual.net...
I'd like to build up a HTML-document using a database BUT the tricky part
is that one
of the elements is a MOV-file. The other three, four are GIF-files.
OK.
Is such data storable in a database at all?
Yes,
Or would it be more suitable to create dynamic anchors to a directory
where all the MOV's and GIF's are put?
"Suitable" is perhaps the wrong adjective... There are arguments both for
and against storing binary files in databases. I tend to avoid doing it, but
that's just a personal preference...
I'm assuming that a part of the file name,
namely "fileID_A3DF.aspx", can easily be
extracted and its four last characters used as an in-parameter, i.e.
"A3DF" in a
call to a database.
http://msdn2.microsoft.com/en-us/lib...extension.aspx
http://msdn2.microsoft.com/en-us/lib...substring.aspx
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #2
If you feel you must store the object in the database, you can set up a http
handler which will stream the data back to the HTML page, this is fairly
easy to do.

"Mark Rae [MVP]" <ma**@markNOSPAMrae.netwrote in message
news:OC*************@TK2MSFTNGP02.phx.gbl...
"K Viltersten" <tm**@viltersten.comwrote in message
news:67*************@mid.individual.net...
>I'd like to build up a HTML-document using a database BUT the tricky part
is that one
of the elements is a MOV-file. The other three, four are GIF-files.

OK.
>Is such data storable in a database at all?

Yes,
>Or would it be more suitable to create dynamic anchors to a directory
where all the MOV's and GIF's are put?

"Suitable" is perhaps the wrong adjective... There are arguments both for
and against storing binary files in databases. I tend to avoid doing it,
but that's just a personal preference...
>I'm assuming that a part of the file name,
namely "fileID_A3DF.aspx", can easily be
extracted and its four last characters used as an in-parameter, i.e.
"A3DF" in a
call to a database.

http://msdn2.microsoft.com/en-us/lib...extension.aspx
http://msdn2.microsoft.com/en-us/lib...substring.aspx
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #3
You might want to look at the VirtualPathProvider class and concept. This
allows you to serve an ASP.NET web site from a database, or even from a ZIP
file.

-- Peter
To be a success, arm yourself with the tools you need and learn how to use
them.

Site: http://www.eggheadcafe.com
http://petesbloggerama.blogspot.com
http://ittyurl.net
"K Viltersten" wrote:
I'd like to build up a HTML-document using
a database BUT the tricky part is that one
of the elements is a MOV-file. The other
three, four are GIF-files.

Is such data storable in a database at
all? Or would it be more suitable to
create dynamic anchors to a directory
where all the MOV's and GIF's are put?

I'm imaging that when a request like:
http://localhost/fileID_A3DF.aspx
is issued, the document created will be
something like:

<other stuff>
<img src="A3DF.gif>
<embed src = "A3DF.mov" height = 135
width = 155></embed>
<other stuff>

I'm assuming that a part of the file name,
namely "fileID_A3DF.aspx", can easily be
extracted and its four last characters
used as an in-parameter, i.e. "A3DF" in a
call to a database.

Please comment if you can suggest any
improvements to that approach.

--
Regards
Konrad Viltersten
--------------------------------
sleep - a substitute for coffee for the poor
ambition - lack of sense to be lazy

Jun 27 '08 #4
You might want to look at the VirtualPathProvider class and
concept. This allows you to serve an ASP.NET web site
from a database, or even from a ZIP file.
Thanks for the help. I'd like to get a clarification on a part of
it, though. Which of the following two approaches would be
more suitable, would you say?

1. To distract the key for DB from the file name.
http://localhost/fileID_A3DF.aspx

or

2. To get the key as an explicit argument.
http://localhost/fileID.aspx?key=A3DF

Please advise.

--
Regards
Konrad Viltersten
--------------------------------
sleep - a substitute for coffee for the poor
ambition - lack of sense to be lazy

Jun 27 '08 #5
On Apr 28, 6:38*am, "K Viltersten" <t...@viltersten.comwrote:
You might want to look at the VirtualPathProvider class and
concept. This allows you to serve an ASP.NET web site
from a database, or even from a ZIP file.

Thanks for the help. I'd like to get a clarification on a part of
it, though. Which of the following two approaches would be
more suitable, would you say?

1. To distract the key for DB from the file name.
* *http://localhost/fileID_A3DF.aspx
Here you would need to implement an URL rewriting technique
http://www.google.com/search?hl=en&q...et+URL+rewrite
>
2. To get the key as an explicit argument.
* *http://localhost/fileID.aspx?key=A3DF
This will work by default.
Jun 27 '08 #6
>Thanks for the help. I'd like to get a
>clarification on a part of it, though.
Which of the following two approaches
would be more suitable, would you say?

1. To distract the key for DB from the file name.
http://localhost/fileID_A3DF.aspx

Here you would need to implement an URL rewriting technique
http://www.google.com/search?hl=en&q...et+URL+rewrite
>2. To get the key as an explicit argument.
http://localhost/fileID.aspx?key=A3DF

This will work by default.
In that case, this'll be the method i'll
use. Why complicate thing? Thanks!

--
Regards
Konrad Viltersten
--------------------------------
sleep - a substitute for coffee for the poor
ambition - lack of sense to be lazy

Jun 27 '08 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Konrad Den Ende | last post by:
Is there a ready to use layer for playing up a QickTime-file? I'd hate to write it on my own. -- Kindly Konrad --------------------------------------------------- May all spammers die an...
0
by: | last post by:
Hi, We have a problem when trying to present data retrieved from SQL Server in an e-mail. We don't use SQL mail - we use JMail (in ASP code) and need to encode the message using ISO-8859-2. When...
2
by: Barry | last post by:
Hi all, I'd like to implement a Gaelic tutorial with the inclusion of Gaelic fonts. Irish Gaelic has 18 letters - abcdefghilmnoprstu but vowels can also take an acute accent, called a fada...
4
by: Isabelle | last post by:
Hello all, I want two sets of links to do different things; one set within *content* and the other *navigational* elements. In particular I want the *hover* rollover effect to work differently...
3
by: _Lars_ | last post by:
Any suggstions on how to play a quicktime movie (i.e .mov) within a c-sharp application? Thank you for the advice.
5
by: aotemp | last post by:
Hi, Im trying to find a way to convert a single color in a mov or an avi file into a transparency. I looked at...
4
by: siggi | last post by:
Hi all, does Python support MPEG or MOV videoclips? I couldn't find anything about it online. Thank you, Siggi
4
by: acknowledged74 | last post by:
Hi All We have updated the website for The Television and Radio Industries Club. The site includes a 1 minute 50 second .mov movie. http://www.tric.org.uk/main/tric_awards1.html It will...
0
by: D2 | last post by:
Hi All, I want to read metadata like height, width, length of video file formats like .mov, avi, .mpg etc and possibly one frame as bitmap. Could anyone pl suggest what are the options in...
4
by: rabindra123 | last post by:
hi everyone, I want a music player for the greetings card which can run on .mp3,.midi,.mov file and also it should run in all the browser.Any idea plaese help
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.