Jump to content
Fórum Script Brasil
  • 0

Inserir Imagem usando string


Donnerak

Question

Bom Dia, caso eu tenha postado no local errado, por favor mover.

Minha dúvida é a seguinte:

Tenho esta função que monta os menus.

the_menu = the_menu + "<span onClick=\"return sub_menu(" + i + ");\">" + mainmenu + "</span> | ";

Esta parte pega o nome do menu + mainmenu +

Eu gostaria de ao invés de pegar o nome do menu ele aparecesse a imagem correspondente ao menu. Eu tentei fazer desse modo mas não deu..

the_menu = the_menu + "<span onClick=\"return sub_menu(" + i + ");\">"<img src="\mainmenu".png" </span> | ";

Obrigado pela atenção...

[RESOLVIDO] ---------------------------------------

obrigado

the_menu = the_menu + "<span onClick=\"return sub_menu(" + i + ");\"><img src=\""+mainmenu+".png\" /> </span> | ";

Edited by Donnerak
Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



  • Forum Statistics

    • Total Topics
      152k
    • Total Posts
      651.5k
×
×
  • Create New...