Print Page | Close Window

Scan MP3 files

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=2919
Printed Date: 29 March 2026 at 10:14am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Scan MP3 files
Posted By: Mart
Subject: Scan MP3 files
Date Posted: 21 May 2003 at 12:04pm

Does anyone know how to scan an MP3 file in asp and extract the artist and the track from the ID3 tag? Is this even possible?

Thanks, Martin.




Replies:
Posted By: MorningZ
Date Posted: 21 May 2003 at 1:08pm
http://www.4guysfromrolla.com/webtech/tips/t041701-1.shtml - http://www.4guysfromrolla.com/webtech/tips/t041701-1.shtml

-------------
Contribute to the working anarchy we fondly call the Internet


Posted By: Mart
Date Posted: 21 May 2003 at 2:01pm

Does this script work for a <input type="file"> or does the MP3 have to be on the server because it uses fso.

Thanks, Martin.



Posted By: MorningZ
Date Posted: 21 May 2003 at 2:06pm

you cannot peek inside a client's file on their computer.. ASP only has access to files on its filesystem

imagine the havoc if it wasn't that way



-------------
Contribute to the working anarchy we fondly call the Internet


Posted By: Bluefrog
Date Posted: 22 May 2003 at 4:18am

Cool. I checked out the script and it kicks butt. I think I'll be using that one in the near future.

 



Posted By: Mart
Date Posted: 22 May 2003 at 9:33am
So your saying you can upload files and post he contents anywhere on your site and make it availible for download with the users say so, but you can't view files they selected in 'real time' with there say so. There must be a way...


Posted By: MorningZ
Date Posted: 22 May 2003 at 9:38am

You obviously dont have an iota of a clue about "scope"

A file here on my work computer is NOT accessible by a web server, even if the location is listed inside a "file" input box...

If server side script had access to a user's file system, it would be "hack a rama"

Now there are some Client-side ActiveX controls that can capture info about files a user says is ok to do so, but those controls are very pricey... but Joe Schmo programming in straight up ASP DOES NOT have access to any files outside the world of "cookies"



-------------
Contribute to the working anarchy we fondly call the Internet


Posted By: Mart
Date Posted: 22 May 2003 at 10:53am
So how does file uploading work?


Posted By: Gary
Date Posted: 22 May 2003 at 10:57am

Usually by using a component such as aspupload. The web page should have a form which includes an <INPUT> of type 'file'. This allows the user to select a file on their pc and upload it to the web server.

The web server itself cannot go to a users pc and pull files - it has to be the user pushing the file to the web server.

just imagine if I had a web site that was able to pull files willy nilly from the site visitors' machines - major security issue !!!



Posted By: Mart
Date Posted: 22 May 2003 at 12:58pm
But when you press the submit button doesn't it post the contents of the file to the asp page?


Posted By: MorningZ
Date Posted: 22 May 2003 at 1:10pm

yes, but at the point the file is at the server, whether its a physical file on the server's Hard Drive or as a stream in memory....

 

 



-------------
Contribute to the working anarchy we fondly call the Internet


Posted By: eagle00789
Date Posted: 22 May 2003 at 6:04pm
and when you have the stream in the memory, then you can do with it what you (or your asp-page) want. even read the ID3 tag

-------------
Using forum at http://www.gravenrode.nl/forum/forum - Gravenrode and http://www.gravenrode.nl/forum/test_forum - here and http://217.121.39.22/forum/test_forum - here


Posted By: Bluefrog
Date Posted: 23 May 2003 at 9:06am

Real simple.

Get two things happening - upload and MP3 file reading:

1) A file upload to the server (aspupload or whatever)
2) Read the file in the upload component and save it to disk
3) Use the script MorningZ posted to access all the information
4) Do whatever you like from that point

For the upload version, you can use http://www.aspupload.com/ - aspupload or http://www.dundas.com - Dundas Upload or the http://www.softartisans.com/ - SoftArtisans component or whatever you like.

If you like free, go for Dundas. If you think you might need support, go for a commercial component.

Your pages should follow a simple path:

1) Page 1 allows users to upload mp3s
2) Page 2 accepts the upload, saves the file, perhaps does some database work or other file system work and returns a result

Mart, for your question about the component posting... just check the documentation for a component. It will tell you exactly how to handle the file once you receive it on the "post to" page. And yes, when you click submit, the file upload BEGINS.

I hope that helps clarify - looks like there's a bit of confusion in this thread...

Cheers

 




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net