[eluser]gunter[/eluser]
using realpath() isn´t necessary because the library already uses the realpath()...
and BASEPATH isn´t necessary too, because you are already in the base folder...
so, if you upload folder is one level over (?correct english word?) the base folder (with the index.php) then just use this...
"../static/images/katalogas/kategorijos/'
path can be described absolute or relative says the userguide...