File: _web_example8.py

package info (click to toggle)
nodebox-web 1.9.4.6-1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 1,904 kB
  • ctags: 1,602
  • sloc: python: 7,582; ansic: 581; xml: 239; makefile: 2
file content (10 lines) | stat: -rw-r--r-- 222 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
# Definitions from the Urban Dictionary.

try:
    web = ximport("web")
except:
    web = ximport("__init__")
    reload(web)

definitions = web.urbandictionary.search("human")
text( choice(definitions), 50, 50, width=300)