Hello,
How can I preload a few images of a page javascript?
Should I use CSS to do this? Is it even possible?
Thanks,
Miguel 9 1969
shapper wrote:
Hello,
How can I preload a few images of a page javascript?
Hi,
Go to google: http://www.google.com
Type in the searchbox:
preload images javascript
Follow any of the 985,000 links, eg the first.
Regards,
Erwin Moller
Should I use CSS to do this? Is it even possible?
Thanks,
Miguel
Erwin Moller wrote:
shapper wrote:
>How can I preload a few images of a page javascript?
[...]
Go to google: http://www.google.com
Type in the searchbox:
preload images javascript
Follow any of the 985,000 links, eg the first.
However, http://groups.google.com
and
preload images group:comp.lang .javascript
returns more useful information.
Please trim your quotes as described in the FAQ Notes.
PointedEars
--
Prototype.js was written by people who don't know javascript for people
who don't know javascript. People who don't know javascript are not
the best source of advice on designing systems that use javascript.
-- Richard Cornford, cljs, <f8************ *******@news.de mon.co.uk>
Thomas 'PointedEars' Lahn wrote:
Erwin Moller wrote:
>shapper wrote:
>>How can I preload a few images of a page javascript?
[...] Go to google: http://www.google.com
Type in the searchbox: preload images javascript
Follow any of the 985,000 links, eg the first.
However,
http://groups.google.com
and
preload images group:comp.lang .javascript
returns more useful information.
Good advise.
>
Please trim your quotes as described in the FAQ Notes.
The two lines from the OP?
Get real.
Regards,
Erwin Moller
>
PointedEars
Thomas 'PointedEars' Lahn said the following on 11/27/2007 6:19 PM:
Erwin Moller wrote:
>Thomas 'PointedEars' Lahn wrote:
>>Please trim your quotes as described in the FAQ Notes.
The two lines from the OP? Get real.
It was four lines that you did not refer to but quoted anyway, and you
did it again. Read the FAQ.
You should try some relaxation techniques. Then you wouldn't stay as
wound up as a two dollar watch.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javas cript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Randy Webb wrote:
Thomas 'PointedEars' Lahn said the following on 11/27/2007 6:19 PM:
>Erwin Moller wrote:
>>Thomas 'PointedEars' Lahn wrote: Please trim your quotes as described in the FAQ Notes. The two lines from the OP? Get real.
It was four lines that you did not refer to but quoted anyway, and you did it again. Read the FAQ.
You should try some relaxation techniques. Then you wouldn't stay as
wound up as a two dollar watch.
I am quite relaxed, thank you. However, I found it necessary to point out
that Erwin's posting style, which is against established Usenet conventions,
will confuse people, and even irratate some. It was not the first time that
he did this, and it turned out it was not the last time.
I would like to remind you that you reduce your credibility as the FAQ
maintainer by issuing statements that imply FAQ content not to be important.
PointedEars
--
Prototype.js was written by people who don't know javascript for people
who don't know javascript. People who don't know javascript are not
the best source of advice on designing systems that use javascript.
-- Richard Cornford, cljs, <f8************ *******@news.de mon.co.uk>
Thomas 'PointedEars' Lahn said the following on 11/27/2007 6:40 PM:
Randy Webb wrote:
>Thomas 'PointedEars' Lahn said the following on 11/27/2007 6:19 PM:
>>Erwin Moller wrote: Thomas 'PointedEars' Lahn wrote: Please trim your quotes as described in the FAQ Notes. The two lines from the OP? Get real. It was four lines that you did not refer to but quoted anyway, and you did it again. Read the FAQ.
You should try some relaxation techniques. Then you wouldn't stay as wound up as a two dollar watch.
I am quite relaxed, thank you. However, I found it necessary to point out
that Erwin's posting style, which is against established Usenet conventions,
will confuse people, and even irratate some. It was not the first time that
he did this, and it turned out it was not the last time.
Then I find it necessary to point out that you have posted way more than
those two lines to complain about those two lines. If it had been enough
to have been worthwhile, then sure. But two lines? Wind down my friend.
I would like to remind you that you reduce your credibility as the FAQ
maintainer by issuing statements that imply FAQ content not to be important.
I said the FAQ content isn't important? Wow. You are pedantically
complaining about two lines. I quote a lot more than that, are you going
to start being pedantic with me as well?
Two lines crosses into a gray area where you have to apply some common
sense sometimes and realize it causes more problems to complain than the
two lines ever did.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javas cript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Thomas 'PointedEars' Lahn wrote:
<snipped for Thomas>
I am quite relaxed, thank you. However, I found it necessary to point out
that Erwin's posting style, which is against established Usenet conventions,
will confuse people, and even irratate some. It was not the first time that
he did this, and it turned out it was not the last time.
Hi Thomas,
I have been posting on usenet for ages. You are the first that complains
to me about my posting style. People complaint to me about other things
I wrote a lot, but lets leave that. ;-)
Yes, I know of the conventions you refer to, and I follow them when they
seem to make sense to me. A 2 line question is considered by me very
short and to the point, and I don't see how cutting would increase
readability for anyone with an IQ over 60.
And irritating people?
Me?
Check this very group and see which one of us gets/attracks the most
annoyed reactions...
>
I would like to remind you that you reduce your credibility as the FAQ
maintainer by issuing statements that imply FAQ content not to be important.
This is not the first time I hear you complain out in the open about
Randy being the FAQ maintainer.
Did you had an eye on that task and didn't get it maybe?
I don't know your history, but that returning comment surely makes me think.
Oh: Get happier man. It really helps.
Regards,
Erwin Moller
>
PointedEars
On Nov 26, 2:17 pm, shapper <mdmo...@gmail. comwrote:
Hello,
How can I preload a few images of a page javascript?
Should I use CSS to do this? Is it even possible?
That is a question. Initially in Netscape 3.x they introduced
scriptable .src property for images so developers could achieve roll-
over effects for graphics menu elements. To avoid load delays for the
first mouseover they also introduced Image constructor. The purpose of
this constructor was that by making
var imgOver = new Image;
imgOver.src = 'some/url';
script issued load request for the new image so it would be pre-
cashed. As DOM 0 supported by all - even the most lousy - modern
browsers the answer would be "Yes, it is easy, use Image objects on
page load". But as much as I remember, this feature exposed browsers
to numerous cache misuse, like
var bogusImg = new Image;
bogusImg.src = 'some/10Mb-100Mb/image';
and as I remember some precaution limitation had been made up to stop
caching images completely on imgObject.src=" url" assignments.
What browsers still do such caching and if any left at all is a good
question to check.
P.S. Maybe that would also explain the origin of FAQ 4.31 http://www.jibbering.com/faq/#FAQ4_31 that puzzled me all the time -
because no Web developers in any sanity would ever use server-side CGI
image generators for menu buttons nor would patch content header for
still images. I looked through the clj archives and the time this FAQ
was proposed overall matches to the period of "cache attacks" as my
weaked memory tells me :-) So possibly we have in this FAQ a dog
barking to an all wrong tree.
In comp.lang.javas cript message <47************ **@PointedEars. de>, Wed,
28 Nov 2007 00:40:52, Thomas 'PointedEars' Lahn <Po*********@we b.de>
posted:
>I am quite relaxed, thank you. However, I found it necessary to point out that Erwin's posting style, which is against established Usenet conventions, will confuse people, and even irratate some. It was not the first time that he did this, and it turned out it was not the last time.
Established Usenet convention is to be reasonably tolerant, and not to
reply in a Gestapo-like fashion at any unimportant breach of one's
interpretation of the rules.
One notes that you are evidently found to be similarly arrogant and
obnoxious in de.c.l.j.
--
(c) John Stockton, Surrey, UK. ??*@merlyn.demo n.co.uk Turnpike v6.05 MIME.
Web <URL:http://www.merlyn.demo n.co.uk/- FAQish topics, acronyms, & links.
Check boilerplate spelling -- error is a public sign of incompetence.
Never fully trust an article from a poster who gives no full real name. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: MALdito |
last post by:
hi everybody
let me say right from the start .. I´m not a coder ... "just" a designer!
that said .. here is my question:
I´m using dreamweaver´s built in preloader for a menu. it looks like this:
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length;
|
by: Bob |
last post by:
I usually use some "pre-load" code in my pages to preload graphics
that will be swapped. But, I'm thinking that rather than the
long, repetitive, once, for each graphic hardcoded stuff like this:
var bb_off = new Image();
bb_off.src = "images/bb_off.jpg";
....that I could have an array where I just listed the names of the
graphics, a loop, and code in the loop that cycles through each
entry in the array to create and pre-load the "on"...
|
by: Albert Spencil |
last post by:
I have tried several preload scripts found here; plus, some of my own.
The only thing that works is the unsophisticated loading of those
tiny images. The download consist of 100+ images amounting to 50+mb;
and, normally completes in less than 1 minute without preload (using
DSL). The preload terminates after 6 or 7
images and seems to time-out in the middle of an image. A reload will
download a few more, etc. I have used the <body...
|
by: Stacey |
last post by:
Hi,
I'm hoping for a bit of advise-- I have a (relatively, from the
point-of-view of this dilettante) complex script that attempts to preload
certain images in order to trigger one of a series of six slideshows
(rather than try to articulate, have a look here):
http://www.slack.net/~stacey/stestbed/homejs.jsp
Clicking any of the six blocks of text along the sides will begin a loop
of the corresponding slideshow.
|
by: shapper |
last post by:
Hello,
I think to preload an image I should us something like:
img = new Image();
img.src = 'images/img.jpg';
Could someone tell me how to create a loop which would preload a list
of images?
Something like:
| |
by: shapper |
last post by:
Hello,
I am working in Asp.Net 2.0 web sites and I need to preload some images
in my master pages and in the pages that use those master pages.
Could someone tell me how to do this?
Thanks,
Miguel
|
by: shapper |
last post by:
Hello,
Is there a way to preload a few images of a page using only CSS?
If yes, how can I do it, and should I use CSS or Javascript to do
this?
Thanks,
Miguel
|
by: matt9807 |
last post by:
The following is a script that I have written that preloads images for an image gallery. The problem is that the images only preload in Safari, other browsers load each image when it is called. Any ideas?
imgSeries = new Array();
curImg = '';
function loadkill() {
document.getElementById('loadingtxt').style.display = "none";
document.getElementById('imgone').src = imgSeries;
document.getElementById('imgtwo').src = imgSeries;
}
|
by: Revathi Balakrishnan |
last post by:
Hi
i have the used the below code to switch the button image on mouseover
and mouseout.
<html:button property="Button" value="Display" styleClass="displaybutton"
onmouseover="this.className='displaybutton displaybuttonover'"
onmouseout="this.className= 'displaybutton'"/>
CSS definition of displaybutton and displaybuttonover is shown below.
|
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
| |
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |