SunQuest
 
           JavaScript Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingJavaScript Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today!
  #1  
Old August 3rd, 2006, 02:21 AM
janakiraman janakiraman is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 3 janakiraman User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 17 m 54 sec
Reputation Power: 0
Preload Background Image Untill Real Content is Displayed

Hi
Iam new to this forum. I went through the article to preload images. Looks Good. I thought of implementing the same concept into my program but with a different stratergy.
I want to load the background image for a few moment when the page gets loaded and then i want to display the actual content. I want to make use of ajax in doing so.Iam a beginner to ajax. so iam in need of your help.

Your help is greatly appreciated

Thanx in advance

janakiraman

Reply With Quote
  #2  
Old August 3rd, 2006, 02:41 AM
colton22's Avatar
colton22 colton22 is offline
\ ^_^ / - Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Location: near chicago, Illinois
Posts: 471 colton22 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 Days 1 h 9 m 44 sec
Reputation Power: 3
Send a message via AIM to colton22 Send a message via MSN to colton22 Send a message via Yahoo to colton22
i dont know anything about ajax, are you working with javascript, if so, you could use something like...

<BODY ONLOAD="witch()">
<DIV ID="hid"></DIV>
<DIV ID="page" STYLE="display:none">

page goes here

</DIV>
<SCRIPT TYPE="text/javascript" LANGUAGE="javascript" RUNAT="server">
function witch() {
window.document.all.hid.style.display="none";
window.document.all.page.style.display="inline";
}
</SCRIPT>

hope this helped

colton22

Last edited by colton22 : August 3rd, 2006 at 12:08 PM. Reason: thanks dzz

Reply With Quote
  #3  
Old August 3rd, 2006, 07:36 AM
MadCowDzz's Avatar
MadCowDzz MadCowDzz is offline
I'm Internet Famous
Dev Articles Frequenter (2500 - 2999 posts)
 
Join Date: Jan 2003
Location: Toronto, Canada
Posts: 2,890 MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 1 Week 16 h 4 m 48 sec
Reputation Power: 8
How long does your page really take to load?

For the record, coltron22 missed a closing triangle bracket on his <BODY> tag.
__________________
Daryl's Homepage | My Blogroll | My Profile | Firefox supporter!
DevArticles Forum Moderator

"The net is a waste of time, and that's exactly what's right about it." -- William Gibson

Reply With Quote
  #4  
Old August 31st, 2006, 04:14 AM
janakiraman janakiraman is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 3 janakiraman User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 17 m 54 sec
Reputation Power: 0
Hi,

can this loading be done via ajax. If so can u help me by sending some sample scripts or... I have to get it done by ajax. Iam having around 5 images in the page which may vary depending on the id that i pass to the page. so, for each image i need to display the loading image and then the actual image. This should occur independently.

Any help. greatly appreciated!!!

Thanx

Reply With Quote
  #5  
Old September 1st, 2006, 05:27 PM
colton22's Avatar
colton22 colton22 is offline
\ ^_^ / - Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Location: near chicago, Illinois
Posts: 471 colton22 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 Days 1 h 9 m 44 sec
Reputation Power: 3
Send a message via AIM to colton22 Send a message via MSN to colton22 Send a message via Yahoo to colton22
sorry, i dont even know what ajax is, ill reaserch it though, you have me wondering now.

lol
colton22

Reply With Quote
  #6  
Old September 5th, 2006, 08:50 AM
MadCowDzz's Avatar
MadCowDzz MadCowDzz is offline
I'm Internet Famous
Dev Articles Frequenter (2500 - 2999 posts)
 
Join Date: Jan 2003
Location: Toronto, Canada
Posts: 2,890 MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level)MadCowDzz User rank is Lance Corporal (50 - 100 Reputation Level) 
Time spent in forums: 1 Week 16 h 4 m 48 sec
Reputation Power: 8
I don't see the value that AJAX will add to your page... Why are you preloading a background image anyways? Shouldn't it just be optimized and relatively small anyways?

Reply With Quote
  #7  
Old September 7th, 2006, 05:48 AM
janakiraman janakiraman is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2006
Posts: 3 janakiraman User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 17 m 54 sec
Reputation Power: 0
What i really want is my page will be similar to my.yahoo.com. Let us assume that my apge is divided into four quadrants. Each quadrant seperately loads an php file. Before loading these files in their respective quadrant i need to display an image saying loadig etc. This should occur independently, in the sense a php file may have loaded as the time taken to load that file would be a few seconds. where as another file will take a few more seconds. In that case the loading progress should be shown. In this way the loading should be done independently. Is this possible. If this is not the right place to get the answer can you suggest where can i find an answer for this.
Iam very much depressed as i couldnt think of what step to take to solve this.

Thanks
janakiraman

Reply With Quote
  #8  
Old September 7th, 2006, 05:41 PM
colton22's Avatar
colton22 colton22 is offline
\ ^_^ / - Moderator
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Jun 2006
Location: near chicago, Illinois
Posts: 471 colton22 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 Days 1 h 9 m 44 sec
Reputation Power: 3
Send a message via AIM to colton22 Send a message via MSN to colton22 Send a message via Yahoo to colton22
i understand what your talking about but do not know how to fix it.

on the other hand, if you get it to work, i do have an image that might work well for your situation.

it is attached.

colton22
Attached Images
File Type: gif process_info.gif (4.7 KB, 384 views)

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingJavaScript Development > Preload Background Image Untill Real Content is Displayed


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway