HTML Decoding

Discussion in 'ASP .Net' started by Uriah Piddle, Jan 7, 2007.

  1. Uriah Piddle

    Uriah Piddle Guest

    Hi Gang,

    I have text that I am putting into a label that has been custom formatted by
    a text editor and looks like this:

    Some outside text <crl>Some inside text</clr> Some outside text

    How can I map this to an item in a CSS file so that I can use it to format
    the 'Some inside text' portion of the text?

    Thanks.

    Steve
     
    Uriah Piddle, Jan 7, 2007
    #1
    1. Advertising

  2. Well I dont think you can map it to CSS without changing it to something CSS
    can identify against. So, before you add the text to the label do a string
    replace on the crl so it becomes a DIV and manipulate the DIV as you would
    any div from CSS. Of course you'll need to close the DIV correctly also.

    So:
    Some outside text <crl>Some inside text</clr> Some outside text
    becomes
    Some outside text <div class="crl">Some inside text</div> Some outside text

    --
    Regards

    John Timney (MVP)
    VISIT MY WEBSITE:
    http://www.johntimney.com
    http://www.johntimney.com/blog


    "Uriah Piddle" <> wrote in message
    news:...
    > Hi Gang,
    >
    > I have text that I am putting into a label that has been custom formatted
    > by a text editor and looks like this:
    >
    > Some outside text <crl>Some inside text</clr> Some outside text
    >
    > How can I map this to an item in a CSS file so that I can use it to format
    > the 'Some inside text' portion of the text?
    >
    > Thanks.
    >
    > Steve
    >
     
    John Timney \(MVP\), Jan 7, 2007
    #2
    1. Advertising

  3. Uriah Piddle

    Uriah Piddle Guest

    Thanks John.

    "John Timney (MVP)" <> wrote in message
    news:...
    > Well I dont think you can map it to CSS without changing it to something
    > CSS can identify against. So, before you add the text to the label do a
    > string replace on the crl so it becomes a DIV and manipulate the DIV as
    > you would any div from CSS. Of course you'll need to close the DIV
    > correctly also.
    >
    > So:
    > Some outside text <crl>Some inside text</clr> Some outside text
    > becomes
    > Some outside text <div class="crl">Some inside text</div> Some outside
    > text
    >
    > --
    > Regards
    >
    > John Timney (MVP)
    > VISIT MY WEBSITE:
    > http://www.johntimney.com
    > http://www.johntimney.com/blog
    >
    >
    > "Uriah Piddle" <> wrote in message
    > news:...
    >> Hi Gang,
    >>
    >> I have text that I am putting into a label that has been custom formatted
    >> by a text editor and looks like this:
    >>
    >> Some outside text <crl>Some inside text</clr> Some outside text
    >>
    >> How can I map this to an item in a CSS file so that I can use it to
    >> format the 'Some inside text' portion of the text?
    >>
    >> Thanks.
    >>
    >> Steve
    >>

    >
    >
     
    Uriah Piddle, Jan 8, 2007
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. IgorD

    decoding html in java

    IgorD, Jan 20, 2006, in forum: Java
    Replies:
    2
    Views:
    15,341
    Roedy Green
    Jan 20, 2006
  2. rabby
    Replies:
    2
    Views:
    426
    gene tani
    Dec 20, 2005
  3. Replies:
    5
    Views:
    2,302
  4. Anuj

    Decoding HTML entities

    Anuj, Jul 24, 2003, in forum: ASP General
    Replies:
    0
    Views:
    124
  5. Morgan

    Adventures in html decoding.

    Morgan, Sep 12, 2005, in forum: Ruby
    Replies:
    14
    Views:
    240
    Martin DeMello
    Sep 17, 2005
Loading...

Share This Page