perl shake.pl lear.htm > learout.htm
Adding the style sheet as instructed produced results for me, every 5th line is numbered on the right hand side.
Update: should you wish line numbers to be displayed at a different frequency the part of the code which deals with this is fairly simple to alter.
Update 2: Observations from your youtube video:
- The output file is larger than the input file. This is good, something has changed.
- The Shakespeare dir is missing a sub directory. When I saved a play it generated:
HTML
<link rel="stylesheet" type="text/css" media="screen" href="lear_files
+/shake.css">
Directory/file
C:\>dir lear_files
Volume in drive C is XP MP 3.01
Volume Serial Number is CE02-00E2
Directory of C:\lear_files
15/02/2013 09:39 <DIR> .
15/02/2013 09:39 <DIR> ..
15/02/2013 09:39 259 shake.css
If you don't have this css in the location (note that in your file it's looking for /shake.css) it won't render properly on screen. Get this file, save it to your Shakespeare directory.
Update 3: http://shakespeare.mit.edu/shake.css
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|