Works well now. i think the trick was your statement and code '>Important changes:
>
>- The href really should be surrounded by quotes as it is in my version.'
> writebr("<a href=\"/files/" + url encode path($docList{$i}) + "\">" +
Putting all the code into 1 active 4D statement rather than Active4D, HTML, Actiev4D,
HTML bits has made the difference.
Thanks
Graham
On Friday, November 21, 2003, at 01:10AM, Aparajita Fishman <[EMAIL PROTECTED]> wrote:
>> This is part of the code that does not work if the page is put in an
>> iframe. It works fine if it is just an included page. If it should
>> work I will just try some more variations.
>>
>> <%
>> Array string(31;$arrayCF;0)
>> Array string(31;$arrayFLCF;100)
>> Document List ("Macintosh HD:Fear:Web:files:"+get
>> session("vSubject")+":Downloads";$arrayCF) `can use get root
>> For ($h;1; size of array ($arrayCF))
>> $j:=1
>> $arrayFLCF{$h}:=""
>> For ($j;1; length($arrayCF{$h}))
>> if(substring($arrayCF{$h};$j;1)=" ")
>> $arrayFLCF{$h}:=$arrayFLCF{$h}+"%20"
>> else
>> $arrayFLCF{$h}:=$arrayFLCF{$h}+substring($arrayFLCF{$h};$j;1)
>> end if
>> end for %>
>> <img src="Images/file_icon.gif" align="middle">
>> <% ="<a href=/Files/" + get session("vSubject") + "/Downloads/" +
>> $arrayFLCF{$h} + ">" + $arrayCF{$h} + "</a>" %>
>> <br>
>> <%
>> End for %>
>
>Allow me if I may to rewrite it:
>
><%
>array string(31; $docList; 0)
>document list(get root + "files/" + session{"vSubject"} +
>"/Downloads/"; $docList)
>
>for($i; 1; size of array($docList))
> write("<img src=\"Images/file_icon.gif\" align=\"middle\">")
> writebr("<a href=\"/files/" + url encode path($docList{$i}) + "\">" +
>$docList{$i} + "</a>")
>end for
>%>
>
>Important changes:
>
>- The href really should be surrounded by quotes as it is in my version.
>
>- Use 'url encode path' to transform the spaces (and other necessary
>characters). Please see the "URL Encoding/Decoding" subsection of the
>"String" section of the Command Reference.
>
>- Note the capitalization of "files" differs in your code between the
>'document list' command and the building of the href.
>
>As for why it isn't working as an iframe, what does your iframe tag
>look like?
>
>Regards,
>
> Aparajita
> Victory-Heart Productions
> [EMAIL PROTECTED]
> www.aparajitaworld.com
>
> "If you dare to fail, you are bound to succeed."
> - Sri Chinmoy | www.srichinmoylibrary.com
>
>_______________________________________________
>Active4d-dev mailing list
>[EMAIL PROTECTED]
>http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev
>
>
Graham Timmins
RMIT University
9925 4272
0412 667 007