Not signed in (Sign In)

Vanilla 1.1.9 is a product of Lussumo. More Information: Documentation, Community Support.

    •  
      CommentAuthormax
    • CommentTimeMay 20th 2010
     

    Hey guys. There have been so many calls for a web export in Ulysses. Doing HTML and blogs and stuff right from the app. But till now ... theres about zero feedback. What's up? Did we confuse you? Is there no interest? Did you miss to read about it? No time? etc. We'd really like to know!

    •  
      CommentAuthorbashosfrog
    • CommentTimeMay 24th 2010
     
    max - definitely interested, and after taking a quick look I have to say congratulations on your usual innovation and inventiveness. But I'm not currently using Ulysses because Spotlight and Quicklook don't work, and these features are central to my workflow. I prefer writing in Ulysses to anything else, but not when it doesn't integrate with my system. So, web export is terrific and it looks well implemented, but I'm still waiting on the basics. Looking forward to 2.1.

    - matt
    •  
      CommentAuthormax
    • CommentTimeMay 24th 2010
     

    Got it. We'll take care of the problem :)

    •  
      CommentAuthorbashosfrog
    • CommentTimeMay 25th 2010
     
    max -

    While you're taking care of the problem ... I earn most of my crust from journalism. I find Devonthink to be an indispensable tool, and have taken to writing all my articles from templates set up within Devonthink. That means that all my articles are saved directly to the Devonthink database, so that when I'm digging around in a topic the articles sit alongside any reference docs to complete the archive. I don't have articles in the Finder, references in Devonthink, and have to hop between the two systems to find something.

    I'm working with Ulysses, because it's such a great writing environment, but for the moment I have to export an RTF version of each article from Ulysses so Spotlight can read it. Not ideal.

    Devonthink relies on Spotlight to find documents within its database, and Quicklook to view those documents. How useful Ulysses docs are in Devonthink will greatly depend on how well you implement Quicklook. Ideally, the Ulysses Quicklook will enable the user to flick through every document in a Ulysses project, like the PDF Quicklook allows you to flick through each page. Then it will seamlessly integrate with Devonthink, and I can have the best of both worlds: the best writing tool working within the best information manager.

    Here's hoping.

    - matt
    •  
      CommentAuthorMaggot
    • CommentTimeMay 27th 2010
     
    I'm not a techy, so I'm only looking at it for fun, but it seems there's a couple of limitations so far.

    1) No way to edit the index landing page... so far, it just shows as blank in the modern template.
    2) No way to insert external link in the navigation bar - you might want to do this if there's a non-Ulysses contribution to the site, for example a forum.
    3) There's some kind of bug with the references page. I'd expect the reference page to appear in the navigation menu if and only if the current page uses references (perhaps there ought to be the option to always or never show it as well). But sometimes the RP appears in the menu when it shouldn't, and doesn't when it should - see the documentation for an example of both.

    But wait - I'm an idiot, because I've just reread your documentation, and perhaps you can do 1) & 2) by editing the template file index.html and pages.html? They're nothing techy like plists, so it seems it'd be pretty easy to do so. Could you produce simple instructions? (the "creating custom templates" is way over my head, and anyway is too powerful for simple things like 1) & 2)).

    Very imaginative solution - as always! I love the way things fit together. And... it's enjoyable to play with, which is a real plus with me.

    Best regards

    Robert
    •  
      CommentAuthorgoetz
    • CommentTimeMay 27th 2010
     
    Thank you for your feedback.

    Let me try to give you some instructions to fix (1) - (3).
    First off, you need to navigate to the template folder. Open Applications folder with Finder. Ctrl-click "Ulysses" and select "Show Package Contents." Go to Contents > Plugins, Ctrl-click "WebExport.ulysex" and select "Show Package Contents" again. In Contents > Resources > Templates > Modern, you can find the Template "Modern" (we're looking into ways to make locating the default Templates easier).

    To fix (1), open "index.html" inside the folder. You can add HTML content between "<div id="content">" and "</div>" (lines 27/28).

    To fix (2), you need to edit both "index.html" and "page.html". The latter HTML file is a Template for every exported Document. You can simply add content (such as external links) by adding them to the section "navigationBar" (lines 10-24). Since you probably want to add content after the table of content, add it just before the "</div>" tag in line 24.

    We know about the Reference link issue in the navigation bar and it will be fixed in the next release. In the meantime, you can delete line 19 ("{{IF (references.@count) > 0}}") and line 24 ("{{END}}") in "index.html" and lines 18 and 23 in "page.html". This way, the Reference link will always be displayed.

    As a side note: I think it is better to first create a copy of the Modern Template by copying it from the above-mentioned directory path to Library/Application Support/Ulysses/Exporter/Web (I'm referring to the Library folder in your home directory, not the system-wide Library folder in the root directory) and then editing this copy and not the original Template.

    I hope I don't sound too techy :) We're currently trying to make editing Templates easier, especially for users who don't have an Property List editor.
    •  
      CommentAuthorMaggot
    • CommentTimeMay 28th 2010
     
    Hey, Goetz. Thanks a lot. I've worked at your instructions a bit, and I understand them, or at least I think I understand them, which I guess is nearly the same thing. In fact I've just broken my leg, so I'll be spending rather more of the next six weeks killing time than I anticipated. I've got just the project for this little gem and this enforced idleness; something I've been putting off for a couple of years and doubted I'd ever have time for. Thanks, folks.

    I really think SM are underselling this exporter! It's much more flexible than it appears at first - and much more useable. It seems to me that with very little coding you can have a complete website, no need for any other package (except obviously for things like FTP client and property list editor). That's amazing! Obviously it's best for text-based sites - the kind of glossy touch-me stuff that packages like iWeb produce are probably best done with packages like iWeb - but, hey, everyone who comes to Ulysses loves words more than their social life anyway (or is it just me?).

    All the best and thanks again.

    Robert
    •  
      CommentAuthorMaggot
    • CommentTimeJun 1st 2010
     
    Hello, troops. I'm beginning to really like this exporter. It completely changes the way I look at U... suddenly it's a CMS system, of a kind! I really hope this takes-off for you.

    I know the exporter is still only a beta, but there's a couple of things I've noticed that you might not have already on your list.

    First, if you duplicate a template as Goetz suggested, it zeroes the elements (markers, images, etc). They're easy to flick back on, but if you copy your duplicated template to the home library folder they still don't work. Leaving the new template in the package works, though it might not be *approved* to edit things directly inside the Ulysses package... (I wouldn't even consider it on a PC, but somehow Mac users don't take to the words "you're not supposed to do that").

    You have to change the name of the new template inside info.plist, even if you've already changed the file name, otherwise it shows as two "moderns". I don't have property list editor, but textedit works.

    At one point I saw a "operation could not be completed: property list error" during export. Everything still worked, and I haven't seen that error since. Sorry I didn't take any details.

    There's a longstanding very minor bug with the main part of Ulysses by which documents are sometimes marked as changed even if they're not. Normally it's not enough of an irritation to worry about but with the new exporter I'm exporting much more than usual, and the thing I do before exporting is check all my documents are saved. Pass it on, please.

    I don't like the "Image 1:" stuff so I blanked the format string in the XMTL plist. That removed it from the text, but not from the description of the image. How do I do that? Conversely, I would like my footnotes to be numbered in order automatically; I'm going to see if the same or similar code will work there.

    Metatags - show at the top of the page. Whoops! (But I'm sure you're already on that case).

    It seems to me the index page ought to be inside Ulysses, at least optionally. I know you can edit it as in Goetz's last post, but hardly anyone has a landing page with "click here to enter" on any more...

    I presume HTML that isn't run-of-the-mill can be put in the template file?... I'm thinking of things like iFrames. That'd be cool.

    That's all for now. Thanks and great idea.

    Robert
    •  
      CommentAuthorgoetz
    • CommentTimeJun 2nd 2010
     
    Again, thanks for the feedback :) I'm glad you like our new exporter!

    We know that duplicating Templates in the Finder and editing them using the Property List Editor is far from optimal and we're working on a solution in which you don't need to take care of Template and Property Lists anymore.

    About the "Image 1": if you want to remove that from the description as well, you need to change the "floating" property of the Style. In the case of the "Image" Style in the "Modern" Template, you need to remove "{{LOC image}} {{@index}}: ", so that only "{{description}}" is left inside the <p> tags.

    I can't really reproduce the issue with the metatags. If I insert a metatag, say,
    <meta name="author" content="Goetz Fabian">
    it is inserted in the <head> section of the HTML files. Or did I miss something here?

    The index page will be changed in the next release, and it definitely won't be empty anymore :)

    You're free to put any code into the template file. Basically, the Exporter will go through the file and replace all the language statements (FOR, IF, ...) and placeholders (document.text, document.name, ...). The rest is simply ignored. Therefore, you can change Templates to include iFrames, JavaScript and anything else you feel like putting in there.

    Götz
    •  
      CommentAuthorMaggot
    • CommentTimeJun 2nd 2010
     
    "I can't really reproduce the issue with the metatags. If I insert a metatag, say,
    <meta name="author" content="Goetz Fabian">
    it is inserted in the <head> section of the HTML files. Or did I miss something here?"

    Yep, you did miss something, mate - you missed that I'm an idiot. I was putting in metatags without the <meta name= content=> stuff. Works now. Sorry.

    Moving on. Unless it's me again, the navigation bar seems to cut half into the text of the pagenames on IE7 / Windows (which I believe is still used in primitive parts of the world). I'll dig into the browser settings if you want.

    "You're free to put any code into the template file. Basically, the Exporter will go through the file and replace all the language statements (FOR, IF, ...) and placeholders (document.text, document.name, ...). The rest is simply ignored. Therefore, you can change Templates to include iFrames, JavaScript and anything else you feel like putting in there."

    This is really really really brilliant. That makes it infinitely flexible. OK, I'm going to make the effort and try and understand the nitty gritty. I really think Soulmen are underselling themselves with this one... and free!

    Goetz, can I ask how the index page will be changed, if that's been decided? It affects the design I'm working on...

    Thanks again - stirling stuff.

    R
    •  
      CommentAuthorgoetz
    • CommentTimeJun 3rd 2010
     
    To be honest, I haven't tried the exported files with any other browser than Firefox and Safari. We'll take a look at that.

    We haven't decided about the index page yet, but if we do, I'll update you.
    •  
      CommentAuthorMaggot
    • CommentTimeJun 12th 2010
     
    1) The "property list error 0" message is back, and this time it stops the export and sometimes crashes U (I noticed Mail also crashed while I was trying this; that must be a coincidence, but a very odd one - haven't seen Mail crash for years). At one point the same message was coming up every few seconds even when I wasn't doing anything. Very strange. Restart and even reboot didn't help, but eventually I copied all the text and notes to a new document and that did the trick. Let me know what to look out for and I'll take more detailed notes if it happens again.

    2) Request - some way of coding <br>!

    3) Definitely half the left (navigation) frame is lost in IE 6 & 7.
    •  
      CommentAuthorgoetz
    • CommentTimeJun 16th 2010 edited
     

    This "property list error 0" message is pretty strange, since I haven't encountered it yet while working with the Web Export. We would appreciate it if you could send the crash log to support@the-soulmen.com, it might help us in finding the root of the problem.

    If you want your paragraphs to be separated by <br /> instead of enclosed in <p> and </p>, you can simply change the format of the default Style (the Paragraph Style Action with the description "Paragraph" and the type "default") from "<p>{{}}</p>" to "{{}}<br />". This way, a "<br />" is inserted after every paragraph. Currently, you cannot simply enter "<br />" in the Editor, since some characters such as <, > or & are automatically converted to their respective HTML entities (< >, &).

    •  
      CommentAuthoraef110
    • CommentTimeJun 17th 2010 edited
     
    Ulysses is exactly what I've been looking for and I love the HTML exporter. Thanks so much to the Soulmen team for their ingenuity.

    I just have a few minor suggestions for the HTML exporter:

    - Option to remove blank lines (easier to write with blank lines but they're often unnecessary in the final HTML)
    - Save snippets as .html rather than .txt (or option to do so)
    - Automatically interpret tags (such as the "dash space" used in this list) as unordered lists, and numbered lists ("1.", "2.", "3.") as such, or:
    - Add more tags for elements such as lists and quotes
    - Option to replace "smart quotes" and apostrophes with straight quotes: Single quotes are currently exported as ,Äô and double quotes as ,Äú and ‚Äù when viewed in TextEdit. Straight quotes would be preferable since they display properly in all text editors and browsers!

    Thanks so much for such an extraordinarily useful program!


    Kind regards,

    Albert
    •  
      CommentAuthorgoetz
    • CommentTimeJun 17th 2010
     
    • Option to remove blank lines (easier to write with blank lines but they're often unnecessary in the final HTML)

    Aren't the empty lines outside the <p></p> tags? For me, these empty lines helped reading the source code. We'll think about such an option, but right now it doesn't really seem too useful to me.

    • Save snippets as .html rather than .txt (or option to do so)

    You can actually change this setting by yourself by editing the Info.plist file of the Snippet Template. There's a whole section on how to edit to Templates called "Creating Custom Templates" in the documentation of the Web Export. Once you opened the Info.plist file, navigate to multiFiles > Item 0 and set the property "name" to {{document.index}} - {{ENC document.name}}.html (the only thing which is changed is the extension). We're currently working on a Template Editor, which will greatly simplify changing settings like these.

    • Automatically interpret tags (such as the "dash space" used in this list) as unordered lists, and numbered lists ("1.", "2.", "3.") as such.

    The easiest thing would be to add a Paragraph Style with "- " or "1. " as tag and apply the Style Action "List (Unordered)" to that Paragraph Style. That's actually what I do when working with lists.

    • Add more tags for elements such as lists and quotes.

    What other tags would like to have included in the default Templates? The selection of tags in the Templates is only a subset of all HTML tags but we felt those were the most important ones for exporting Ulysses Projects. If you want, you can also add your own Actions to the Templates (using the instructions provided in the Web Export Documentation).

    I hope that helps.

    Götz

    •  
      CommentAuthoraef110
    • CommentTimeJun 17th 2010
     
    Hallo Götz,

    Vielen herzlichen Dank für diese Infos. ;-)

    In playing with the web export documentation file I discovered that the most important features I was looking for already exist. I'll use double dashes for unordered lists and edit the template files if I need any additional tags.

    Blank lines are irrelevant; it's purely my personal habit to remove them from HTML. You're right about readability and I think I'll switch and start using them as well.

    I discovered that the tags that appear in the exporter depend on the input documents: Only those tags appear that are in the document(s). I was using a very simple document for input and had mistakenly assumed that Ulysses didn't support more tags.

    Thanks so much for your wonderful program. It's exactly what I had been looking for!


    Freundliche Grüße

    Albert
    •  
      CommentAuthorMaggot
    • CommentTimeJun 17th 2010
     
    Property List Error isn't coming up at the moment - isn't that always the way? (a watched saucepan never boils, we say). I **suppose** it may have been a result of me tinkering inside the U package (see point 1 in my next post)... but I was pretty sure it wasn't. If it turns out it was, I'm very sorry to have wasted your time. If it returns, I'll take a screenshot and (if it crashes U) a crash log.
    •  
      CommentAuthorMaggot
    • CommentTimeJun 17th 2010
     
    ***Adventures and discoveries.***

    I thought some of you might be interested in what I've done and found over the last couple of weeks or so.

    Software used: Ulysses, Cyberduck, TextEdit, Property List Editor, TextWrangler. All except U are free or donationware.

    1) To start with, I copied the "Modern" template, as described at the end of Goetz's post 27/5. At first I worked on a copy direct inside the U package - I had problems with copying to Library > App Support; but the Library locaion is undoubtedly safer, and it worked eventually (never found out what I was doing wrong). Inside the exporter, open info.plist in your property list editor and change the name field to something new. Restart U and the exporter should appear in the list on the export page. You'll probably have to reset all your styles. As explained by Götz (finally found the umlaut key!) on the 2/6, now is a good time to set your metatags. The ones I used were:
    <meta name="keywords" content="many words that I hoped would attract the eagle eye of Googlers">
    <meta name="description" content="brief description of website which AFAIK appears below the link in Google's search.">

    2) I didn't like the separate landing page that can't (yet) be edited within U. I tried various solutions, and the one that worked best was simplest - just delete the index.html template inside the exporter. You also have to delete the line "1 index.html" in Singlefiles in info.plist (because U seems to check all the template files are there when it starts). This also means that any changes I make to the templates only have to be in one file (pages.html). Sorry, Götz, to undo all your work - it just didn't work for me...

    After this, my workflow is simply:
    a) export from U into a folder on the desktop;
    b) FTP to my remote space. CyberDuck doesn't do smart uploads, so if you have a lot of files you may prefer to keep records of what's changed and do it the hard way.

    Now, you still want an index file as a home page, so I did two things. First, for my local export folder, I made an alias of my real home page and named it index.html. Because the index template is deleted, exporting from U doesn't overwrite my alias, so I don't need to repeat that step each time. Second, for my remote server, I set up a 301 redirect to do the same thing. My host's software (cPanel) has a simple way of doing it that seems to be Google-friendly, and probably yours does too.

    3) I wanted different words to "table of contents" - I thought a brief description or motto of my site would be nice. Open localisable.strings (inside your language folder - for example "en") in Textedit, change "table of contents" to "Frightening the horses since 2010" or whatever your chosen blurb is, save and close. You then have to restart U for the change to take effect.

    Note I didn't change the tag "tableofcontents" - seemed to be asking for trouble - but if you do, remember to change it in pages.html as well. I say leave it alone; illogical, but I think the less you change, the better.

    Couldn't work out how to put a carriage return inside those strings, though - Götz?

    4) I wanted the window bar in my browser to show the website name as well as the page name. I could have changed the names of all my documents, but that was obviously undesirable. Because the lovely Goetz has made the {{}} symbols being evaluated first, I found I could just change the relevant line in pages.html from
    <title>{{document.name}}</title>
    to
    <title>{{TITLE}} - {{document.name}}</title>
    (Evaluates as
    Site name - document name
    where the "-" is literal). That is so elegant!! You clever man!

    5) I wanted a copy of pages separate from the main list of pages. I knew their names and had fixed them so that they were top and second top in the export. First add a couple of new lines to the localisable file:
    "Home" = "Home";
    "About" = "About";
    Restart U. In pages.html, add the following inside the ul toc list, but before the FOR loop:
    <li><a href="1 - {{LOC Home}}.html">{{LOC Home}}</a></li>
    <li><a href="2 - {{LOC About}}.html">{{LOC About}}</a></li>
    <hr />
    But the pages need to be taken out of the FOR loop as well; I thought using the index count was easiest. Add
    {{IF document.index != '2' AND document.index != '1'}} ... {{END}} around the li element.
    You need the quotes around the 2 and the 1 - otherwise they evaluate as an integer, I think. But as it is there might be a problem if you have more than 9 pages... it might decide (say) 11 is between 1 and 2. Ah well - I'll cross that bridge when I come to it.

    More in due course.

    Robert
    •  
      CommentAuthoraef110
    • CommentTimeJun 17th 2010
     
    I'm wondering why the double dash tag works for the Web Export Documentation file but doesn't for my own projects. I'd like to use it for unordered lists, but it doesn't show up at all in the export dialog.

    Also, quotes don't display properly in Safari. Is there a way to replace all smart quotes (Ulysses's default when editing) with simple straight quotes?


    Many thanks,

    Albert
    •  
      CommentAuthorMaggot
    • CommentTimeJun 18th 2010
     
    Is it possible to access individual notes programtically, say from within pages.html? Failing that, is it possible to put rich text into the excerpt, or use the <<...>> tags there to get at the notes?

    Thanks

    R
    •  
      CommentAuthoraef110
    • CommentTimeJun 18th 2010
     
    I think I just discovered a significant bug in the Web Export module: It appears that new projects created after installing the beta have all new paragraph and inline styles, whereas projects created before installing the module do not.

    Please let me know if there's any more information on this error, or any updates.


    Thanks,

    Albert
    •  
      CommentAuthorMaggot
    • CommentTimeJun 18th 2010
     
    Poor Soulmen. Max started by saying why is nobody commenting on the new exporter... and now he's drowning in comments.
    •  
      CommentAuthorgoetz
    • CommentTimeJun 18th 2010
     

    Maggot: Adventures and discoveries.

    Wow, I was really impressed by how much you played around with the Web Export and made use of its capabilities!

    Here are a few remarks to your adventures:

    "Note I didn't change the tag "tableofcontents" - seemed to be asking for trouble - but if you do, remember to change it in pages.html as well. I say leave it alone; illogical, but I think the less you change, the better."

    The Localizable.strings files inside the en.lproj folder always have the same format: first the identifier in quotes, then an = and then the localized string in quotes. The identifier is the same for all localizations, the localized string is not. For instance, the string with the identifier "tableOfContents" has the localized string "Table of Contents" in the English localization (which can be found in en.lproj), while the German localization (located in de.lproj) has "Inhaltsverzeichnis"" as localized string. One of the commands for the placeholders in the Web Export is LOC. Whenever you use it, you put LOC first and then the identifier, e.g. {{LOC tableOfContents}}. During export, this placeholder will be replaced with "Table of Contents" if you run Ulysses (and Mac OS X) in English. If you run Mac OS X in German, the placeholder will be replaced with "Inhaltsverzeichnis". Therefore, you shouldn't change the tag, but the localized string. If you change the tag, you will need to change the tag inside the LOC placeholder as well. The Web Export has a built-in validator that checks for those things.

    "Couldn't work out how to put a carriage return inside those strings, though - Götz?"

    You should be able to insert a carriage return by putting \n at the position where you want the line break.

    "5) I wanted a copy of pages separate from the main list of pages. I knew their names and had fixed them so that they were top and second top in the export. First add a couple of new lines to the localisable file: "Home" = "Home"; "About" = "About"; Restart U. In pages.html, add the following inside the ul toc list, but before the FOR loop: <li><a href="1 - {{LOC Home}}.html">{{LOC Home}}</a></li> <li><a href="2 - {{LOC About}}.html">{{LOC About}}</a></li> <hr /> But the pages need to be taken out of the FOR loop as well; I thought using the index count was easiest. Add {{IF document.index != '2' AND document.index != '1'}} ... {{END}} around the li element. You need the quotes around the 2 and the 1 - otherwise they evaluate as an integer, I think. But as it is there might be a problem if you have more than 9 pages... it might decide (say) 11 is between 1 and 2. Ah well - I'll cross that bridge when I come to it."

    First off, you don't necessarily need to use the LOC placeholder. It's useful if you want to write a multi-language Template. Otherwise, you can simply put the following code before the FOR loop:

    <li><a href="1 - Home.html">Home</a></li>

    <li><a href="2 - About.html">About</a></li>

    The IF condition is a bit tougher. The problem is, once you have more than 10 documents, the document index will be '01' and '02' since they are numbers < 10 are padded with zeroes. document.index is a string, that's why you need to add single quotes around them. Maybe we'll find a better for your problem. (oh and '11' and '12' should work just fine.)

    Again, it's great to see people playing around with the Web Export :)

    Götz

    •  
      CommentAuthorgoetz
    • CommentTimeJun 18th 2010
     
    aef110:
    "I'm wondering why the double dash tag works for the Web Export Documentation file but doesn't for my own projects. I'd like to use it for unordered lists, but it doesn't show up at all in the export dialog."

    The double dash is not a default Paragraph Style (I added this Paragraph Style for the Web Export Documentation since there was no appropriate default Style). You need to add this Style to the Project yourself. Open the Preferences (Ulysses > Preferences), select "Paragraph Styles" on the left, press the "+" button on the button and set the tag to "-- " and the description to "List Item" (or any other string).

    "Also, quotes don't display properly in Safari. Is there a way to replace all smart quotes (Ulysses's default when editing) with simple straight quotes?"

    There's also a Preferences setting for that :) This time, it's in the the section "Standard Mode". Additionally, make sure that you don't replace the standard quotes with localized quotes in the Web Export (first option in the section "Characters").

    Götz
    •  
      CommentAuthorgoetz
    • CommentTimeJun 19th 2010
     
    Maggot:
    "Is it possible to access individual notes programtically, say from within pages.html? Failing that, is it possible to put rich text into the excerpt, or use the <<...>> tags there to get at the notes?"

    Yep, you should be able to access them using the property "documents.notes". Since a Document can have more than one Note, you can iterate over them using the FOR loop:
    <ul>
    {{FOR note in document.notes}}
    <li>{{note}}</li>
    {{END}}
    </ul>
    Please keep in mind that this will add all Notes (even the ones with References) to the exported file. We're working on a new solution for Notes for the next version :)

    You can also access the excerpt with {{document.excerpt}}. Currently, you cannot access the rich text.

    To be honest, I haven't used notes in the Web Export, but it should work :)
    •  
      CommentAuthorgoetz
    • CommentTimeJun 19th 2010
     
    aef110:
    "I think I just discovered a significant bug in the Web Export module: It appears that new projects created after installing the beta have all new paragraph and inline styles, whereas projects created before installing the module do not."

    This is really weird. Can you please clarify what you mean by "new paragraph and inline styles"? Do the new projects have less paragraph and inline styles? are there none?
    Whenever I create a new Project (with the Web Export installed), all Styles and Markers are present.
    Obviously, the Web Export shouldn't change any Styles, and in my opinion, it doesn't do that.
    •  
      CommentAuthorMaggot
    • CommentTimeJun 19th 2010 edited
     
    "Wow, I was really impressed by how much you played around with the Web Export and made use of its capabilities!"

    No sweat, mate - the pleasure is mine. It's what I said earlier; this exporter is great fun. It's also amazingly flexible - sure, it's a bit of a steep learning curve, but so is any flexible package. So far it's mainly Albert and me posting here, but I do hope others take it up.

    Thanks for the tips. I'll work through them. I'd realised about being able to miss out LOC, but I put it in my post for the sake of others to whom localisation is important. You're right - I'm not using LOC myself.

    The \n for newline - d'oh. <Slaps forehead>

    Thanks for the document.notes tip. I really meant accessing an individual note, so that I can get at a particular image from the template (but a different image for each document). I bet there's a variable like count or index that keeps track of where in the FOR loop you are. I'll check out the Apple documentation. BTW, it seems to me to be a bit odd that Ulysses doesn't allow rich text in the excerpt; after all, an excerpt is simply a note above its station.

    Thanks again

    R
    •  
      CommentAuthoraef110
    • CommentTimeJun 19th 2010
     
    >> This is really weird. Can you please clarify what you mean by "new paragraph and inline styles"? Do the new projects have less paragraph and inline styles? are there none?

    You answered my question in the previous post. I was trying to figure out why the Web Export Documentation file has additional tags for HTML while the default templates don't. It seemed that if I loaded the documentation file, then closed it and started a new project, the tags were still in memory.

    Now I know to add the tags in the preferences. Maybe an HTML template could be added that already contains the tags?


    Best,

    Albert
    •  
      CommentAuthorMaggot
    • CommentTimeJun 20th 2010
     
    More adventures.

    6) An bug/ feature/ item of interest! If you comment out stuff that doesn't work in the template files, it may still fail U's validation, presumably because the validation doesn't have any understanding of the structure of the document but knows it's going have to swap {{invalid expression}}, and can't find anything to swap it with. Boy - it took me over an hour to get that one!

    7) I wanted to change the title at the top of the page. The really neat way is changing
    <h1 class="DocumentHeader">{{document.name}}</h1>
    in the {{IF HEADER}} bit to
    <h1 class="DocumentHeader">{{document.excerpt}}</h1>
    Then you can put any text you like in the excerpt and it comes up at the top of your page. Unfortunately, the excerpt is plain text, and doesn't take the <<...>> notation, so it's not possible to put an image there.

    As a workaround, Götz has proposed accessing the notes programatically, and putting my image there; but I couldn't get that to work. "document.notes" seems to be valid - it will display something like
    (,,,)
    where the number of commas equals the number of notes, but it seems that document.notes can't be taken over a FOR loop. So for now we'll just have to put the image in from the U document in the normal way.

    8) I don't like the "image 1" stuff. Goetz gives directions to remove it on 2/6 above. Briefly, point your property list editor at XHTML.plist, select the appropriate inline dictionary (number 6 for me), change the format from "{{LOC image}} {{@index}}" to an empty string, and take out {{LOC image}}{{@index}} from the floating string. Restart Ulysses for the changes to take effect.

    9) Neither IE nor Firefox like TIFFs. Not sure if that's something wrong with the exporter, or something wrong with those browsers. Either way, it's easily fixed; use JPEGs or whatever. Preview converts.

    10) The problem I told you about with IE shifting the navigation list left of the window (so that only the last few letters of the items on the list are visible). After an hour or so on the web, I've come to the conclusion that this is a "hasLayout" problem with IE. The site
    http://www.satzansatz.de/cssd/onhavinglayout.html
    offers various solutions, none of which I could get to work (or even understand). However, I found that changing the toclist's left margin in the .css file from -2em to +2em made IE look OK while still being acceptable in proper browsers. I've wasted enough time on this, and so that'll have to do for now.

    Also, I see IE shows the frames in double scroll bars. It's at moments like this that I remember why I pay Apple's over-inflated prices - because, really, they're worth it.

    10) Putting <br> or blank lines in - it's really good to have the occasional whitespace, but HTML deletes it all. Götz's workaround back on p2 above was to change the default paragraph style, but I didn't want to **always** have blanklines, only when I wanted them. So I tried the following variation on his idea:

    First, in XHTML.plist > paragraph, add a new dictionary - comes up as number 9 for me. Give it two string children, one called "description" set to "NewLine" and the other called "format" set to "{{}}<br />" (not including quotes, of course). Save and restart U. Next, introduce a new paragraph style called Newline (I used \\ as the key combination). Make it look a bit subdued - say in grey. In the exporter, tie it to action "NewLine". Finally, in your text when you want to have space, put a "\\" as for any other paragraph style at the beginning of the line for every line of whitespace you want. That **should** work... next step is to give it a parameter for the number of lines.

    11) \n in localised.strings doesn't work... just replaced by one white space, presumably because HTML is getting its hands on it as well. It's not really important, I guess.

    12) I've been trying to get the navigation bar to list the h1 headings in the current page. I used storeAs in the .plist file, and I thought all would be well, but the validation failed, saying it didn't recognise "headings". I used:
    storeAs headings in the plist
    {{FOR heading IN headings}} in the template.
    Any idea?

    Ta for now.
    •  
      CommentAuthoraef110
    • CommentTimeJun 23rd 2010
     
    I have a couple small requests for the HTML exporter:

    1. Option to replace smart quotes with straight quotes. It's great to use smart quotes when writing, and there's an option to replace straight quotes with smart quotes. However, HTML often needs the reverse and it would be great to have this capability.

    2. Replace all nonstandard characters (i.e., those not in ASCII 0-127) with official HTML entity codes. Thus, è would be replaced by &egrave; and ü by &uuml;, etc. This would eliminate much post-export editing and allow all characters to work in all browsers.


    Many thanks,

    Albert