title: how to check in python if a string contains characters only form specific code page?
body: <p>I know that python uses solely utf8 for string encoding , but what if I need to send data to older application that is non-unicode and supports only these characters that are included in windows code-page like windows-1251 (cyrylic) etc... So here I want to detect if utf-8 string contains any character that could not by represented by given code page.</p>