|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
|
|
Free Web 2.0 Code Generator! Generate data entry and reporting .NET Web apps in minutes. Quickly create visually stunning, feature-rich apps that are easy to customize and ready to deploy. Download Now!
|
|
#1
|
|||
|
|||
|
Load multiple images from variable
Why is only the first image loading? The variables are defined in a previous script within the head section. This script is in the head section as well.
Code:
<script type="text/javascript">
onload = function(){
document.getElementById('firstpic').setAttribute(' src','Pictures/Page1/'+page1pic1);
document.getElementById('secondpic').setAttribute( 'src','Pictures/Page1/'+page1pic2)
}
</script>
Figured it out...This code works... Last edited by headpoop : October 25th, 2006 at 05:53 PM. Reason: Figured it out |
|
#2
|
||||
|
||||
|
thanks for reposting!
colton22 |
![]() |
| Viewing: Dev Articles Community Forums > Programming > JavaScript Development > Load multiple images from variable |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|