jafrazee
asked on
loading images
currently if have a pretty long routine to load customer logo's.
i am loading them into a table format loading individual images by name.
it becomes a problem when i have to load new ones, because i have to rewrite the page to keep the order correct.
is there a way to read a directory that the images are in and load them in alpha order?
current code.
<td class="td_maintext">
<table border="0" cellspacing="10" cellpadding="0">
<tr>
<td><img src="images/a1.jpg" width="99" height="96"></td>
<td><img src="images/a2.jpg" width="99" height="96"></td>
<td><img src="images/a3.jpg" width="99" height="96"></td>
<td><img src="images/a4.jpg" width="99" height="96"></td>
</tr>
<tr>
<td><img src="images/a5.jpg" width="99" height="96"></td>
<td><img src="images/a6.gif" width="99" height="96"></td>
<td><img src="images/a7.jpg" width="99" height="96"></td>
<td><img src="images/a8.jpg" width="99" height="96"></td>
</tr>
<tr>
and so on
thanks for any help
i am loading them into a table format loading individual images by name.
it becomes a problem when i have to load new ones, because i have to rewrite the page to keep the order correct.
is there a way to read a directory that the images are in and load them in alpha order?
current code.
<td class="td_maintext">
<table border="0" cellspacing="10" cellpadding="0">
<tr>
<td><img src="images/a1.jpg" width="99" height="96"></td>
<td><img src="images/a2.jpg" width="99" height="96"></td>
<td><img src="images/a3.jpg" width="99" height="96"></td>
<td><img src="images/a4.jpg" width="99" height="96"></td>
</tr>
<tr>
<td><img src="images/a5.jpg" width="99" height="96"></td>
<td><img src="images/a6.gif" width="99" height="96"></td>
<td><img src="images/a7.jpg" width="99" height="96"></td>
<td><img src="images/a8.jpg" width="99" height="96"></td>
</tr>
<tr>
and so on
thanks for any help
ASKER
the array loads onto the web document but does not load into my table.
am i missing a step?
am i missing a step?
Show me your code.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
<td class="td_maintext">
<table border="0" cellspacing="10" cellpadding="0">
<tr>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
</tr>
<tr>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
<td><img width="99" height="96"></td>
</tr>
<tr>
<table>
<script>
ImArray= new Array("images/a1.jpg","ima
for (i=0;i<=document.images.le
{document.images[i].src=Im
</script>