Learning inheritance

Thomas Jollans thomas at jollans.com
Sun Sep 19 04:12:52 EDT 2010


On 2010-09-19 09:22, Niklasro wrote:
> util.py:
> url = os.environ.get("HTTP_HOST", os.environ["SERVER_NAME"]) #declared
> as class variable(?)
>   
There is no class here, so this is no class variable, and you're not
inheriting anything. You're simply using a module.

> And viola just test if util.url.find('niklas') > 0:
>
> Exactly what I wanted to do with your experienced guidance.
>
> Many thanks
> Happy refactored
>   




More information about the Python-list mailing list