Changeset 2900

Show
Ignore:
Timestamp:
12/14/07 20:11:48 (9 months ago)
Author:
Rottenchester
Message:

Added better comments.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • addressplugin/0.11/address/macro.py

    r2897 r2900  
    1 # Implements the Moin-style IncludePages macro. 
    2 # 
    3 # This plugin base on WikiInclude macro By Vegard Eriksen zyp at jvnv dot net. 
    4 # See: http://projects.edgewall.com/trac/wiki/MacroBazaar#WikiInclude 
    5 # and on the variant written by  yu-ji 
    6  
    71from genshi.builder import Element, tag 
    82from genshi.core import Markup 
     
    1913__all__ = ['AddressMacro'] 
    2014 
    21 _API_KEY = 'ABQIAAAA3VM3oU5dUaRzj4mZKrWenRR-aua9fIhr0mssyA66j0SiUW84BRT6dpcTl-e73A90avaJpS5TGZYrCQ
     15_API_KEY = 'PUT YOUR KEY HERE
    2216 
    2317class AddressMacro(Component): 
    2418    """ 
    25  
     19    Creates a Google map for the supplied address and optional location. 
     20    This map is stored in the trac database and associated with the page. 
     21    The rendered map shows other addresses in proximity. 
     22    {{{ 
     23 
     24    [[Address("123 Any Street, Anytown, NY 14450","Some Location"]] 
     25 
     26    [[Address("123 Any Street, Anytown, NY 14450"]] 
     27 
     28    }}} 
    2629    """ 
     30 
    2731    implements(IWikiMacroProvider) 
    2832 
  • addressplugin/0.11/address/tests/simple_geocode_test.py

    r2897 r2900  
    33import geocode 
    44 
    5 _API_KEY = 'ABQIAAAA3VM3oU5dUaRzj4mZKrWenRR-aua9fIhr0mssyA66j0SiUW84BRT6dpcTl-e73A90avaJpS5TGZYrCQ
     5_API_KEY = 'PUT YOUR KEY HERE
    66 
    77place = geocode.geocode('1 Main St, Pittsford, NY 14534',_API_KEY) 
  • addressplugin/0.11/address/tests/simple_wikiaddress_test.py

    r2897 r2900  
    33import wikiaddress 
    44 
    5 _API_KEY = 'ABQIAAAA3VM3oU5dUaRzj4mZKrWenRR-aua9fIhr0mssyA66j0SiUW84BRT6dpcTl-e73A90avaJpS5TGZYrCQ
     5_API_KEY = 'PUT YOUR KEY HERE
    66 
    77my_dbapi = __import__("MySQLdb") 
    88mydb = my_dbapi.connect(host='localhost', 
    9                         user='rottentrac', 
    10                         passwd='rottentrac', 
    11                         db='rottentrac') 
     9                        user='userid', 
     10                        passwd='password', 
     11                        db='password') 
    1212 
    1313w = wikiaddress.wikiaddress(mydb,'mundo grill',_API_KEY,'somebody','1.2.3.4','2833 Monroe Ave, Rochester NY 14618',None)