JafSoft Support Forums  
  Products:
AscToHTM (text to HTML) / AscToPDF (text to PDF) / AscToRTF (text to RTF) / Detagger (HTML to text and markup removal) 

 
  Forum options:
Forum Index  Register  Login  Search  FAQ  Log Out
Member options:
My Profile  Inbox  Member List  Address Book  My Subscription  My Forums 
 
 

Note: Some forums require a login other than "Guest" in order to post messages and replies


<label> tag

 
Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums > [Public forums (moderated)] > Ask JafSoft > <label> tag Page: [1]
Login
Message << Older Topic   Newer Topic >
<label> tag - 4/17/2008 10:12:45 PM   
Guest
I am testing this convertor and can't get it to remove the <LABEL> tags without getting rid of the value inside them.

For example:  <label id="OrderPrintUI_CommonFieldUI_SOL_Status">NEW</label>  is totally wiped.   "NEW"  does not appear in the results.

< Message edited by Admin -- 4/17/2008 11:22:20 PM >
  Post #: 1
RE: <label> tag - 4/18/2008 12:03:35 AM   
Jaf

 

Posts: 70
Joined: 2/1/2006
Status: offline
There's not a progam option to do this specifically.  Usually <label> tags are inside a <form> ... <.form> construct and these are largely eliminated as a whole.

However there is a trick that can be used using the product's "Text commands" feature.  This feature allows simple text edits to be performed against the source text before it is passed to the converter.  These commands are placed in a separate text file known as the "Text commands file".

Create a file called "label_commands.inc" and open it using a normal text editor.  In this file place on separate lines the two commands

   replace_text string "<label" by_string "<bad_label"
   replace_text string "</label" by_string "</bad_label"


these command will replace the matched parts of the <label> tag and change them into <bad_label> tags.  Thus

<label id="OrderPrintUI_CommonFieldUI_SOL_Status">NEW</label>


is now seen by the converter as

 <bad_label id="OrderPrintUI_CommonFieldUI_SOL_Status">NEW</bad_label>
 


Since "bad_label" isn't a legitimate HTML tag, it should simply be stripped when the HTML is converted to text.

However, I suspect that your <label> tag may be inside a <form>..</form> construct that is being removed en masse.  If that's the case, edit your commands file to look like this

     replace_text string "<label" by_string "<bad_label"
      replace_text string "</label" by_string "</bad_label"
      replace_text string "<form" by_string "<bad_form"
      replace_text string "</form" by_string "</bad_form"
  


which will use the same trick to prevent the converter recognising the whole form.

Once you have created your text commands file, use the menu option Conversion options -> Configuration Files -> Text commands to tell the converter where your text commands file is.

Hope this helps.


(in reply to Guest)
Post #: 2
Page:   [1]
All Forums > [Public forums (moderated)] > Ask JafSoft > <label> tag Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts