Erik van Blokland 3646055ea2 initial import
git-svn-id: http://svn.robofab.com/trunk@1 b5fa9d6c-a76f-4ffd-b3cb-f825fc41095c
2008-01-07 17:40:34 +00:00

23 lines
510 B
Python

class ScriptTag(BaseTag):
"""Tag that contains Javascript code."""
def __init__(self, parent, attrs):
BaseTag.__init__(self, parent, attrs)
def _emit(self, page, target=None):
page.scripts.append(content(self))
class PHPTag(BaseTag):
"""Tag that contains php code.
Automatically sets the extension of the final file to .php
"""
def __init__(self, parent, attrs):
BaseTag.__init__(self, parent, attrs)
def _emit(self, page, target=None):
target.append("<?php %s ?>"%content(self))