News for hackers. Stuff that matters.
Re:Why are restaurant web sites so bad? by ronnier on Monday December 27, 2010 @10:17PM (#2044485)
I also deal with this while keeping my resume updated and tweaked. I have an HTML, PDF, and MS Word format. I use a print CSS sytle sheet on my homepage (http://ronnie.me) so that I can print it to PDF for the PDF version and manually create the Word version. Very tedious.
Re:Why are restaurant web sites so bad? by jat850 on Monday December 27, 2010 @10:45PM (#2044547)
That's really neat. Is the CSS file readily available (for others to use), or something you'd prefer not to give out?

(I realize I could probably crawl through the source on your page and just take it, but that seems rude without asking.)

Re:Why are restaurant web sites so bad? by ronnier on Monday December 27, 2010 @10:50PM (#2044558)
It's as simple as creating a style sheet, targeting items you don't want to print, or create a class such as .noprint, and hide the items with { display: none; }

You'd want to put that CSS in a separate file and include it like this:

<link rel="stylesheet" type="text/css" media="print" href="print.css" />

The important bit is the media="print". Look at mine all you like, nice of you to consider asking :)

Re:Why are restaurant web sites so bad? by antrix on Monday December 27, 2010 @11:21PM (#2044618)
I do something similar for my resume (http://antrix.net/resume/). Started with a template by timbray [1] which I 'imported' into Google Docs by directly editing the document CSS & HTML. Finally, export from Google Docs as doc, pdf, etc.

The HTML version on my site has additional print specific CSS to switch fonts, background colour, etc. making the print output more pleasing.

[1]: http://www.tbray.org/ongoing/When/200x/2005/11/12/Template.h...

Re:Why are restaurant web sites so bad? by BrandonM on Monday December 27, 2010 @11:55PM (#2044678)
Ugh. Just learn LaTeX and write once.
Re:Why are restaurant web sites so bad? by cookiecaper on Tuesday December 28, 2010 @12:28AM (#2044744)
LaTeX isn't the only way you can "write once"; while there are LaTeX exporters for the formats mentioned, you can do the same with LibreOffice, which exports to Word, PDF, and HTML much easier than LaTeX docs do (LaTeX conversion usually requires three different tools, it's a simple Save As... or Export in LibreOffice).
Re:Why are restaurant web sites so bad? by BrandonM on Tuesday December 28, 2010 @12:10PM (#2045977)
> LaTeX conversion usually requires three different tools

That's what shell scripts are for. It is trivial to write a script that will accept a LaTeX filename and run the necessary commands on it. It is only a little bit more work to add in hooks (e.g., to your IDE) such that the script is run automatically upon saving the file.

Moreover, with .tex files being plain-text, you could even write simple scripts to assist with updating the documents themselves. Something like "add-new-reference" or "update-hobbies" could accept input from the user and add it to the .tex file quite trivially.

This is in contrast to a GUI program, where you are basically forced to fire up a heavyweight editor, perform the changes by hand, and then perform each export one-by-one, also by hand. I know you could script old versions of OpenOffice using Java or Python, but that ends up being way more convoluted than doing the equivalent with a .tex file.

Re:Why are restaurant web sites so bad? by wfarr on Tuesday December 28, 2010 @10:42AM (#2045698)
True, but LaTeX's output is worth the effort of input.