dynamic attributes in jsp:plugin tag

Discussion in 'Java' started by Bronwyn Howard, Jul 24, 2003.

  1. I need to know how to put dynamic attributes in my jsp:plugin tag.

    I've tried a combination of things, but I essentially want to do this:

    String codeBase = clientBean.getCodebase();
    %>
    <html>

    <jsp:plugin
    type="applet"
    code="chatapplet.chatMain"
    codebase=<%=codeBase%>
    height="200"
    width="300"
    target="_blank"
    jreversion="1.3"
    nspluginurl="http://java.sun.com/products/plugin/1.3/plugin-install.html"
    iepluginurl="http://java.sun.com/products/plugin/1.3/jinstall-131-win32.cab"
    >


    I've tried "<%=codeBase%>".. I've also tried escape characters, and a
    combination of all of the above as well as just crazy stuff that would
    obviously not work, just in case it did.

    I've seen plenty of people on groups asking the same question, but
    noone ever seems to get a reply, or leave an e-mail or other contact
    so I can ask them.

    Can someone PLEASE give me the answer!!

    Bronwyn.
    Bronwyn Howard, Jul 24, 2003
    #1
    1. Advertising

  2. Bronwyn Howard

    Sudsy Guest

    Bronwyn Howard wrote:
    > I need to know how to put dynamic attributes in my jsp:plugin tag.
    >
    > I've tried a combination of things, but I essentially want to do this:
    >
    > String codeBase = clientBean.getCodebase();
    > %>
    > <html>
    >
    > <jsp:plugin
    > type="applet"
    > code="chatapplet.chatMain"
    > codebase=<%=codeBase%>
    > height="200"
    > width="300"
    > target="_blank"
    > jreversion="1.3"
    > nspluginurl="http://java.sun.com/products/plugin/1.3/plugin-install.html"
    > iepluginurl="http://java.sun.com/products/plugin/1.3/jinstall-131-win32.cab"
    >


    Try this as your boilerplate:

    <bean:define id="xxx" value="this_is_a_test"/>
    <jsp:plugin
    type="applet"
    code="chatapplet.chatMain"
    height="200"
    width="300"
    jreversion="1.3"

    nspluginurl="http://java.sun.com/products/plugin/1.3/plugin-install.html"

    iepluginurl="http://java.sun.com/products/plugin/1.3/jinstall-131-win32.cab">

    <jsp:params>
    <jsp:param name="java_codebase" value="<%= xxx %>" />
    </jsp:params>
    </jsp:plugin>

    (I'm just using the bean:define and the variable xxx as examples)
    Sudsy, Jul 24, 2003
    #2
    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. jstack
    Replies:
    1
    Views:
    587
    Tor Iver Wilhelmsen
    Jul 4, 2003
  2. Crowther
    Replies:
    0
    Views:
    3,865
    Crowther
    Nov 19, 2003
  3. Raymond DeCampo

    Custom tags and <jsp:plugin> / <jsp:param>

    Raymond DeCampo, Feb 18, 2004, in forum: Java
    Replies:
    0
    Views:
    614
    Raymond DeCampo
    Feb 18, 2004
  4. shruds
    Replies:
    1
    Views:
    757
    John C. Bollinger
    Jan 27, 2006
  5. phil89
    Replies:
    0
    Views:
    686
    phil89
    Mar 13, 2009
Loading...

Share This Page