Cleaned up inline js approach