ClientScripting fixes