global doesn't work like that for AOLserver. This kind of usage is what
nsv was designed for. Rewrite using nsv instead:
globalInfo.adp
<%
nsv_set . test "Thisisatest"
%>
showGlobal.adp
<%
ns_adp_puts [nsv_get . test]
%>
Why? Remember that these two adp's are not part of a single script.
They are invoked by HTTP requests, which are stateless. They don't
share
memory or variables.
Use nsv instead of ns_share, if you can--it's more efficient.
See: http://www.aolserver.com/docs/nsv.adp
Rob
Prakash Sinha wrote:
>
> i have two files in the same directory.....
>
> globalInfo.adp
> <%
> global test
> set test "Thisisatest"
> %>
>
> showGlobal.adp
> <%
> #ns_adp_include globalInfo.adp
> global test
> ns_adp_puts $test
> %>
>
> It fails giving error test is undefined.
>
> Any idea?
> P