Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Inline image in html dynamic textbox

Status
Not open for further replies.

mobius1983

Technical User
Jul 7, 2002
45
GB
Hi everyone,

I hope someone can help, I have been going around in circles for days!! :)

I am building a chat room for a charity, it uses a php socket server and a flash front end. The flash has a dynamic html text box and each xml communication from the server is formatted and added to the htmlText.

Everything is working fine, but I wanted to add the functionality of sending 'emoticons' with the chat. To do this I format the message coming from the server to replace the shortcut string with an <img> tag,
Code:
 msgBody =  msgBody.split("(1)").join("<img src='1.jpg' height='14px' width='14px' hspace='0' vspace='0' />");}
but (and here is the annoying BIG but!) it all works fine apart from the images always appear on a separate line below the text rather than inline even though a trace of the html looks good.

Anyone that can help would save me pulling my hair out over the next few days! :)

Many thanks,
Nick
 
This is a well known issue, and there are no easy workarounds. Using a smiley font is the easiest solution. Or you can code it using ScrollPane - actually people has done this for a long time, if you Google I'm sure you can find the code or two.

Kenneth Kawamoto
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top