HTML - Forcing Downloading Rather Than Opening
Generally when you click a link to e. g. JPEG image, it is open in browser window. When you click a link to a ZIP file, it is downloaded.
Is there a possibility to force a browser downloading e. g. a JPEG image? Similar TutorialsCan someone post the code I would use to have a hyperlink on our webpage that would give visitors the option to view or download a pdf? Thanks! I have a table with three cells in it, one cell at the top and one cell at the bottom with an image in i.e borders. I then put text in the middle cell, enough that it forces the cell to be greater than the height of my screen and then pushes the bottom cell off the bottom of the screen. How do i make the middle cell (with the text in) a fixed size and create a scroll bar for the text that is off the screen thus keeping the bottom border nice and tidy at the bottom of my screen? HTML Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Untitled Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> <table width="820" border="0" cellpadding="0" cellspacing="0" height="100"> <!--DWLayoutTable--> <tr> <td width="953" height="45" valign="top"><img src="site/images/slice_03.jpg" width="953" height="45"></td> </tr> <tr> <td height="353" valign="top"> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> <p>This text needs to stay in the middle of the screen and not push the bottom border off the page</p> </td> </tr> <tr> <td height="44" valign="top"><img src="site/images/slice_20.jpg" width="953" height="43"></td> </tr> </table> </body> </html> Hi, I'm been having some trouble viewing an embedded an SWF file. Nobody in the ActionScript/Flash community seems to have any answers so I thought I'd try here, since it's really an HTML issue anyway. I built an 800x1400 SWF in Flash CS5 and exported the file in an HTML wrapper, automatically generating the appropriate HTML code in an HTML file for upload to the server with the SWF. The problem is, my resolution is currently set to 800x600 and the HTML page won't scroll down so I can't see any of the content below the top 600 pixels of the SWF. Nobody seems to know how to force the page to add a scroll bar that will scroll down far enough for me to view the entire SWF. Any thoughts? Thanks for your help, ~Josh pls click on my website (only 80% finished) he http://www.welcometotherash.com the main body is a frame-based environment (except the index page u see first) but i want to force frames so it works properly. if you click on the 'road rash cd' link it brings up the frame page (force frames) but the wrong page is in there - if you use the sidebar and hit 'road rash cd' - thats the page that should be force framed what am i doing wrong? any advice would be gratefully appreciated, thx Hi, When I put some text in a <h1> tag it automatically starts a new line after </h1>. Can I stop this from happening as I want text after it as part of the same sentence. Thanks Paul Hi All I am very new to HTML, and have employed the services of a junior designer to come up with a site for me. It can be seen at www.360ukproperty.co.uk, please excuse some of the pages are not completed yet. When clicking on the menu items, the relevant page loads in the faded out frame. This works on most computers, but for some reason it forces a new window to open up on my PC at home. It wirks fine on my designers's PC, my work PC and my laptop. This problem is on IE6, IE7 and Firefox. Very weird! The code for the homepage is pasted below: Hopefully its something simple.....~? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>360 UK Properties</title> <link href="style.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="frame" align="center"> <div id="main"> <iframe style="padding-top:94px; float:left;" src="title.html" name="mainFrame" scrolling="no" id="mainFrame" marginwidth="0" marginheight="0" frameborder="0" width="659" height="506"> </iframe> <div id="menu" align="left"> <p><a href="index.html">Home</a></p> <p><a href="why.html" target="mainFrame">Why 360?</a></p> <p><a href="how.html" target="mainFrame">How it Works</a></p> <p><a href="gallery.html" target="mainFrame">Gallery</a></p> <p><a href="faq.html" target="mainFrame">FAQ</a></p> <p><a href="price.html" target="mainFrame"> Prices</a></p> <p><a href="contact.html" target="mainFrame">Contact</a></p> <div id="bottom"> <p><a href="mailto:gustavbasch@yahoo.co.uk">info@360ukproperty.co.uk</a><br /> phone: +44 7875374689</p> </div> </div> </div> </div> </body> </html> Hello I have an issue where I have two web pages generated from Java servlets in NetBeans 5.5. The first of these pages requires some user input and when the page's form is submitted, this input is sent to the server. The server processes the input to generate a text file which is used by a graphing tool to plot a graph as a 'png' file. This text file and graph are then displayed in the HTML generated for the second page using 'href's in a table. This works perfectly well but if the user wants to alter the graph, they have to go back to page one and change the options and resubmit the form. This is where the problem occurs; in Firefox all is well but in Internet Explorer and Opera, when they resubmit the form, page two displays the original graph rather than the changed one. A hard 'refresh' is required via F5 to force the displaying of the new text file and graph. I have tried various of the HTML: meta http-equiv=\"refresh\" content=\"0\"> alternatives and forcinf reload upon loading the second page but the graph and text file still show original data. Is there a way to force the browser to 'pick up' the new text and graph generated so that the page display is correct? I see this more as an HTML issue rather than a servlets one hence its inclusion in this forum. Thanks Martin O'Shea. Hi, I want visitors to be able to download files (.mp3) from my web site . I've looked through some of the posts on this and some seem to say just use something like: <a href="http://yourdownloadfile.mp3">Download This</a> others mention php. What is the best to use? Do I need php? Thanks Hi, I'm putting up a store that sells downloadable content and am having trouble with the download procedure in the osCommerce system. Under Linux it works great but the host I am using uses Microsoft Server and after about 10 mb or 4 minutes time it runs out of resources and reports the download is complete when it is not. Now I'm looking for an alternative method to download the file without the buyer being able to see the exact URL for the file. If he could see that he would have the opportunity to pass it on to his friends. If dishonest he could just as easily email the file to all his friends but I digress. Using the store's download procedure I can only get 46kps where as I can get in excess of 200kps by entering the URL to the file in the address box at the top of the browser. Ok now I have procedures that will check to make sure the person is logged in and he has downloads available to the file before the procedure will continue so what I need to know is there a way to after the checks are run just do the equivelant of entering the URL at the top of the box without actually allowing the user to see the URL to the file? The store uses PHP to do this and under Linux is extremely fast, but under MS server is slower than crap and never completes. I thank you for reading this, I probably gave more information than was needed, but I would rather err on the side of too much than too little. Bob Hai I am displaying a list of mp3 files in a html file. I want to provide download option for the mp3 files from the html file. Now i am converting mp3 files to a zip file and then downloading it as below <a href="song.zip"> Download file</a> But i want to download it as an mp3 file itself. please any body guide me to download the mp3 file from the html file. Thanks Sakthi I'm trying to setup download links on my page. For exsample I have a file on my web server and I want a link that I can click on and it will bring up a download window. Can anyone PLEASE HELP! I am setting up a website to print free birthday cards. However I am not at all experienced in html. Basically I want the customers to print the cards without downloading the image. I thought I could do this perhaps by loading what I want printed in an iframe (???) The actual page will have the image with a watermark on it, and a printing link that prints the card without the watermark There are download managers (such as DAP, etc.) which can download parts of files from different mirrors and assemble them on the same pc. Your users will need one of these installed to download the file, or you could send them your own download manager. If using a ready made download manager they'll need to enter the urls of the two mirrors of the file. Hi, I'm a photographer and I want to start posting portrait slideshows to my website. What I would like to do is have a simple HTML page with hyperlinks that when you click on the subjects name it will start the download for the slideshow. However, I would like for it to request a password before allowing someone to download the file. It doesn't have to be double super secret secure and is really more for keeping honest people honest. I would just like to have another step the might deter someone from downloading another person's slideshow. Any help with this coding would be greatly appreciated. Thanks! -Pam Hi, Im trying to put .pps or .ppt slideshows on my website but instead of playing the show, it wants to download. I thought they were working right at one point a long while ago, but nooooo...I must have been hallucinating! I would really appreciate any advice. page: http://jdsplace.us/vids/seriousvids/...worldpics.html the slideshow is beautyworldpics.pps code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Beautiful Views of Our World</title> </head> <body background="/background_images/b2.gif"> <a href="/new/lateststuff/lateststuff1.html"><img src="/gif/backblue.gif" border="none"></a> <center> <table border="4" width="60%"> <tr> <td> <center><font size="6"><em><b> Here are some fantastic photos of our world </b></em></font</center> </td> </tr> </table> <br> <font size="4"> Click the Blue button...may take a moment to load </font> <a href="/vids/seriousvids/beautyworldpics.pps"><img src="/gif/button43.gif" border="none"></a> </center> </body> </html> Please follow this link and observe how the page scrolls up after you have been taken there. It scrolls up because, unless you've been here before and have all the images stored on your computer, the images are continually downloaded and they expand the height of the page causing it to expand down and causing your browser to scroll up. Incidentally, the point at which you were supposed to be linked to ends up further down the page. Is there a way of preventing this? Is there a way of getting the browser to stick to the original point on the page where you were linked to? How do I get a sound file to automatically download when a user enters the page after purchsing? Thanks. heya guys i want to open a webpage in a new window when i click on a hotspot. can anyone tell me what i need to do? frosty I have a link on my website that opens up a new window, and that new window opens up and is resized to be smaller at 400X300. It works just fine on Internet Explorer and Safari, but when it's in Firefox the new window opens up on a separate tab in the same browser window and causes the whole window to resize to 400X300. Is there a way to fix this? Like is there a better coding to make sure Firefox will open this link in a new window for sure, and not just a separate tab? I'm using the coding target="_blank" right now..... |