Copy link to clipboard
Copied
Using RH 9 and Windows 7, 64-bit. Recently upgraded from RH 7.
Hi Folks,
I'm trying to survive a zombie <span> apocalypse! Here's what a portion of one of my .htm topics in my project looks like inside of the Notepad++ text editor:
Notice that these span tags are empty. My understanding is that tags without any attributes in them don't do anything. Right?
Anyway, there are some 1000 emtpy <span> tags in 18 topics that don't have any attributes in them. I've checked the revision history for one of our files, and it appears that this started happening sometime after the upgrade to RH 9. The initial conversion to RH 9 didn't increase the # of <span> tags, but subsequent edits and saves to the file I checked seems to be causing it.
For example in this revision history view from Mercurial, it shows a single change from one revision to the next revision. Notice the increase in tags:
Does anyone know what's causing this? There was no visual indication this was happening inside the WYSIWYG editor in RH. It's only now when we submitted the files for localization, that our localization department ran into them when preparing this project for localization. Here's what they saw:
Any ideas why this is happening and on how to fix it? To fix it, I'm thinking of doing a Find and Replace across my project in Notepad++ and removing any empty <span> tag, and then opening the project back up inside of the RH editor. I'm hoping this would then remove the closing unmatched </span>?
Copy link to clipboard
Copied
See Item 10. http://www.grainge.org/pages/authoring/rh9/using_rh9.htm
Rather than use a find and replace tool for only 18 topics, consider using Remove Attributes. Slower but safer. Just right click in each paragraph.
See www.grainge.org for RoboHelp and Authoring tips
Copy link to clipboard
Copied
Note that Item 10 is shaded blue. That is explained at the top of my page. You may have done the damage before you applied the patch, you did apply it didn't you?
See www.grainge.org for RoboHelp and Authoring tips
Copy link to clipboard
Copied
I'm running version 9.0.0.228--When I do Updates from the Help menu it says my applications are up to date.
Copy link to clipboard
Copied
Looks like from your post here...
http://forums.adobe.com/thread/848021
...That the latest is 9.0.1. Too bad my update functionality didn't catch this update. I'll apply it and see if that helps.
Copy link to clipboard
Copied
Hi,
My Remove inline styling script will also delete any empty span tags, see http://www.wvanweelden.eu/robohelp/extendscript/remove_inline_styling
Note that this script does more than remove span tags as it will remove all your inline styling. But by removing the code you don't need, you can easily configure the script to only remove the span tags. Important: Make a backup before running the script!
Greet,
Willam
Copy link to clipboard
Copied
So I fixed these in my the project I mentioned at the start of this by opening each inside of RH and findng and replacing the span tags. I visually checked each file and that seemed to work.
But now I find this zombie plague has infected all my other help projects. I did a search and I have 430+ affected htm files in 11 projects. This is much too large a number to try to fix manually. I mean I will if I have to, but I don't WANT to.
The problem of course is two fold:
1) A bazillian span tags
2) The contitional build tags that are often surrounding text that shouldn't be marked.
I should be able to fix the span tag proliferation problem using a Notepad++ find and replace workaround I came up with, but I don't see an automated way of fixing the screwed up contitional build tags that are in those files. Any ideas? Or is it just going to be a manual grind through 430 htms?
Copy link to clipboard
Copied
Hi,
For the span tags, see http://www.wvanweelden.eu/robohelp/zombie_span_tag_apocalypse_cleaner for quickly removing the span tags from your project. It'll correctly remove the corresponding end tag of the spans, something that might give problems with a find and replace operation.
For the conditional build tags, I don't see an easy way to fix that.
Greet,
Willam
Copy link to clipboard
Copied
Hi Willam
Perhaps your experience has been different than mine, but I find that all I need to do is remove the beginning span tags. When I do that, it leaves behind gobs of orphaned closing span tags. RoboHelp sees them as orphans and deletes them for me.
Cheers... Rick
Helpful and Handy Links RoboHelp Wish Form/Bug Reporting Form Begin learning RoboHelp HTML 7, 8 or 9 within the day! |
Copy link to clipboard
Copied
Such a great tool. Who'd have thought that
Greet,
Willam
Copy link to clipboard
Copied
Willam van Weeldeen wrote:
For the span tags, see http://www.wvanweelden.eu/robohelp/zombie_span_tag_apocalypse_cleaner for quickly removing the span tags from your project. It'll correctly remove the corresponding end tag of the spans, something that might give problems with a find and replace operation.
Thanks Willam! I'll try using your script when I have to do fix the zombie tags on our release code branch next.
Captiv8r wrote:
...Perhaps your experience has been different than mine, but I find that all I need to do is remove the beginning span tags. When I do that, it leaves behind gobs of orphaned closing span tags. RoboHelp sees them as orphans and deletes them for me.
Yeah, that's the route I took for our development branch. Did a Find and Replace on the <span> in Notepad++ and then opened the project in RH. RH yanks out the closing spans. I'm still checking each .htm in RH after doing this though, since I've noticed that perhaps ~1% of files will still show an occassional <span> tag for some reason. But I have to visually look at each htm to ensure that the conditional build tag isn't screwing things up anyway.
Copy link to clipboard
Copied
So, I found that while the 9.0.1 patch mentioned earlier stops some of the conditional build tags from spreading, it does not stop it in all cases. For example, in an .htm file I have, I have a javascript followed by an image. If the image is clicked on, the javascript is executed, as indicated from this code taken from an affected topic:
<a href="javascript://" onclick="MyRoadMap(MenuStr, 'yes', event.screenX, event.screenY)"><script language="VBScript" type="text/vbscript">//<![CDATA[ On Error Resume Next MenuStr = MapCtrl.GetHelpMap(26170) ' ID_USE_LEGACY_DIMENSIONS //]]></script><?rh-cbt_start condition="Online" ?><img src="../images/i_chiclet.gif" alt="Display Menu Roadmap" title="Display Menu Roadmap" width="14" height="14" border="0" /><?rh-cbt_end ?></a> |
However, if I try to move the <?rh-cbt_start condition="Online" ?> tag in HTML view in front of the <a href...> tag, and then go back into Design view, the tag gets propagated throughout the entire rest of the document from that point on.
Or I try to apply the conditional marking to just the script (little red square) in Design view, click Save, and then click on HTML view and then back to Design view, the same thing happens. So the best I can do is just conditional mark the image.
Copy link to clipboard
Copied
I am using Robohelp 2017 on Windows 10 OS. I copied a short phrase from one topic to another topic, and the phrase had conditional text on it. I went off to do something else, and when I went back to that topic, the Zombie Span Tag Apocalypse had happened!
I saw this thread and cheered for Willam Van Weeldon, but the link is broken. 😞
I know how to fix it; my question is how can I make RoboHelp stop trying to fix my code?! There should be a check box or even a registry setting to turn that bug--or feature--off.
Thanks,
Karla
Copy link to clipboard
Copied
Sorry Karla - no such flag or setting AFAIK.
Copy link to clipboard
Copied
This hasn't been seen since RoboHelp 9 so report it.
Copy link to clipboard
Copied
Done! Bug Id: RH-626