added interface and javascript handling