added hack for generating valid plugin dir url on scripts and styles registering