Friends,
Does In Design CS 5.5 have the power to convert text that uses italics to text that uses <i> and </i> ??
Your question is so vague that no one knows how to answer it. Let me help you a bit here: tell us about your target format. Are you exporting something from InDesign? How are you doing it? (File -> Export -> ?) What settings are you using? Please be specific. Have you already tried it? If so, what did you get, and how was it not what you expected?
I'm presuming that you mean you want to export the text from ID and have it tagged in the HTML. That's outside my workflow, but my understanding is that if you've applied a style to make that formatting happen, you should get a style for it inthe CSS style sheet that is generated when you do the export and the text itself will be tagged with that style automatically. That's a little different from waht you asked, but what you are looking for, I think.
As it happens it's dead easy. ![]()
Go to the find and change dialogue
Click on the Grep Tab
Click on the magnifying glass next to the find format
Click on Basic....
Click on Italic (take care to get the right Italic 99.9% of the time it's Italic)
Click OK
On the Change part Type <i>$0</i>
Click change all
I'll leave it to you to figure out how to do the bold one ![]()
Do yourself's a favor blokes and read Peter's book on Greps! http://shop.oreilly.com/product/9780596156015.do
@ Trevor,
Yes, it's dead easy to add the tags in the text in ID, and I nearly posted that, but that isn't really what ceencha is asking, to my understanding. The way I've read what he says is that the text is formatted and he want to export his page to html and have the html also format that text. As I said above, if a style is applied I believe that format tagging should be automatic on export.
I wouldn’t use automatic. If you do you wind up with classes and a mess of CSS.
I would have a character style for bold and one for italic. Those styles should be mapped to strong and em tags.
Every browser in existence will display them as bold and italic and of course that can be further styled by creating CSS rules for them.
Bob
My own findings on this subject are that it's not as straight forward as you might think to do this. Even when you map the tags to styles, it adds classes and not the tag you would require. However, there seems to be a way around it.
As has been mentioned here, if you create paragraph and character styles for your text - character for italic and bold, paragraph for headings - and then create tags (window > utilities > tags) the same as the HTML ones - h1, p, em, strong etc - you can then map the styles to those tags. However, when you export as HTML these are still converted to CSS classes and if you don't export the CSS, they all become <p> tags with <span>. Instead, export it as XML and change the file extension to HTML as you do this. It will correctly export the HTML tags but without the CSS styling. It depends on your workflow as to whether this is useful because you may be looking for both the CSS and the tags. In which case, I would probably do 2 exports. It may also be easier to export as HTML and then find and replace the generated classes with the tags. Eg. Find <span class="italic">, replace with <em>.
I came across this old article for CS2 that kind of covers this but it might have changed since: http://indesignsecrets.com/how-to-export-basic-html-out-of-cs2.php
Also, <i> and <b> are not deprecated - there are just better alternatives in most cases like <em> and <strong>.
http://www.w3schools.com/tags/tag_b.asp
http://www.w3schools.com/tags/tag_i.asp
You are of course correct Bob. However, my answer was written to aid the OP in his quest to get the HTML tags to appear. With no CSS, it generates the same HTML as with CSS - there are just no classes attached which is not what he was looking for. As I said:
However, when you export as HTML these are still converted to CSS classes and if you don't export the CSS, they all become <p> tags with <span>
Below is an HTML export with NO CSS and WITH CSS. I am using InDesign CS5.5. Unless I am missing something?
The first one is fine, but you need to create a character style for the bold and italic. Those then need to be mapped to strong and em.
Right now that text is separate paragraphs which is fine if the entire paragraph is going to be italic. But if that's the case, you'd then map it to p and assign a class to it of italic and set the rule in CSS for font-style, but for just a couple of words, applying the character style mapped to em would give you the correct em tag with no class.
Bob
These were all made with the same file and as per screenshot 1, I have mapped the character styles correctly. As I said, the HTML tags only show when exported as XML and I change the file extension. Otherwise, the last 2 screens show what happens when exported as HTML - same mapping as the first one.
But, in interest of covering all bases, below is it all on one line. If you can get something different, can you post your results?
If it will help, here's a link to that small INDD file. https://dl.dropbox.com/u/2548785/InDesign%20to%20HTML%20demo.indd
Bob
OK. I now see where I have either gone wrong, or got confused.
I set the file up, with paragraph styles and character styles and then opened the tags window and created appropriate tags. I then used Map Tags to Styles (or Map Styles to Tags) to create the link between them. As you can see from my structure, this worked fine. On export this did not create the HTML tags required. However, when I went into the Paragraph/Character style palette and edited the export tags, they were unmapped. I mapped them and got the same result as Bob.
As that is the case, what is the point of the 'Map Tags to Styles' option if the tags are not exported?
No. Mapping styles to tags was one of the major improvements in CS5.5 that received very little notice from the print crowd.
You might want to consider upgrading to Creative Cloud. With intro pricing the first year is only $29.99/month.
You can find details here:http://www.adobe.com/products/creativecloud.html
Bob
North America
Europe, Middle East and Africa
Asia Pacific