hwms / dirty Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/dirty
Automatically exported from code.google.com/p/dirty
it would be great to have RawString counterpart to include XML data from a file.
let's say we have RawXMLFile class to inject the file XML data, i.e:
f1 = open('s01.xml')
f2 = open('s02.xml')
xml.root(
xml.desc('Data from system 01'), xml.data(RawXMLFile(f1)),
xml.desc('Data from system 02'), xml.data(RawXMLFile(f2)),
)
of course, now we can create a generator:
def raw_file(f):
while True:
data = f.read(4096) # do not use f.readline
# in case of large, one line XML documents
if len(data) == 0:
break
yield RawString(data)
but it would be great if dirty recognized RawXMLFile
and copied the file (f1 and f2 above) without need
of creating RawString instances.
Original issue reported on code.google.com by [email protected]
on 7 Oct 2011 at 10:12
It is more likely that I don't know what I am doing or there is a work around
already, but I can not find it anyway.
Using Python 2.7 (not sure if this matters).
I am trying to put
<meta http-equiv="refresh" content="15" />
in the header.
The line:
meta( 'http-equiv="refresh" content="5"' )
outputs:
<meta>http-equiv="refresh" content="5"</meta>
which is interpreted by Chrome as body text (even though it is not in the
body). (sorry I did not check other browsers)
But this:
meta( http-equiv="refresh", content="5" )
is a problem for python because a '-' is not allowed in an argument name.
Original issue reported on code.google.com by [email protected]
on 6 Oct 2014 at 5:10
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.