Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_discuss thread: What is going wrong ??


Message #1 by "Vincent Vandermeeren" <vinnie@j...> on Sat, 20 Apr 2002 20:25:21 +0200
This is a multi-part message in MIME format.

------=_NextPart_000_0020_01C1E8A9.7EDBDDE0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Hi all,

I have code that runs good on the website hosting of my provider but 
there I don't want to publish it yet till the whole website is ok.
If I run the code on my machine it doesn't work on my machine ...

What could be wrong ??
Don't mind the dutch text plz !!

Thanks,
Vinnie

<%
photo=3DRequest.QueryString("submod")
if photo =3D "vierjaar" then
denphoto=3D"ok"
end if
if photo =3D "verbouwingen" then
denphoto=3D"ok"
dentxt=3D"Foto's van de verbouwingen gedurende oktober 2001"
end if
if denphoto =3D "" then
photo=3D"vierjaar"
dentxt=3D"Foto's van ons vierjarig bestaan"
end if
%>
<table border=3D"0" width=3D"100%" cellspacing=3D"0" cellpadding=3D"0" 
height=3D"100%">
  <tr>
    <td width=3D"100%" valign=3D"top" align=3D"center">
      &nbsp;<div align=3D"center">
        <table border=3D"0" width=3D"95%" cellspacing=3D"0" 
cellpadding=3D"0" bgcolor=3D"#FF9900" style=3D"border-collapse: 
collapse">
          <tr>
            <td width=3D"100%" colspan=3D"2" valign=3D"middle" 
align=3D"center">
              <p align=3D"left"><b><font face=3D"Tahoma" size=3D"3" 
color=3D"#FFFFFF">&nbsp;Het Sjatoo
              photoalbum (<%=3Ddentxt%>)</font></b></td>
          </tr>
          <tr>
            <td width=3D"100%" colspan=3D"2" align=3D"center" 
bgcolor=3D"#C0C0C0">
              <p><a 
href=3D"default.asp?mod=3Dfotoalbum&submod=3Dvierjaar">4 jaar Sjatoo</a> 

              || <a 
href=3D"default.asp?mod=3Dfotoalbum&submod=3Dverbouwingen">
              De verbouwingen</a></td>
          </tr>
        <center>
<OBJECT RUNAT=3Dserver PROGID=3DScripting.FileSystemObject id=3DoFs> 
</OBJECT>
<%
Dim oFolder
Dim oFile
Dim iFileCount
Dim aFiles
Dim i
Dim sFolderPath

sFolderPath =3D "fotoalbum\" & photo

Set oFolder =3D oFs.GetFolder(server.MapPath(sFolderPath))
iFileCount =3D oFolder.files.count


ReDim aFiles(iFileCount)
i =3D 0
'loop files collection in folder
'put names in array
For Each oFile in oFolder.files
 aFiles(i) =3D oFile.Name
 i =3D i + 1
Next
Response.Write "<table border=3D""0"" width=3D""95%"" 
cellspacing=3D""0"" cellpadding=3D""0"">"
'loop array, write table
For i =3D 0 To uBound(aFiles)-1
%>
<tr><td align=3D"center" bgcolor=3D"#FFFFFF"><a 
href=3D"default.asp?mod=3Dshow&foto=3D<%=3DaFiles(i)%>&album=3D<%=3Dphoto
%>"><%=3DaFiles(i)%></a></td>
<%
 If i + 1 < uBound(aFiles) Then
%>
<td align=3D"center" bgcolor=3D"#FFFFFF"><a 
href=3D"default.asp?mod=3Dshow&foto=3D<%=3DaFiles(i+1)%>&album=3D<%=3Dpho
to%>"><%=3DaFiles(i+1)%></a></td></tr>
<%
  i =3D i + 1
 Else
%>
<td align=3D"center" bgcolor=3D"#FFFFFF">&nbsp;</td>
<%
End If
Next
%>
   </table>
        </center>
      </div>
    </td>
  </tr>
</table>


Message #2 by lingasamyk@h... on Wed, 24 Apr 2002 07:35:41
Hi vinnie

What kind of error did you face when you use it in your machine, since 
your problem is not mentioned clearly, finding out solution for the same 
is difficult. But i guess that the following may be the problem. Check for 
the existence of the folder (fotoalbum\) in your local site. Try this and 
get back to me.

Regards,
Lingasamy K

  Return to Index