Using ASP variables with HTML

Discussion in 'ASP General' started by Leeper, Feb 25, 2004.

  1. Leeper

    Leeper Guest

    Here is the line that I am using.
    response.write("<p style='color:" & Item"'></p>")
    the word Item is a variable with hex code in it for color. This is
    pretty simple I think, but how can I get this variable to work with
    this HTML. Any help would be greatly appreciated.

    Thanks
    Ryan
     
    Leeper, Feb 25, 2004
    #1
    1. Advertising

  2. Leeper

    Ray at Guest

    What isn't working about it? Are you getting an error of some sort? It
    seems fine to me, although I'd change the variable name to something along
    the lines of sColor.

    Ray at work

    "Leeper" <> wrote in message
    news:...
    > Here is the line that I am using.
    > response.write("<p style='color:" & Item"'></p>")
    > the word Item is a variable with hex code in it for color. This is
    > pretty simple I think, but how can I get this variable to work with
    > this HTML. Any help would be greatly appreciated.
    >
    > Thanks
    > Ryan
     
    Ray at, Feb 25, 2004
    #2
    1. Advertising

  3. Leeper

    Ray at Guest

    I take back my "It seems fine to me" statement after reading Peter's post.
    [;

    Ray at work

    "Ray at <%=sLocation%> [MVP]" <myfirstname at lane34 dot com> wrote in
    message news:u2X%23fG%23%...
    > What isn't working about it? Are you getting an error of some sort? It
    > seems fine to me, although I'd change the variable name to something along
    > the lines of sColor.
    >
    > Ray at work
    >
    > "Leeper" <> wrote in message
    > news:...
    > > Here is the line that I am using.
    > > response.write("<p style='color:" & Item"'></p>")
    > > the word Item is a variable with hex code in it for color. This is
    > > pretty simple I think, but how can I get this variable to work with
    > > this HTML. Any help would be greatly appreciated.
    > >
    > > Thanks
    > > Ryan

    >
    >
     
    Ray at, Feb 25, 2004
    #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. sagejoshua
    Replies:
    16
    Views:
    676
    Michael Winter
    Nov 9, 2005
  2. Adel
    Replies:
    3
    Views:
    328
    Jack Klein
    Mar 17, 2005
  3. Replies:
    9
    Views:
    1,008
  4. Ravi Parimi
    Replies:
    16
    Views:
    218
    Thomas Kratz
    May 13, 2004
  5. Frank

    Using variables as variables

    Frank, Apr 9, 2007, in forum: Javascript
    Replies:
    4
    Views:
    137
    Dr J R Stockton
    Apr 10, 2007
Loading...

Share This Page