Search
Code Directory
 ASP
 ASP.NET
 C/C++
 CFML
 CGI/PERL
 Delphi
 Development
 Flash
 HTML
 Java
 JavaScript
 Pascal
 PHP
 Python
 SQL
 Tools
 Visual Basic & VB.NET
 XML
New Code
Excel Add-in for DB2 1.7
wolfSSL 4.0.0
EntityDAC Express 2.2
SecureBridge 9.1
C# HTML to PDF 2019.6.5
PHP Ecommerce Script 3.6
Devart SSIS Data Flow Components 1.11
dbForge Data Compare for PostgreSQL 3.2.15
OrgChart JS 4.9.7
iScripts CyberMatch 1.3.3
AnyGantt JS Gantt Charts 8.7.0
Database Workbench Pro 5.6.8
SentiMask SDK Trial 2.0.193121
dbForge Studio for SQL Server 5.8
ODBC Driver for ASE 2.1.2
Top Code
iScripts CyberMatch 1.3
SecureBridge 8.0
dbForge Data Compare for PostgreSQL 2.0
dbForge Studio for SQL Server 5.5
Database Workbench Pro 5.6.8
PHP Ecommerce Script 1.0.4
Availability Booking Calendar PHP 1.0
ATN Site Builder 3.0
ATN Resume Finder 2.0
Excel Add-in for DB2 1.1
PHP Review Script 1.0
ICPennyBid Penny Auction Script 4.0
EntityDAC Express 2.2
MLM Software ONE 1.5.46
Scholarship Award System 1.2.71b
Top Rated
VisualNEO Web 2018.12.15
Azizi search engine script PHP 4.1.10
Paste phpSoftPro 1.4.1
Extreme Injector 3.7
Deals and Discounts Website Script 1.0.2
ADO.NET Provider for ExactTarget 1.0
Solid File System OS edition 5.1
Classified Ad Lister 1.0
Aglowsoft SQL Query Tools 8.2
Invoice Manager by PHPJabbers 3.0
ICPennyBid Penny Auction Script 4.0
PHP Review Script 1.0
ATN Resume Finder 2.0
ATN Site Builder 3.0
Availability Booking Calendar PHP 1.0
Serve PageTemplates with Medusa 
File ID: 66691






Serve PageTemplates with Medusa 
Download Serve PageTemplates with Medusa http://code.activestate.com/recipes/157501-serve-pagetemplates-with-medusa/?in=lang-pythonReport Error Link
License: Freeware
Downloads: 1
Submit Rating:
Serve PageTemplates with Medusa  Description
Description: This recipe combines the delicious PageTemplates package with the flavorful Medusa package to serve up rendered PageTemplates from the file system.

Why not just use Zope you say? As far as I know, the current Zope release isn't an option with Python 2.2 code. The project for which this recipe was devised requires Python 2.2.

Ingredients you'll need:

Python 2.2. If you're using 2.1, try Zope instead, as it does everything this recipe can do plus a whole lot more.
ExtensionClass and friends. There is more than one way to get ExtensionClass installed, but the method I've used successfully is to install StandaloneZODB. That package is available here: http://www.zope.org/Products/StandaloneZODB
PageTemplates, TAL, and ZTUtils packages. These are available in the Zope source releases but must be installed manually. Again, there's more than one way to make these packages available in your system. The method I've used is to copy the package directories from the Zope source archive into the Python lib/site-packages/ directory. The Zope source is available from this link: http://www.zope.org/Products
Medusa. I used Medusa 0.5.2 to develop this recipe, but you may have an equally pleasant experience with other versions. You can get Medusa here: http://oedipus.sourceforge.net/medusa/
A Medusa startup script. As with all Medusa handlers, you must explicitly construct a PageTemplates handler and associate it with an HTTP server. You can modify a copy of the sample startup script included with Medusa or create your own.
Some PageTemplates. The code below reads PageTemplates markup from files stored in your file system. Give your markup files a ".pt" or ".ptx" extension, and the handler will try to render them as PageTemplates before returning their markup.

Once you have all these items in place, modify your Medusa start up script:

Save the code below as "pagetemplate_handler.py", and bring it into your script: import pagetemplate_handler
Construct a pagetemplate_handler.pagetemplate_handler, pagetemplate_handler.pagetemplate_xml_handler, or both. These types need a filesystem object, just like the default_handler.
Associate your pagetemplate_handler with your HTTP server.

License: Freeware

Related: Web

O/S:Windows

Downloads: 1



More Similar Code

MobilePress is a WordPress plugin that will render your WordPress blog on mobile handsets, with the ability to use customized themes. Built into MobilePress is the ability to track your mobile sites analytics and serve ads with Aduity.com.

Integration with Aduity.com enables you to serve ads from some of the biggest mobile ad networks such as Admob, Quattro Wireless, Buzzcity and InMobi. You can also serve you own managed ads. You...



The script can eliminate the possibility of unintentional fraud by optionally using javascript to output ads (with URLs divided into small chunks). This will prevent any automatic software (such as search engine spiders, etc) from following such...



This section demonstrates remote method calls between two
machines (or processes) using the XML-RPC protocol. A complete
example of working client/server code is provided.



Now a day's wedding invitation design has become really good business, you can earn brilliant money by launching a site with our wedding design script. We also provide technical support through out installation.

Wedding invitation...



The Banner Serve is a simple banner manager with which you will be able to place your banners on remote sites. With this script you can get complete statistics regarding each user and each banner and also it collects information for each banner...



With the inClick Ad Server, you can serve text ads on your site in a pay-per-click bid-for-placement environment. Beyond just a simple ad server, inClick allows you to serve ads based on keywords and content, unlimited zones, and more. Become an...



Newsletter Mx is bundled with Html Editor for Composing Newsletters Online (insert tables, Form elements, Add images, Word Spell Checker and support for 22+ languages and lot more. If the Editor does not serve your purposes then Create your own...



AntiSpam's primary purpose is to serve as a programming exercise to test an ostensibly primitive method of dealing with unwanted email (SPAM).

The current release works with Outlook Express 6, but future versions will include...



The files contained in this zip file
serve as an introduction to using RTDX technology from Texas Instruments with Simulink for the purpose of verifying that that your Simulink simulation is running the same way as your DSP implementation....



phpMyWebServices is a framework that can serve dotNET-like Web services coded in PHP, so it works on all apache/php servers (MySQL not required).

With it, you can easy host any webservice on the most of free hosting services !!!

User Review for Serve PageTemplates with Medusa
- required fields
     

Please enter text on the image