Changeset 3147

Show
Ignore:
Timestamp:
06/25/07 02:06:54 (1 year ago)
Author:
carndt
Message:

- Reorganized layou temlates
- Update stale links
- Improve navbar
- Shorten sidebar

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • website/newdocs/about/changelog.html

    r2994 r3147  
    99 
    1010<body> 
    11      
     11<div id="page"> 
    1212    <h1>TurboGears Changelog</h1> 
    13      
     13 
    1414 
    1515    <h2 id="1.0.2_may_2_2007">1.0.2 (May 2, 2007):</h2> 
     
    5555  from #1361 by Christoph Zwerschke.</li> 
    5656 
    57     <li> SA auto-commiting fixed in some rare circumstances where sa_rwt was not being called. Patch from  
     57    <li> SA auto-commiting fixed in some rare circumstances where sa_rwt was not being called. Patch from 
    5858      #1267 by Paul Johnston.</li> 
    5959 
     
    9494<li> RuleDispatch to 0.5a0.dev-r2303 for Python 2.5 support.</li> 
    9595 
    96 <li> Added requirement of DecoratorTools due to upgrade of PyProtocols which  
     96<li> Added requirement of DecoratorTools due to upgrade of PyProtocols which 
    9797  deprecates functions used in decorator.py.</li> 
    9898</ul> 
     
    109109<li> paginate decorator now supports SA, improves sorting and fixes problems 
    110110  with CompoundWidget. Thanks to randall@tnr.cc and sbr77. #2404</li> 
    111 <li> Catwalk now supports SQLMultipleJoin/SQLRelatedJoins. Thanks to Chris Arndt  
     111<li> Catwalk now supports SQLMultipleJoin/SQLRelatedJoins. Thanks to Chris Arndt 
    112112  #2382</li> 
    113113<li> more docstring for widgets package #2355</li> 
     
    119119<li> Identity logout  now works properly when using ``set_identity_user`` #1245. 
    120120  Thanks to Felix Schwarz</li> 
    121 <li> set right default encoding 'utf-8' instead of 'utf8' which broke  
     121<li> set right default encoding 'utf-8' instead of 'utf8' which broke 
    122122  XmlHttpRequest in IE. Thanks Simon King #2408</li> 
    123123<li> workaround for MySQLdb imcompatibilty with MySQL 4.1. Thanks to Felix Schwarz 
     
    128128<li> fixes for FR locale in JavaScript for CalendarPicker. Thanks to Florent Aide 
    129129  #2370</li> 
    130 <li> various test case fixes. Thanks to Christoph Zwerschke, Felix Schwarz  
     130<li> various test case fixes. Thanks to Christoph Zwerschke, Felix Schwarz 
    131131  #2366 #2374 #2376</li> 
    132 <li> adapt tests to changes in Kid 0.9.4. Thanks to Jeff Hinrichs and  
     132<li> adapt tests to changes in Kid 0.9.4. Thanks to Jeff Hinrichs and 
    133133  Christoph Zwerschke #2364</li> 
    134134  <li> reverted #2256 which caused a RuntimeError #2340</li> 
     
    150150    <li> now possible to pass any option (besides dburi and echo) to sqlalchemy 
    151151        engine. Thanks to elftherios and Lee McFadden #2318 #2320</li> 
    152     <li> now possible to place test specific configuration in "test.cfg". Thanks to  
     152    <li> now possible to place test specific configuration in "test.cfg". Thanks to 
    153153        Tim Freund #2263</li> 
    154154    <li> support testing the code that uses identity. Thanks to Max Ischenko and 
     
    159159    <p><em>Features</em></p> 
    160160<ul> 
    161     <li> now possible to add variables to the root template namespace via  
     161    <li> now possible to add variables to the root template namespace via 
    162162        turbogears.view.root_variable_providers. Thanks Arnar Birgisson #2261</li> 
    163163    <li> turbogears.database.run_with_transaction is now a MultiorderGenericFunction to 
     
    173173    <li> Fix implicit transactions for SQLAlchemy. Thanks to Lee McFadden #2322</li> 
    174174    <li> Various CSS fixes for DataGrid. Thanks Florent Aide #2316</li> 
    175     <li> FeedController is now a Controller so tg.url works properly and fixed missing  
     175    <li> FeedController is now a Controller so tg.url works properly and fixed missing 
    176176        import in feed.py .Thanks Florent Aide #2310 #2312</li> 
    177177    <li> Looser Enum implementation taht works better with ToscaWidgets #2303</li> 
     
    181181    <li> throwing an identity.IdentityException inside a controller method is now 
    182182      caught by identity.SecureResource #2250</li> 
    183     <li> various test case fixes. Thanks to Felix Schwarz, Joost Moesker,  
     183    <li> various test case fixes. Thanks to Felix Schwarz, Joost Moesker, 
    184184      Jeff Kowalczyk #2247 #2266 #2268 #2314</li> 
    185185    <li> 'logout' method in SQLObjectIdentity was setting read-only property. Does not 
     
    191191    <p>Alberto Valverde, Joost Moesker, John M. Camara, Dan Jacob, Arnar Birgisson, Ksenia Marasanova, Felix Schwarz, Tim Freund, Max Ischenko, Fred Lin, Florent Aide, Jeff Kowalczyk, elftherios, Lee McFadden, Kevin Dangoor</p> 
    192192 
    193      
     193 
    194194    <h2 id="10b2_novembe_30_2006">1.0b2 (November 30, 2006):</h2> 
    195195 
     
    286286    <li>setuptools 0.6c2</li> 
    287287    </ul> 
    288      
     288 
    289289    <h2 id="09a9_august_17_2006">0.9a9 (August 17, 2006):</h2> 
    290290 
     
    333333    templates)</li> 
    334334    </ul> 
    335      
     335 
    336336    <h2 id="09a7_july_19_2006">0.9a7 (July 19, 2006)</h2> 
    337337 
     
    341341    <li>Former LocalizableJSLink is now CalendarLangFile. New LocalizableJSLink is 
    342342    simpler but backwards-incompatible.</li> 
    343     <li>Catwalk no longer accepts an allowHost argument.  
     343    <li>Catwalk no longer accepts an allowHost argument. 
    344344    To restrict access to it use Identity.SecureObject instead.</li> 
    345345    </ul> 
     
    384384    <li><code>DateTimeConverter</code> now handles dates &lt; 1900.</li> 
    385385    <li>Catwalk now handles gracefully UnicodeCols.</li> 
    386     <li>QUICKSTART: <code>start-project.py</code> now detects correct python binary&#8217;s path in  
     386    <li>QUICKSTART: <code>start-project.py</code> now detects correct python binary&#8217;s path in 
    387387    the system.</li> 
    388388    <li>Kid&#8217;s base templates are now (re)loaded properly.</li> 
     
    409409    <p>(My apologies if your name belongs here and is not!)</p> 
    410410 
    411     <p>Roger Demetrescu, Elvelind Grandin, Rune Hansen, Sean De La Torre,  
    412     Alberto Valverde, Max Ischenko, Joseph Tate, Elvelind Grandin,  
     411    <p>Roger Demetrescu, Elvelind Grandin, Rune Hansen, Sean De La Torre, 
     412    Alberto Valverde, Max Ischenko, Joseph Tate, Elvelind Grandin, 
    413413    Charles Duffy, Matt Good, Ksenia Marasanova.</p> 
    414414 
    415      
     415 
    416416    <h2 id="09a6_may_9_2006">0.9a6 (May 9, 2006)</h2> 
    417417 
     
    427427    <li>In widgets, if you were using a dictionary as a params be aware that now 
    428428    the dictionary is not updated at construction or display/render time but 
    429     simply replaced with the new one.  
    430     If you were using it to provide default attributes for your widget, take a  
     429    simply replaced with the new one. 
     430    If you were using it to provide default attributes for your widget, take a 
    431431    look at how the TableForm does that.</li> 
    432432    </ul> 
     
    440440    precision.)</li> 
    441441    <li>tg-admin info shows which eggs require TurboGears</li> 
    442     <li><p>In widgets, SelectionField now supports grouped options,  
     442    <li><p>In widgets, SelectionField now supports grouped options, 
    443443    SingleSelectField and MultipleSelectField widgets take advantage of this 
    444444    to provide an optgroup tag. The format of a grouped options list is like 
     
    503503    <p>Max Ischenko, Claudio Martinez, Matt Good, Rune Hansen, Michele Cella, 
    504504    Jorge Godoy, Alberto Valverde González, Simon Belak, Jeroen Dekkers, 
    505     Mark Ramm-Christensen, Ronald Jaramillo,  
    506     Richard Standbrook, Roger Demetrescu, Patrick Lewis,  
     505    Mark Ramm-Christensen, Ronald Jaramillo, 
     506    Richard Standbrook, Roger Demetrescu, Patrick Lewis, 
    507507    Jorge Vargas, Bob Kuehne.</p> 
    508      
     508 
    509509    <h2 id="09a5_april_29_2006">0.9a5 (April 29, 2006)</h2> 
    510510 
     
    648648    Joseph Tate, Philip Walls, Bob Ippolito, Steve Bergman, Andrey Lebedev, 
    649649    Brian Beck, Roger Demetrescu.</p> 
    650      
     650 
    651651    <h2 id="09a3_april_4_2006">0.9a3 (April 4, 2006)</h2> 
    652652 
     
    697697 
    698698    <p>This update brought to you by Michele Cella, Jeff Watkins, Simon Davy, 
    699     Baruch Even, Simon Belak, Claudio Martinez, Max Ischenko, Jason Chu,  
    700     Roger Demetrescu, Joost Moesker, plus Phillip Eby for setuptools  
     699    Baruch Even, Simon Belak, Claudio Martinez, Max Ischenko, Jason Chu, 
     700    Roger Demetrescu, Joost Moesker, plus Phillip Eby for setuptools 
    701701    and Remi Delon and the others working on CherryPy.</p> 
    702      
     702 
    703703    <h2 id="09a2_march_27_2006">0.9a2 (March 27, 2006)</h2> 
    704704 
     
    713713    <li>If you used CompoundWidgets in 0.9a1, &#8220;widgets&#8221; has changed to 
    714714    &#8220;member_widgets&#8221;.</li> 
    715     <li>If you are using a Form or a FieldSet widget you must explicitly pass  
    716     the &#8220;fields&#8221; parameter, the first positional parameter expected  
     715    <li>If you are using a Form or a FieldSet widget you must explicitly pass 
     716    the &#8220;fields&#8221; parameter, the first positional parameter expected 
    717717    since 0.9a2 is &#8220;name&#8221;.</li> 
    718     <li>If you are using a Form or a FieldSet widget with a custom template  
    719     you must update your template accordingly to the new templates  
     718    <li>If you are using a Form or a FieldSet widget with a custom template 
     719    you must update your template accordingly to the new templates 
    720720    TG is using.</li> 
    721721    </ul> 
     
    724724 
    725725    <ul> 
    726     <li>WidgetsDeclaration (introduced in 0.9a1) has been renamed WidgetsList  
     726    <li>WidgetsDeclaration (introduced in 0.9a1) has been renamed WidgetsList 
    727727    for clarity.</li> 
    728728    <li>turbogears.config now has get() and update() functions that should 
     
    730730    was made knowing that there will be more powerful, TurboGears-specific 
    731731    configuration in TurboGears 1.1.</li> 
    732     <li>The field_for method of a Form (introduced in 0.9a1) has been  
    733     deprecated and it&#8217;s use is highly discouraged and error prone,  
     732    <li>The field_for method of a Form (introduced in 0.9a1) has been 
     733    deprecated and it&#8217;s use is highly discouraged and error prone, 
    734734    use display_field_for or render_field_for instead.</li> 
    735     <li>In the turbogears.view module variableProviders has been renamed  
     735    <li>In the turbogears.view module variableProviders has been renamed 
    736736    variable_providers.</li> 
    737737    <li>turbogears.fastdata.formmaker&#8217;s sqlwidgets function (introduced in 
     
    745745    you to define different output formats (even with different template 
    746746    engines) that can be chosen via tg_format or the Accept header.</li> 
    747     <li>New AjaxGrid widget provides a grid in JavaScript that is populated via  
     747    <li>New AjaxGrid widget provides a grid in JavaScript that is populated via 
    748748    an Ajax call.</li> 
    749     <li>Three new base widgets to manage forms have been introduced:  
     749    <li>Three new base widgets to manage forms have been introduced: 
    750750    CompoundFormField, RepeatingFormField and FormFieldsContainer.</li> 
    751751    <li>Experimental support for SQLAlchemy. For more complicated databases 
    752     or certain database requirements, SQLAlchemy handles the database more  
     752    or certain database requirements, SQLAlchemy handles the database more 
    753753    gracefully. The main database layer for TurboGears remains SQLObject 
    754754    and SQLObject is more fully supported within TurboGears. However, 
    755755    for those who need it, SQLAlchemy support is there.</li> 
    756     <li>display_field_for and render_field_for are automatically added to the  
     756    <li>display_field_for and render_field_for are automatically added to the 
    757757    template scope of any FormFieldsContainer widget and can be used to 
    758758    easily display/render a field with the corrects value and options.</li> 
     
    833833    <li>Various fixes for CatWalk&#8217;s database access (see tickets 
    834834    #568, #249, #213, #618)</li> 
    835     <li>ModelDesigner and admi18n can find your model.py file even if you  
     835    <li>ModelDesigner and admi18n can find your model.py file even if you 
    836836    change your package name at quickstart time.</li> 
    837837    </ul> 
     
    851851    Elvelind Grandin, Ronald Jaramillo, Simon Belak, Jeff Watkins, 
    852852    Alberto Valverde González, Jason Chu, Owen Mead-Robins, 
    853     Dan Weeks, Dennis Brakhane, Heikichi Umahara, Patrick Lewis,  
     853    Dan Weeks, Dennis Brakhane, Heikichi Umahara, Patrick Lewis, 
    854854    Joost Moesker, Roger Demetrescu, Liza Daly.</p> 
    855855 
     
    882882    <li>In templates the "std" object that holds common values and functions 
    883883    has been changed to "tg".</li> 
    884     <li>turbogears.controllers.Root has now become  
     884    <li>turbogears.controllers.Root has now become 
    885885    turbogears.controllers.RootController for clarity's sake. Root 
    886886    continues to work, but its use is deprecated.</li> 
     
    905905    Thanks to Ronald Jaramillo.</li> 
    906906    <li>Identity management and access control now provided via 
    907     turbogears.identity module. Includes basic classes for User, Group,  
     907    turbogears.identity module. Includes basic classes for User, Group, 
    908908    and Permission objects via turbogears.identity.model. Thanks to 
    909909    Jeff Watkins.</li> 
     
    918918    <li>Error handling for a method can be specified with an error_handler 
    919919    decorator thanks to Simon Belak.</li> 
    920     <li>TurboGears now has a feed object that can generate rss2.0, atom0.3  
     920    <li>TurboGears now has a feed object that can generate rss2.0, atom0.3 
    921921    and atom1.0 feeds</li> 
    922922    <li>Template encodings other than utf-8 can be selected with the new 
     
    933933    package, you can use "yourpackage.templates.templatename" <em>or</em> 
    934934    ".templates.templatename". Thanks to David Bernard.</li> 
    935     <li>New commands can be added to tg-admin via the turbogears.command  
     935    <li>New commands can be added to tg-admin via the turbogears.command 
    936936    entry point. Thanks to Elvelind Grandin.</li> 
    937937    <li>Controllers that subclass controllers.Controller (including the 
     
    10051005    Jared Kuolt, Paul Clifford, Lee McFadden, Michele Cella, Karl Guertin, 
    10061006    Max Ischenko, Mark Godfrey, Simon Belak, Jorge Godoy, Patrick Lewis, 
    1007     Joey Smith, David Bernard, Simon Davy, Gary Godfrey, Jason Chu,  
    1008     Liza Daly, Ryan Forsythe, Jeremy Jones, Egor Cheshkov, Claudio Martinez,  
    1009     Leandro Lucarella, Bob Ippolito, Alberto Valverde González,  
    1010     Brian Bockelman, Stephen Thorne, Robin Bryce, Ksenia Marasanova,  
     1007    Joey Smith, David Bernard, Simon Davy, Gary Godfrey, Jason Chu, 
     1008    Liza Daly, Ryan Forsythe, Jeremy Jones, Egor Cheshkov, Claudio Martinez, 
     1009    Leandro Lucarella, Bob Ippolito, Alberto Valverde González, 
     1010    Brian Bockelman, Stephen Thorne, Robin Bryce, Ksenia Marasanova, 
    10111011    Ori Avtalion, Martina Oefelein, Ian Bicking, Rick Richardson, 
    10121012    Luis Bruno, Joost Moesker, BJörn Lindqvist.</p> 
    10131013 
    10141014    <p>A special thanks to Cliff Wells of Develix for sponsoring a bug bounty!</p> 
    1015      
     1015 
    10161016 
    10171017    <h2 id="089_february_6_2006">0.8.9 (February 6, 2006)</h2> 
     
    10201020    <li>Fixes a warning message that appears with each quickstart</li> 
    10211021    </ul> 
    1022      
     1022 
    10231023    <h2 id="088_january_10_2006">0.8.8 (January 10, 2006)</h2> 
    10241024 
     
    11391139    has become tg_format and tg_html has become tg_template.)</li> 
    11401140    <li>The StringBoolean validator (which has moved into FormEncode proper) 
    1141     now returns strings for from_python. For example, from_python(True)  
     1141    now returns strings for from_python. For example, from_python(True) 
    11421142    now returns 'true'. It used to return True.</li> 
    11431143    <li>turbogears-admin.py is now called tg-admin and is automatically 
     
    11781178    <li>validators can now be specified with a dict (the 0.5 way) or with a 
    11791179    FormEncode Schema, which provides more options. By Fabian Neumann.</li> 
    1180     <li>Quickstart now provides a basic static files skeleton. By  
     1180    <li>Quickstart now provides a basic static files skeleton. By 
    11811181    Elvelind Grandin.</li> 
    1182     <li>Added config setting to determine Kid's output format (HTML/XHTML).  
     1182    <li>Added config setting to determine Kid's output format (HTML/XHTML). 
    11831183    By Fabian Neumann.</li> 
    1184     <li>In quickstart, project-start.py now takes a config file on the  
     1184    <li>In quickstart, project-start.py now takes a config file on the 
    11851185    command line. By Elvelind Grandin.</li> 
    1186     <li>project-start.py is also made executable automatically. By  
     1186    <li>project-start.py is also made executable automatically. By 
    11871187    Fabian Neumann.</li> 
    11881188    <li>Added turbogears.tests.util.call function to allow you to call a 
     
    12311231    <h2>0.5.1 (Sep 17, 2005)</h2> 
    12321232 
    1233     <p>Relaxed version requirements and changed version numbering for  
     1233    <p>Relaxed version requirements and changed version numbering for 
    12341234    included ElementTree packages to ease installation troubles</p> 
    12351235 
     
    12391239    <li>Initial public release.</li> 
    12401240    </ul> 
    1241      
     1241</div> 
    12421242</body> 
    12431243</html> 
  • website/newdocs/about/cherrypy.html

    r596 r3147  
    55<head> 
    66  <meta content="text/html; charset=UTF-8" http-equiv="content-type" /> 
    7   <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link>  
     7  <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link> 
    88  <title>TurboGears: CherryPy Web Controller Framework</title> 
    99</head> 
    1010 
    1111<body> 
     12<div id="page"> 
    1213    <h1>CherryPy: Going to and from the web has never been so easy!</h1> 
    1314    <h1 py:def="sidetitle">CherryPy in-an-instant</h1> 
     
    1617        <h3>Home page</h3> 
    1718        <p><a href="http://cherrypy.org" target="_blank">cherrypy.org</a></p> 
    18          
     19 
    1920        <h3>Fearless Leader</h3> 
    2021        <p>Remi Delon</p> 
    21          
     22 
    2223        <h3>Claim-to-fame</h3> 
    2324        <p>Write code for the web through standard Python objects!</p> 
    24          
     25 
    2526        <h3>What's so great?</h3> 
    2627        <p>Every URL just points to a method on an object. CherryPy looks at the URL, finds the right object for you and turns query parameters and POST data into parameters for the method it finds! It's also got a great filter system that lets you run code before and after methods are called.</p> 
    2728    </div> 
    28      
     29 
    2930    <p>When you start using CherryPy, you're not going to miss CGI, Java Servlets, or whatever it is you were doing before <em>at all</em>. CherryPy makes hooking code up to the web as easy as writing methods in Python. You just set an object as CherryPy's root object, and all of your URLs cleanly map to a method inside of that root object. Don't believe me? Look at Hello World:</p> 
    30      
     31 
    3132    <textarea name="code" class="py" rows="6" cols="30"><![CDATA[ 
    3233import cherrypy 
    3334 
    3435class MyRoot: 
    35      
     36 
    3637    @cherrypy.expose() 
    3738    def index(self, who="World"): 
     
    3940]]> 
    4041</textarea> 
    41      
     42 
    4243    <p>Pointing your browser at http://yourserver/?who=Foobar, you'll see "Hello, Foobar!" in your browser. It's that easy! CherryPy automatically calls the "index" method for objects that you hook up to your root, and any method that you expose becomes automatically available as well! CherryPy also lets you define a "default" method that picks up any request which didn't match one of the methods you had defined. The default method makes it easy to do blog-like URLs: 2005/09/16/cherrypy_rocks.</p> 
    43      
     44 
    4445    <p>And, did you notice that MyRoot doesn't subclass any other class? CherryPy leaves you free to set up your objects however it makes sense to do so!</p> 
    45      
     46 
    4647    <p>CherryPy also gives you sessions, "filters" that can change data at various points of the request cycle, and a built-in zippy webserver.</p> 
    47      
     48 
    4849    <p>CherryPy is a very natural and fun way to write webapps in Python.</p> 
    49      
     50 
    5051    <p><a href="index.html">Return to About TurboGears</a>.</p> 
    51      
     52 
    5253    <script src="${root}sh/shCore.js"></script> 
    5354    <script src="${root}sh/shBrushPython.js"></script> 
     
    5556        dp.SyntaxHighlighter.HighlightAll('code'); 
    5657        </script> 
     58</div> 
    5759</body> 
    5860</html> 
  • website/newdocs/about/extras.html

    r1861 r3147  
    55<head> 
    66  <meta content="text/html; charset=UTF-8" http-equiv="content-type" /> 
    7   <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link>  
     7  <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link> 
    88  <title>TurboGears: Supporting Cast</title> 
    99</head> 
    1010 
    1111<body> 
     12<div id="page"> 
    1213    <h1>Other projects used by TurboGears</h1> 
    1314    <h1 py:def="sidetitle">Other parts</h1> 
     
    1516        <h3><a href="http://effbot.org/zone/element-index.htm" target="_blank">ElementTree</a></h3> 
    1617        <p><a href="http://online.effbot.org/" target="_blank">Fredrik Lundh</a>'s fast and easy XML parser and generator library.</p> 
    17          
     18 
    1819        <hr/> 
    1920        <h3><a href="http://formencode.org" target="_blank">FormEncode</a></h3> 
    2021        <p><a href="http://blog.ianbicking.org/" target="_blank">Ian Bicking</a>'s validation and conversion package.</p> 
    21          
     22 
    2223        <hr/> 
    2324        <h3><a href="http://somethingaboutorange.com/mrl/projects/nose/" target="_blank">Nose</a></h3> 
    2425        <p><a href="http://www.blueskyonmars.com/" target="_blank">Jason Pellerin</a>'s unittest extension</p> 
    25          
     26 
    2627        <hr/> 
    2728        <h3><a href="http://json-py.sourceforge.net/" target="_blank">json-py</a></h3> 
    28          
     29 
    2930        <p><a href="http://patricklogan.blogspot.com/" target="_blank">Patrick Logan</a>'s JSON converter for Python.</p> 
    3031    </div> 
    31      
     32 
    3233    <p>When you download TurboGears, you get several packages in the bargain. Though the four main packages are the ones you'll interact most directly with, these other packages are also working behind the scenes and available for your use to make your life better.</p> 
    33      
     34 
    3435    <h2><a name="elementtree"></a>ElementTree</h2> 
    35      
     36 
    3637    <p>For anyone who's ever had to write code to the W3C interfaces in Java, you know how difficult working with XML <em>can</em> be. ElementTree provides a programming interface that is far easier for common XML tasks. It is not the be-all and end-all XML library, but it's a very practical approach to much of what you'll need to do.</p> 
    37      
     38 
    3839    <p>TurboGears also includes cElementTree, which is an implementation of the ElementTree API in C. cElementTree is <em>very</em> fast.</p> 
    39      
     40 
    4041    <p><a href="kid.html">Kid</a> uses ElementTree to parse and work with your templates.</p> 
    41      
     42 
    4243    <p>Here's an example of ElementTree usage from the ElementTree site:</p> 
    43      
     44 
    4445    <textarea name="code" class="py" rows="6" cols="30"><![CDATA[ 
    4546from elementtree.ElementTree import Element, SubElement, ElementTree 
     
    6364]]> 
    6465</textarea> 
    65      
     66 
    6667    <h2><a name="formencode"></a>FormEncode</h2> 
    67      
     68 
    6869    <p>When data comes in from the web, you get a blob of strings that map to whatever was on the form the user submitted. Odds are that what you'd like to have is something different. Perhaps you want a boolean instead of the string "True" or perhaps you want an int instead of the string "42". Or, maybe you need to verify that the user entered "301-555-1212" for their phone number (let's ignore the usability issues of that, shall we?).</p> 
    69      
     70 
    7071    <p>FormEncode provides a framework for converting incoming values to their appropriate Python versions and converting Python values to whatever is needed on the other end. In the process of doing the conversion, it also makes sure that the values are valid and provides a means to describe what the problem is.</p> 
    71      
     72 
    7273    <p>FormEncode is used by SQLObject to do conversions to and from database types. You'll also encounter it in TurboGears directly when using the validation feature.</p> 
    73      
     74 
    7475    <p>Here's a quick example of using a form encode validator:</p> 
    75      
     76 
    7677    <pre><![CDATA[ 
    7778>>> import formencode 
     
    8586Invalid: Please enter an integer value 
    8687]]></pre> 
    87      
     88 
    8889    <h2><a name="nose"></a>Nose</h2> 
    89      
     90 
    9091    <p>Python's standard unittest module is based on the venerable JUnit. It's a straightforward framework, but there are some usability niggles here and there.</p> 
    91      
     92 
    9293    <p>For example, it's pretty common to have a TestSuite that covers your whole project. It's a good idea to run the full TestSuite frequently. Unfortunately, you have to keep that suite up-to-date by hand. TestGears provides a simple means to gather up all of the tests in your project. With nose, you can just run "nosetests" to gather up all of your tests.</p> 
    93      
     94 
    9495    <p>Even though writing a TestCase is easy, sometimes even that is more overhead than you really need. With Nose, if you put functions with names beginning with "test" in a file that begins with "test_", your tests will run automatically as part of the suite.</p> 
    95      
     96 
    9697    <h2><a name="json"></a>json-py</h2> 
    97      
     98 
    9899    <p><a href="http://json.org" target="_blank">JSON</a> (JavaScript Object Notation) specifies a way to represent data as nested hash tables, lists and simple values. For transmitting data to a browser for further manipulation, JSON has some significant advantages over XML: the syntax is native JavaScript so it's fast, can be interpreted directly via eval() and is supported equally by all browsers.</p> 
    99      
     100 
    100101    <p>The json-py library provides conversion routines to migrate simple values from Python to JSON and vice-versa.</p> 
    101102 
     
    105106        dp.SyntaxHighlighter.HighlightAll('code'); 
    106107        </script> 
     108</div>s 
    107109</body> 
    108110</html> 
  • website/newdocs/about/index.html

    r2346 r3147  
    99 
    1010<body> 
     11  <div id="page"> 
    1112    <h1>Create great web apps faster</h1> 
    12      
     13 
    1314    <p>That's it. That's the goal of TurboGears. That and to make it easier. The two goals are to create web apps faster and easier. And more fun. The three goals are to...</p> 
    14      
     15 
    1516    <p>How does TurboGears do it?</p> 
    16      
     17 
    1718    <ul> 
    1819        <li>By making it as easy as writing a method to expose functionality to the web</li> 
    1920        <li>By allowing you to seamlessly provide nice HTML <em>or</em> an API for JavaScript to work with</li> 
    20          
     21 
    2122        <li>By giving your designers room to work with any XHTML tool to create great layouts</li> 
    22          
     23 
    2324        <li>By letting you use your database without writing SQL</li> 
    24          
     25 
    2526        <li>By filling in gaps in JavaScript, so that you'll actually enjoy writing it!</li> 
    26          
     27 
    2728        <li>By using a language that is clear, concise and dynamic</li> 
    2829    </ul> 
     
    3839      <li><a href="sqlobject.html" class="more">SQLObject</a> lets you access your database as you would normal Python classes, without obscuring the database itself.</li> 
    3940    </ul> 
    40      
     41 
    4142    <p>Now that you know a bit about the parts of TurboGears, read more about <a href="turbogears.html">how TurboGears ties it all together</a>.</p> 
    42      
     43 
    4344    <p>But, wait! There's more!</p> 
    44      
     45 
    4546    <p>If TurboGears were a movie and the four projects above were the main actors, we'd still need key grips, caterers and the like. Here are some of the other bits of infrastructure needed for TurboGears:</p> 
    4647 
     
    5152        <li><a href="extras.html#json" class="more">json-py</a> does round trip conversions between Python and the <a href="http://json.org" target="_blank">JSON</a> format.</li> 
    5253    </ul> 
    53      
     54 
    5455    <h2>Plays well with others!</h2> 
    55      
     56 
    5657    <p>The TurboGears <a href="http://docs.turbogears.org/1.0/Philosophy">Project Philosophy</a> is all about building on the work of great open source projects, not replacing or supplanting them.</p> 
    57      
     58 
    5859    <p>All parts of TurboGears are released under <b>liberal open source licenses</b> that allow for use in both non-commercial <em>and</em> commercial projects. Whether your work is open source or closed source, TurboGears is free for your use.</p> 
    59      
     60 
    6061    <p>The complete detail is on the <a href="http://docs.turbogears.org/1.0/License">license page</a>.</p> 
    61      
     62 
    6263    <h2>1.0 is released</h2> 
    63      
     64 
    6465    <p>The recommended release of TurboGears is the 1.0. <a href="http://docs.turbogears.org/1.0/DevStatus">Read more about the development status</a>.</p> 
    65      
     66  </div> 
    6667</body> 
    6768</html> 
  • website/newdocs/about/kid.html

    r596 r3147  
    55<head> 
    66  <meta content="text/html; charset=UTF-8" http-equiv="content-type" /> 
    7   <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link>  
     7  <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link> 
    88  <title>TurboGears: Kid Template System</title> 
    99</head> 
    1010 
    1111<body> 
     12<div id="page"> 
    1213    <h1>Kid: Designer <em>and</em> programmer friendly templates</h1> 
    1314    <h1 py:def="sidetitle">Kid in-an-instant</h1> 
     
    1617        <h3>Home page</h3> 
    1718        <p><a href="http://kid.lesscode.org" target="_blank">kid.lesscode.org</a></p> 
    18          
     19 
    1920        <h3>Fearless Leader</h3> 
    2021        <p><a href="http://lesscode.org/" target="_blank">Ryan Tomayko</a></p> 
    21          
     22 
    2223        <h3>Claim-to-fame</h3> 
    2324        <p>Pythonic, XML-based Templating</p> 
    24          
     25 
    2526        <h3>What's so great?</h3> 
    2627        <p>Standard XHTML makes the templates easy-to-use for designers. The programming syntax is a no-brainer for Python programmers. Also includes an easy XSLT-like "match" command. Produces syntactically correct output.</p> 
    2728    </div> 
    28      
     29 
    2930    <p>Your designer will love you for using Kid. As far as they're concerned, they're just giving you XHTML that you put some extra stuff into. The designs they put together can even have sample data that hangs around and gets replaced by the real data when the time comes.</p> 
    30      
     31 
    3132    <p>OK, sure. Not everyone works with a designer. (I've seen lots of pages that prove that. I've <em>made</em> lots of pages that prove that!) That's OK... Kid is friendly for programmers, too.</p> 
    32      
     33 
    3334    <h2>It's just Python</h2> 
    34      
     35 
    3536    <p>If you were generating your output in straight Python, you could do something like this:</p> 
    36      
     37 
    3738    <textarea name="code" class="py" rows="6" cols="30"><![CDATA[ 
    3839print "<table>" 
     
    4445]]> 
    4546    </textarea> 
    46      
     47 
    4748    <p>In a Kid template, you just do it like this:</p> 
    48      
     49 
    4950    <textarea name="code" class="xhtml" rows="6" cols="30"><![CDATA[ 
    5051<table> 
     
    5556    ]]> 
    5657    </textarea> 
    57      
     58 
    5859    <p>The expressions in Kid's "for" and "if" commands are standard Python! Note also that the example above is the "designer-friendly" form that would have nice sample data to show in an editor or browser. If you want, you can use the more succinct "$${person.name}" instead of having the extra &lt;span&gt;.</p> 
    59      
     60 
    6061    <h2>Applying consistent templating throughout</h2> 
    61      
     62 
    6263    <p>Sure, we all use CSS these days to apply consistent style throughout our apps, but you still need a mechanism for consistent headers and footers. Kid provides a couple of useful ways to do this.</p> 
    63      
     64 
    6465    <h3>Template Inheritance</h3> 
    65      
     66 
    6667    <p>You can create a header in a "template function" in a master template that looks something like this:</p> 
    67      
     68 
    6869    <textarea name="code" class="xhtml"><![CDATA[ 
    6970<div py:def="header(title)"> 
     
    7374    ]]> 
    7475    </textarea> 
    75      
     76 
    7677    <p>Then, your individual templates will "extend" your master template and call the function to insert the header:</p> 
    7778    <textarea name="code" class="xhtml"><![CDATA[ 
     
    7980    ]]> 
    8081    </textarea> 
    81      
     82 
    8283    <h3>Matching</h3> 
    83      
     84 
    8485    <p>Kid has a great feature that gives you some of XSLT's power without XSLT's syntax: the "match" command. As in the previous example, you'd have your template extend a master template. However, rather than explicitly calling a header function, the master template will add the header through matching.</p> 
    8586    <textarea name="code" class="xhtml"><![CDATA[ 
     
    9091     ]]> 
    9192     </textarea> 
    92       
     93 
    9394     <p>By putting the code above in your master template, all you have to do is extend the master template for each separate page you make. The headers (and footers, if desired) will automatically be added. Plus, other changes could be made to the final document, if you need to!</p> 
    94      
     95 
    9596    <h2>I <em>really</em> want to write code in my template!</h2> 
    96      
     97 
    9798    <p>OK, if you must. Just don't tell anyone... Kid lets you do what you need to do. You can incorporate some Python directly into your template by enclosing it in &lt;?python?&gt;. Since this is a processing instruction, your template remains valid XHTML.</p> 
    98      
     99 
    99100    <h2>Kid won't give you garbage</h2> 
    100      
     101 
    101102    <p><em>Many</em> template systems make it possible to leave tags hanging or mismatched. With Kid, your template must be valid XML, so you're guaranteed to not have mismatched tags. Many browsers don't properly support XHTML. When the time comes to deliver your content to a web browser, TurboGears will transparently output HTML based on your XHTML template and your data.</p> 
    102      
     103 
    103104    <p><a href="index.html">Return to About TurboGears</a>.</p> 
    104      
    105      
     105 
     106 
    106107    <script src="${root}sh/shCore.js"></script> 
    107108    <script src="${root}sh/shBrushPython.js"></script> 
     
    110111        dp.SyntaxHighlighter.HighlightAll('code'); 
    111112        </script> 
     113</div> 
    112114</body> 
    113115</html> 
  • website/newdocs/about/license.html

    r836 r3147  
    99 
    1010<body> 
     11<div id="page"> 
    1112    <div py:def="sidetitle()">Licenses</div> 
    1213    <div py:def="sidetext()"> 
     
    2223    </div> 
    2324    <h1>TurboGears Licenses</h1> 
    24      
     25 
    2526    <p>Note that the following paragraphs are <b>not legal advice</b>. They are one person's interpretations of the software licenses involved. If you have any questions or concerns about the licenses, you should consult a lawyer.</p> 
    26      
     27 
    2728    <p>TurboGears is a <em>megaframework</em> that incorporates other open source projects. Each project that is included in TurboGears allows for closed source use, and the licenses are included here for convenience. The primary requirement made by the licenses is that you need to include the relevant copyright notices and licenses in your software. Including this file should be sufficient.</p> 
    28      
     29 
    2930    <p>Generally speaking, the parts of TurboGears allow you to not only include them with your work, but to modify them at will. The exception to this is SQLObject, which is released under the "LGPL" license. If you modify SQLObject itself, you need to make those changes available under the terms of the LGPL. This requirement has no impact on you at all if you just use SQLObject as it is included with TurboGears.</p> 
    30      
     31 
    3132    <h2><a name="turbogears">TurboGears</a></h2> 
    32      
     33 
    3334    <p>This is the <a href="http://www.opensource.org/licenses/mit-license.php">MIT license</a>:</p> 
    3435 
     
    4950 
    5051    <p>Copyright (c) 2005 Bob Ippolito.  All rights reserved.</p> 
    51      
     52 
    5253    <p>Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:</p> 
    53      
     54 
    5455    <p>The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.</p> 
    55      
     56 
    5657    <p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p> 
    57      
     58 
    5859 
    5960<h3>Academic Free License v. 2.1</h3> 
     
    130131 
    131132    <p>THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</p> 
    132      
     133 
    133134    <h2><a name="lgpl">SQLObject</a></h2> 
    134      
     135 
    135136    <H2><A NAME="SEC1" HREF="#TOC1">GNU LESSER GENERAL PUBLIC LICENSE</A></H2> 
    136137 
     
    630631 
    631632    <h2><a name="formencode">FormEncode and PasteScript</a></h2> 
    632      
     633 
    633634    <p>FormEncode is copyright 2004-2006 by Ian Bicking. PasteScript is copyright 2005-2006 by Ian Bicking. RuleDispatch is copyright 2005 Phillip Eby. All three are released under the terms of the Python Software Foundation license.</p> 
    634635    <p> 
     
    865866    ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT 
    866867    OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.</p> 
    867  
    868 </body> </html> 
    869      
     868</div> 
     869</body> 
     870</html> 
  • website/newdocs/about/mochikit.html

    r596 r3147  
    55<head> 
    66  <meta content="text/html; charset=UTF-8" http-equiv="content-type" /> 
    7   <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link>  
     7  <link type="text/css" rel="stylesheet" href="${root}sh/SyntaxHighlighter.css"></link> 
    88  <title>TurboGears: MochiKit JavaScript library</title> 
    99</head> 
    1010 
    1111<body> 
     12<div id="page"> 
    1213    <h1>About MochiKit</h1> 
    13      
     14 
    1415    <h1 py:def="sidetitle()">MochiKit in-an-instant</h1> 
    1516    <div class="sidecont" py:def="sidetext()"> 
     
    2324        <h3>What's so great?</h3> 
    2425        <p>Clean design, practical and easy functionality, documentation, automated tests</p> 
    25     </div>     
     26    </div> 
    2627    <p>There are <em>lots</em> of JavaScript libraries out there. One of the first things you'll notice about MochiKit is that you're not left guessing about how to use it or what's in there. Unlike the vast majority of JavaScript libraries, there is <a href="http://www.mochikit.com/doc/html/MochiKit/index.html" target="_blank">actual English text</a> to describe how to use it.</p> 
    27      
     28 
    2829    <p>And, once you start looking at how to use the functions it contains, you'll see that there's a whole bunch of useful stuff in there. MochiKit's creator, Bob Ippolito, is well-known in Python circles and has created a library that is natural to use for both Python and JavaScript programmers. It provides functions for performing asynchronous operations (<a href="http://www.adaptivepath.com/publications/essays/archives/000385.php">AJAX</a>, anyone?), logging (unless you really love alert boxes!), working with lists of data (and who doesn't), plus some amazing DOM tools.</p> 
    29      
     30 
    3031    <h2>See for yo