Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

displaying tif files.

Status
Not open for further replies.

MarkElls

Programmer
Aug 26, 2003
57
GB
I have some asp pages and am hoping to open up a tif file and display it either on a html page or open a new HTML page to display the image.

It is non negotiable that the pictures are tif's. When I put in

<IMG SRC = "E:\FW_EXAMPLE\0101829\ltr00001.tif"> as the code I just get the good old white box and red cross picture. Is it correct that the tif format is not compatible with IMG?

Thanks.
Mark.
 
nope. TIF format isn't compatible with browsers.

if use_of_tif != negotiable then chance = 0



Chris.

Indifference will be the downfall of mankind, but who cares?
A website that proves the cobblers kids adage.
Nightclub counting systems

So long, and thanks for all the fish.
 
.tif format is not compatible with the WEB. You can use jpg, gif or png. Browsers will sometimes display bmp but it is not good to rely on that. I suggest you just make links for the pictures and have users handle .tif themselves.
 
Here is the problem there are litterally hundreds of thousands (about 176 thousand of these tiffs) they are all logged in a directory structure ie issue no 1 is kept in directory 00001. Then inside the directory there is a SubDirectory for each contact with this issue ie 01,02,03,04,05 ... Inside each of the folders is one .tif file.

I am using vb script within these pages. Is there anyway I can get an applkication to open up these tif's?

Any other suggestions?

Mark.

 
I think the solution is going to have to be server-side. Either you write a (fairly simple) program which trawls through all those directories and produces converted versions of the images in a more web-friendly format; or you write a (still quite simple) program which does the conversion on-the-fly as an image is requested.

Take a look at the Image Magick library.

-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 
I imagine you can use a Java applet to display any kind of graphic. Not sure where to find one, but suspect that the old, worn out shimmering pool might do it, too.

Lee
 
we are talking 80Gig of pictures. So even an automated process of converting would not work as I need to store in .tif and in the new format. The person with pointy hair has deep pockets and arms shorter than very short arms, so nop chance of extra storage space.

Thyanks Rye, Chris I will have a look at those.


Thanks.
Mark.
 
I tried Alternatiff but that does not work as a solution. At this rate it would be easier to give up and tell the users to use windows explorer to locate the tif's and then just open the file.
Had a look at ImageMagic but again not a 100% match to what I want to do.

I will start to have a look at Java applets. I wish I had never started this. But the learning curve is steep.

Mark.


 
Another reason to do (whatever you're going to do) on the server side is that TIF files are big. Vour visitors won't want to sit around downloading them, nor will you want to be using up the bandwidth sending them.

I wouldn't rule out the "convert everything" solution - 80GB of TIFs will result in much less than 80GB of PNGs or JPGs, you'll benefit from the compression that those formats use. It's still going to be a big chunk of disk space of course, but disk space is dirt cheap these days.

Converting on-the-fly is way more elegant though...

-- Chris Hunt
Webmaster & Tragedian
Extra Connections Ltd
 

And of course, if you go the PNG route, why not just scrap the TIFs altogether and use PNG as your masters? That way, you won't even need 2 copies of everything.

Dan
 
Tifs with LZW compression can be pretty small.. and they are lossless.. but as said they aren't web friendly.

You could use photoshops automate feature to convert them all to Jpegs for you. Leave it running and go have fun. Might even do them all overnight.

If the files are needed for print purposes then I wouldn't use PNG format as a master. Tiffs are much more suitable and compatible.

- Web design and ranting
- Day of Defeat gaming community
"I'm making time
 
If you don't have Photoshop, there are other programs that automate graphics conversion. I use Irfanview, which is free, to do batches of graphics and have been quite pleased with it. You can set compression, dimensions, and other parameters.

Lee
 
Thanks. To think I got in the office this morning and was about to give up on this.

I will have to spend some time looking at the conversion. Its going to be a long job and I have a feeling these images will need to be printed.

They were originally scans of handwritten letters that needed to be kept. Rather funny really, they received the paper copy scanned the letter, and now to keep as they are not keeping the system they either have to print the scanned letters (Isnt that Ironic) or I need to convert them to another format.

I did wonder if there is a way of opening them with an application ie click on the limnk in the web page and imaging software opens up with the scanned letter showing?


Thanks for all the wonderfull help.

Mark.
 
I did wonder if there is a way of opening them with an application ie click on the limnk in the web page and imaging software opens up with the scanned letter showing?

If you set the MIME type for TIF files on your web server to be some generic binary type, and then use a standard A HREF... tag to link to them, then the user will be presented with the usual "download" or "open" box when clicking the link... If they choose "open", it should open in whatever application they have set up on their PCs to handle the .TIF extension.

Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top