Hello Aparajita
Sometime it would be easier scripting, if we could exit a Include File, instead
of using If else end if.
Similar to a method, where you can leave the method with return, in the middle
of a block.
In the moment I do it in two ways.
Version A:
index.a4d
include preview.inc
preview.inc
if($ajax)
include preview_ajax.inc
else
include preview_default.inc
end if
Version B:
include.a4d
include preview.inc
preview.inc
if($ajax)
include preview_ajax.inc
else
Normal Preview-Block
end if
Version C: (for this a new Active4D command would be needed.
index.a4d
include preview.inc
preview.inc
if($ajax)
include preview_alax.inc
exit include
end if
Normal Preview-Block
The advantage in Version C is, that I can break a Include File, Similar to
return in a method.
Regards, Oliver
_______________________________________________
Active4D-dev mailing list
[email protected]
http://list.aparajitaworld.com/listinfo/active4d-dev
Archives: http://active4d-nabble.aparajitaworld.com/