Function to remove ALL HTML codes

I have a field to extract from primavera which is in BLOB format in the database and pump it into a view.
we have injected codes to remove the HTML tags such as </> and a few other ASCII stuff ( got the help of a developer on that ACII stuff hence I don't know how to explain pardon me) but we still have surprises like &nbsp and &amp appearing depending on what is entered in primavera.
how do I eliminate ALL html codes? currently the code looks like this:
REPLACE(REPLACE(REGEXP_REPLACE(utl_raw.cast_to_varchar2(dbms_lob.substr(tm.task_memo)), '<[^>]+>'),CHR(13),''),CHR(10),'') AS Narratives
Thank you.

Your welcome, please do not forget to mark it as answered.
If you can examine the string in the database, you can use dump to see which character is at the end of the line.
In this sample I have placed a chr(0) at the end of the string to show it:
Decimal:
select dump('testing'||chr(0),8) from dual;
Output: Typ=1 Len=8: 164,145,163,164,151,156,147,0
Hex:
select dump('testing'||chr(0),16) from dual;
Output: Typ=1 Len=8: 74,65,73,74,69,6e,67,0
Edited by: specdev on 6-aug-2012 5:08
Answered without receiving helpful or correct answer points :-( but we make somebody happy today :-)

Similar Messages

  • Remove html code from file

    I'm trying to figure out how to remove all the html code from a file.
    I've got an AppleScript but it doesn't remove all the code
    <code>
    on run {}
    copy (choose file with prompt "Remove markup from which file:") to the_file
    promptuser(thefile)
    end run
    on open (the_file)
    if length of the_file > 1 then
    display dialog "Please drop only one file on me at a time."
    else
    promptuser(thefile)
    end if
    end open
    on promptuser(afile)
    copy (read a_file) to message_text
    copy (open for access file ((path to desktop as text) & "Markup Removed") with write permission) to newfileID
    write removemarkup(messagetext) starting at eof to newfileID
    close access newfileID
    end prompt_user
    on removemarkup(thistext)
    set copy_flag to true
    set the clean_text to ""
    repeat with this_char in this_text
    set this_char to the contents of this_char
    if this_char is "<" then
    set the copy_flag to true
    else if the copy_flag is true then
    set the clean_text to the clean_text & this_char as string
    end if
    end repeat
    return the clean_text
    end remove_markup
    </code>

    The source code is from a Yahoo Movie listing (http://uk.movies.yahoo.com/)
    Most of the code is removed but there's still bits left over from Javascripts & images, I think.

  • How to remove all pages from layout? (except Master Page)

    Geetings Experts:
    I'm implementing additional security measures into my 'initialze' event, where I'll check some global variables and render the file unreadable if needed.
    Which object and properties do I access to remove all my pages from the form?
    I would like to createa a function that removes all the sub pages, leavning only the Matster Page, enable a label in the MasterPage and save itself.
    I searched for xfa.layout and Page[n].remove() methods but cannot find any reference to these.
    .presence = "hidden", fulfills my purpose but the pages remian visible and I need for a clean solution no pages are visible.
    I'm advanced in C# but a novice in LC JavaScript, so any comment, reference or code snipet will be greatly appreciated
    Thank you for your time,
    Ivan A. Loreto – Computer Education Technician
    LOMA LINDA UNIVERSITY | School of Allied Health Professions - Department of Physical Therapy
    [PDF Development Platform]
    Windows XP SP3
    Acrobat Pro 9
    LifeCycle Designer ES 8.2

    Hi Ivan,
    The particular syntax of Javascript in LC Designer is different from that used in Acrobat and different (as I understand it) from core javascript and other applications. There are several free guides on the Adobe web site which cover Acrobat and LC:
    http://www.adobe.com/go/learn_lc_scriptingBasics
    http://www.adobe.com/go/learn_lc_scriptingReference
    http://www.adobe.com/go/learn_lc_formCalc
    http://www.adobe.com/devnet/livecycle/articles/Adobe_XML_Form_Object_Model_Refer ence.pdf
    http://www.adobe.com/devnet/acrobat/pdfs/lc_migrating_acrobat_xmlform.pdf
    And a very handy resource (it goes back to version 6, but is still applicable):http://partners.adobe.com/public/developer/en/tips/CalcScripts.pdf
    JP Terry's book on LC Forms is very good and we use www.pdfscripting (which is a subscription service). If you are going to be doing a lot of LC Designer work, these may be of help.
    I am not a coder, so I going to try and work through your script. Bear with me if you already have this sorted...
    The script looks ok and you are using the resolveNode method correctly. Seeing topmostSubform in the resolveNode indicates that you imported an existing document into LC. This is fine, but sometimes it restricts some of the functionality.
    For starters I think that mPg is returning null. You can use the following in your script to see what is happening (debugging) and then comment it out:
    console.println("mpg: " + mPg);
    Then when previewing hit control+J to bring up the javascript console, then will show the value of mPg when that script executes.
    Try deleting the SOM up to #pageSet:
    var mPg = xfa.resolveNode("#pageSet.MasterPage1");
    The javascript console will show you when the script is working.
    In relation to the loop, I would advise a few changes:
    for (var i=1; i <= xfa.layout.pageCount(); i++)
         var vPage = ("xfa.form.topmostSubform.Page" + i).toString();
         //console.println("vPage: " + vPage);
         var curPage = xfa.resolveNode(vPage);
         curPage.presence = "hidden"; 
    }//next page
    There are a few things here:
    I would declare i as a variable, not an integer (not sure if it makes a difference);
    I would use pageCount rather than numPages and then <=;
    There was an extra ; at the end of the loop declaration;
    I would break the script into steps and get the full SOM of the page as a variable first and then resolveNode that variable;
    You don't need to go to the current page;
    I tend to name master pages with a capital "P" and pages with a small "p". Personal preference, but it can make tracking script easier.
    Have a crack off that and hopefully you can get it to work,
    Niall
    ps another tip, if you want to reference an object in script. First click on the object you want to script for and then scroll (or click on the master page) for the object you want to reference. Click inside the script editor and then when you move the mouse back into the form, press and hold Control, this will turn the mouse into a "V". When you click on the object you want to reference it will insert the SOM into the script. If it needs the resolveNode it will automatically put that in for you. Holding Shift and Control will insert a fully resolved node.

  • Help removing encoded html from string

    Hello,
    I am trying to remove all html from a user input string.
    something like this:
    <cfset string ="sample text &lt;a&gt;">
    I have tried:
    Replace(string , "<[^>]*>", "", "ALL")
    Replace(string , "&lt;br &##x2f;&gt;>", "", "ALL")
    Neither remove the html, can anyone help?

    The related functions for replacing strings using regular expressions are REReplace and REReplaceNoCase. For example,
    <cfset string ="sample text <a>">
    <cfoutput>#REReplace(string , "<[^>]*>", "", "ALL")#</cfoutput>

  • How to Hide HTML code of web application (applet)?

    hi
    On web, while running application, if user open View\Source from browser, he can see all HTML code (base_jini.html). The problem is that we can't afford to show source code to client, because it has DB connection inf (username/password) as well. How this html code can be hide from client machine?
    I think, i convey my prblom. If not, please run any web application and try to see source code from browser view menu, U will see that all configuration details are visible including db password. I suppose there should be some way to hide these details to client.
    Please help in this regard, i will be very thankful
    regards
    Asif

    Forms Listener Servlet is just another way of setting up forms on the web. The main difference is instead of the client and the Forms runtime talking directly, they do so via the webserver. This means thay you only need to have one port opened in your firewalls (e.g. 80) instead of two (80 and 9000)
    Please read the paper I indicated and this will hopefully explain it all.
    As to the suggestion of using the LOGON built int - this would be a solution but you will have to consider if this is acceptable if you have more that one user since the person running the application would have to identify themselves in some way.
    The other option is do not add the username and password in teh HTML and the default logon dialog will appear.
    Regards
    Grant Ronald
    Forms Product Management

  • Regex - Remove specific HTML Tags

    I have already found a solution in the forum to remove all html tags but I need some specific tags - img, a, b, i, u - and also their closing tags - </a>, </b>.
    The regex also needs to differ between img without the class attribute and with class attribute - it should remove elements with class attribute
    So I have tried to modifiy the found solution:
    result = Regex.Replace(result, "<[^(img|a|b|i|u)][^>]*>", " ");
    It works not optimal because it also removes the closing tags, doesn't differ and doesn't remove the br tags. It's not necessary to do all these actions in one statement.

    you can use regular
    <[(/body|html)\s]*>
    in c#:
    var result = Regex.Replace(html, @"<[(/body|html)\s]*>", "");
    <html>
    <body>
    < / html>
    < / body>

  • Problem with inserting html code.

    Hello,
    I have a problem with the inclusion of this code html connected to the CSS style sheets:
    <head>
    <link href='http://fonts.googleapis.com/css?family=Raleway:320,320,300' rel='stylesheet' type='text/css'>
    <link rel="stylesheet" type="text/css" href="assets/normalize.css" />
    <link rel="stylesheet" type="text/css" href="assets/demo.css" />
    <link rel="stylesheet" type="text/css" href="assets/component.css" />
      </header>
        <div class="grid">
        <figure class="effect-lily">
        <img src="assets/1.jpg" alt="img01" class="effect-honey"/></figure>
      </a>
    </section>
    </div><!-- /container -->
    </body>
    </html>
    1) Does not appear in the preview thumbnail adobe muse.
    2) The pull-down menu or previously entered disappears from display problems once exported the site in html.
    Removing the html code menu work correctly.
    Where is the problem ??

    Most likely there is a critical code error somewhere. Use the W3C validation tools to check your CSS and HTML code.
    CODE VALIDATION TOOLS
    CSS - http://jigsaw.w3.org/css-validator/
    HTML - http://validator.w3.org/
    Nancy O.

  • How to remove all of the tags from a HTML file

    Hi all,
    I am developing a search program.
    User will enter a word or some text in a textfield and after click on go button it will search the word from the html file which is reside in c: drive.
    What I am trying to do is -- reading file and storing data/contents of the file in a String and so on............then store in a Vector.....so on.......
    My question is ----- how can I remove all of the html tags such as: <p>, <b>,</b> <h1>, <strong>, or whatever from the String (where I store the data/contents of the html file) or from a HTML file.
    I would appreciate sample code if anyone has any.
    please help me in this way.
    Thanks in advance
    Thanks a lot.
    amitindia

    Hi dear,
    I got the link and have found examples.
    thanks for solving my problem.
    Thanks for your prompt reply.
    amitindia
    India

  • While in Edit Mode in Moodle - page content does not render at all, but I am able to display the underlying HTML code. Happens only after upgrade to Firefox 11.0.

    While in edit mode in the Moodle course management system, the Page Content window should display the page as it will appear to the user. If you click on the "Edit" button, you are able to view the HTML code for the page. However, when you return to the normal display mode, the page is blank. This has occurred after the upgrade to Firefox 11.0. Page is normally rendered in Internet Explorer.

    A possible cause is security software (firewall,anti-virus) that blocks or restricts Firefox or the plugin-container process without informing you, possibly after detecting changes (update) to the Firefox program.
    Remove all rules for Firefox and the plugin-container from the permissions list in the firewall and let your firewall ask again for permission to get full unrestricted access to internet for Firefox and the plugin-container process and the updater process.
    See:
    *https://support.mozilla.org/kb/Server+not+found
    *https://support.mozilla.org/kb/Firewalls
    See also:
    *http://kb.mozillazine.org/Error_loading_websites
    *https://support.mozilla.org/kb/Error+loading+web+sites

  • Function to unformat HTML code

    I start to build a report with CF Report Builder (8) and at
    some point, I realize that one of the field I need to display have
    HTML code (e.g.: <p>, <b>, etc...). The fact is that
    this field is using a Rich Editor (FCKEditor) when input the text.
    Until now, I did not have any problem with this but it displays all
    the code in the report (in the CF Report Builder) and it is not
    really human-friendly. I saw that it is a function to transform
    basic text in HTML but is it something to do the inverse?
    Thank's for any help!

    Interesting comment: starting with a drastic "no help for
    you" and finishing with a hope!!! ;-)) I like it!
    Well you actually gave me the idea. I found something on
    CFLIB.org yes but it was not doing the job properly so I did my own
    code to convert the string before passing it to the CFR (as a
    parameter) and as I have only few HTML tags to take car, it was
    done in a matter of 2 minutes.
    Thank you because you make me thing in a new direction!
    <cfparam name="url.TicketID" default="79">
    <cfinclude template="tagStripper.cfm">
    <cfquery name="qGetProblemDescription"
    datasource="#application.DNS#">
    SELECT ProblemDescription
    FROM TICKET
    WHERE TICKETID = #url.TicketID#
    </cfquery>
    <cfset vDescription =
    qGetProblemDescription.ProblemDescription>
    <cfset vDescription = ReplaceList(vDescription,
    "<p>", "")>
    <cfset vDescription = ReplaceList(vDescription,
    "</p>", chr(13))>
    <cfset vDescription = ReplaceList(vDescription,
    "<br>", chr(10))>
    <cfset vDescription = ReplaceList(vDescription,
    "<br/>", chr(10))>
    <cfset vDescription = ReplaceList(vDescription,
    "<hr>", chr(10))>
    <cfset vDescription = ReplaceList(vDescription,
    "</hr>", chr(10))>
    <cfreport template="WorkOrderInformation_en.cfr"
    format="pdf">
    <cfreportparam name="TicketID" value="#url.TicketID#">
    <cfreportparam name="ProblemDescription2"
    value="#vDescription#">
    </cfreport>

  • How to remove all in and out points from extendscript code?

    Hi,
         I am creating a sequence from a clip from extendscript code to automateToSequence function.
         But if there are some in and out points in the clip only the select clip part is converted as a sequence, what is the solution to remove all those in and out points from extendscript code, or to get the full clip to sequence even there are some in and out points.
    I am using the function like this; qe.project.getItemAt(i).automateToSequence(seq,0,0,1,1);
    Please suggest,
    Thanks and Regards,
    Anoop NR

    Double click the pre-comp or nested comp, open comp settings from the menu or by using the keyboard shortcut Ctrl/Cmnd + k.
    Note, changing the length of the comp will not extent the length of footage or layers inside the comp. You have to do that manually and it depends on your footage type.

  • How to remove extra line breaks in my html code?

    On my website: 2neatmagazines.com, I have old html, written years ago. The html all functions fine, no problems in the broswers. When I Iook at the code, there are lots of line breaks in the text portions.
    I can do "apply source formatting", and that has cleaned and aligned the html code nicely. But, the text descriptions in the html still breaks at fixes places. This does not affect how it renders, just how the code looks. For example:
                      <p align="left"><span class="blacksregularbold"><span class="blackregular">Life
                        Magazine </span>January 11, 1937</span> : Cover - Japanese
                        soldiers doing their exercises. Full page LIFE magazine
                        ad with railroad locomotive at night. The &quot;first&quot;
                        candid photographs taken by Paul Nadar of Paris in 1886.
                        Governors - new and old. Margaret Sanger wins the court
                        victory that birth control contraceptives can be sent
                        by mail, long fight for related women's rights . Bootleg
                        coal mining near Shamokin, Pennsylvania. Painter Winslow
                        Homer. Dinosaurs Enshrined (collection, storage and
                        display of dinosaur fossils in museums, including Dinosaur
                        National Monument). Baths of Foam, milk, mud,and wax
                        for beauty. . Theatre in 1936 and 1937. Japanese Army.
                        Sonja Henie in her movie &quot;One in a million.&quot;
                        Includes photos of Sonja Henie bicycling - looks like
                        today's town cruiser bikes. . Amazing series of photos
                        of San Francisco people interacting (or not) with bum
                        laying on sidewalk. Photos from wreck of United Airliner
                        which crashed December 27, 1936 in the Santa Susana
                        Mountains of California. Five airline crashes in two
                        weeks at end of 1936. Ice hockey fights. &quot;Tobacco
                        Road&quot; on Broadway. Japanese soldiers training.
                        Neat photo of five new locomotives in a row, Canadian
                        National Railways. <br />
                        <span class="redregular">Very Good</span> - $52
    I would like the main text to be wrapped, and neat. I have tried various "text cleaners" like Haven for the mac, but none of the settings will get rid of this annoying line break formatting.
    Any suggestions would be appreciated.
    mark

    The only "Line Break"
    <br /> I see is at the end.
    Code formating just cleans the display of the visual code it doesn't effect the browser display.
    You can do a "Search and Replace" the <br /> with nothing. to strip all <br /> for the whole site or DIR or page.
    In code view right mouse click and choose
    "Search and Replace"
    Is this what your are asking help on?
    Shane

  • Trying to install Creative Cloud Desktop on windows 8.1, I've tried everything. Cloud Cleaner, removed all Adobe products from computer, ran in Administrator Deleted everything still get error code 1

    I've tried everything. Cloud Cleaner, removed all Adobe products from computer, ran in Administrator Deleted everything still get error code 1 noting in all the troubleshoots have helped.

    Error Code 1: "Failed to install" | Creative Cloud Desktop :
    https://helpx.adobe.com/creative-cloud/kb/failed-install-creative-cloud-desktop.html

  • How do I remove "ALL" incontext editing code?

    Hi, I am hoping someone maybe able to help...
    A while ago I put a site together at applied incontext editing regions. After being notified that it will no longer work in May this year, I decided to purchase contribute and went through the labourious task of removing all incontext editable regions and replacing them with normal editable regions.
    I have launched the site in contribute to test that everything works and it keeps coming up with 'You can't edit this page in Contribute because it has "Adobe InContext Editing" region(s).
    This is on almost every page on the site but two which it allows me to edit. I have gone back to the Dreamweaver file and checked through the code, I am certainly no code expertI have compared it to sites which didnt have the InContext applied to it... I am baffled
    Can anyone shed any light on the situation?
    Much appreciated
    Naomi

    I think I can see the problem! - I have updated the file in dreamweaver but it
    is not updating the copy on the server when I upload it...
    I can see the code that I have deleted still showing at the top of the page - I just cant get it to refresh!
    I will try doing it with fetch.....
    Just done it with fetch and it works! - Dreamweaver will not refresh the server copy.

  • [svn] 3120: When you point Flex Builder at a local sandbox trunk build, it couldn' t generate the html-templates folder correctly for new projects so we moved all the html templates up one level and removed the html-templates directory and adjusted build

    Revision: 3120
    Author: [email protected]
    Date: 2008-09-05 10:44:10 -0700 (Fri, 05 Sep 2008)
    Log Message:
    When you point Flex Builder at a local sandbox trunk build, it couldn't generate the html-templates folder correctly for new projects so we moved all the html templates up one level and removed the html-templates directory and adjusted build.xml's to accommodate the directory change
    Modified Paths:
    flex/sdk/trunk/build.xml
    flex/sdk/trunk/webapps/webtier/build.xml
    Added Paths:
    flex/sdk/trunk/templates/client-side-detection/
    flex/sdk/trunk/templates/client-side-detection/AC_OETags.js
    flex/sdk/trunk/templates/client-side-detection/index.template.html
    flex/sdk/trunk/templates/client-side-detection-with-history/
    flex/sdk/trunk/templates/client-side-detection-with-history/AC_OETags.js
    flex/sdk/trunk/templates/client-side-detection-with-history/history/
    flex/sdk/trunk/templates/client-side-detection-with-history/history/history.css
    flex/sdk/trunk/templates/client-side-detection-with-history/history/history.js
    flex/sdk/trunk/templates/client-side-detection-with-history/history/historyFrame.html
    flex/sdk/trunk/templates/client-side-detection-with-history/index.template.html
    flex/sdk/trunk/templates/express-installation/
    flex/sdk/trunk/templates/express-installation/AC_OETags.js
    flex/sdk/trunk/templates/express-installation/index.template.html
    flex/sdk/trunk/templates/express-installation/playerProductInstall.swf
    flex/sdk/trunk/templates/express-installation-with-history/
    flex/sdk/trunk/templates/express-installation-with-history/AC_OETags.js
    flex/sdk/trunk/templates/express-installation-with-history/history/
    flex/sdk/trunk/templates/express-installation-with-history/history/history.css
    flex/sdk/trunk/templates/express-installation-with-history/history/history.js
    flex/sdk/trunk/templates/express-installation-with-history/history/historyFrame.html
    flex/sdk/trunk/templates/express-installation-with-history/index.template.html
    flex/sdk/trunk/templates/express-installation-with-history/playerProductInstall.swf
    flex/sdk/trunk/templates/metadata/
    flex/sdk/trunk/templates/metadata/AC_OETags.js
    flex/sdk/trunk/templates/metadata/readme.txt
    flex/sdk/trunk/templates/no-player-detection/
    flex/sdk/trunk/templates/no-player-detection/AC_OETags.js
    flex/sdk/trunk/templates/no-player-detection/index.template.html
    flex/sdk/trunk/templates/no-player-detection-with-history/
    flex/sdk/trunk/templates/no-player-detection-with-history/AC_OETags.js
    flex/sdk/trunk/templates/no-player-detection-with-history/history/
    flex/sdk/trunk/templates/no-player-detection-with-history/history/history.css
    flex/sdk/trunk/templates/no-player-detection-with-history/history/history.js
    flex/sdk/trunk/templates/no-player-detection-with-history/history/historyFrame.html
    flex/sdk/trunk/templates/no-player-detection-with-history/index.template.html
    Removed Paths:
    flex/sdk/trunk/templates/html-templates/

    Remember that Arch Arm is a different distribution, but we try to bend the rules and provide limited support for them.  This may or may not be unique to Arch Arm, so you might try asking on their forums as well.

Maybe you are looking for

  • Can't save pdf from a web site - HELP!

    I can't seem to save pdf files from a brokerage account.  I have Reader 9, and one one PC, there is no "save icon" on the tool bar, and no "wording tool bar" -ie, no headong of:  File - Edit - View, etc.  On the other , there is no edit portion of th

  • How do I get rid of recent circles on my home page after installing ios8

    How do I get rid of recent circle notifications on my iPad after installing iOS 8

  • Authorization object for a technical role

    Hi all, I have a technical role "SM_ORDERAPPROV_00", to which I need to find out the authorization object.  Could anybody help me in finding this.  I searched this in SUIM also, but I didn't find any. Thanks, bsv.

  • Credit management mass change FD37 or F.34

    Hi SAP Experts, I'm confused in transaction code FD37 and F.34, I can't find any documents that would discuss their differences between SAP versions. I'm using 4.6c and both transaction are existing in table TSTC, however, F.34 is executable but FD37

  • Keyboard layout recognition

    Hi I am an italian user of FCS. As we know the program works by recognizing only the English keyboards. Every time I start the program I must set the keyboard layout in the Default US mode. Is there a way to avoid this? Or, at least, can automate thi