healingtao
asked on
very, very urgent, please help
I put image of a button on a background of the table cell in order to load text inside the cell. I need to do this because the button text can be in different languages. The background was done because client likes this look and feel. But we were told that this is clickable button that needs to send data to the server. I'm not sure how to do it using this background and changing the text dynamically on load. Here is the sample code. This is extremely urgent, please help.
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<form name="form1" method="post" action="">
<table width="60%" border="0">
<tr>
<td height="117" background="images/WS_addF F_EN/WS_ad dFF_EN_05. jpg">
<div align="center"><font color="#FFFFFF" face="Arial, Helvetica, sans-serif" size="+1">text
for position only</font></div>
</td>
</tr>
</table>
</form>
</body>
</html>
The text - "text for position only" will need to change based on language, but we also need this to be a button that will submit the rest of the form data to the server.
Thanks in advance
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<form name="form1" method="post" action="">
<table width="60%" border="0">
<tr>
<td height="117" background="images/WS_addF
<div align="center"><font color="#FFFFFF" face="Arial, Helvetica, sans-serif" size="+1">text
for position only</font></div>
</td>
</tr>
</table>
</form>
</body>
</html>
The text - "text for position only" will need to change based on language, but we also need this to be a button that will submit the rest of the form data to the server.
Thanks in advance
specifically:
<div align="center" onclick="document.form1.su bmit();">
<font color="#FFFFFF" face="Arial, Helvetica, sans-serif" size="+1">text for position only</font>
</div>
<div align="center" onclick="document.form1.su
<font color="#FFFFFF" face="Arial, Helvetica, sans-serif" size="+1">text for position only</font>
</div>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
KeK has it right put the onclick event on the td, and style the td with <td style="cursor:pointer">
Cd&
Cd&
ASKER
Amig,
Can I write text on top of image in the foreground? If yes, how do I do this?
Can I write text on top of image in the foreground? If yes, how do I do this?
ASKER
Guys,
I tried
<form name="form1" method="post" action="https://www.experts-exchange.com"">
<td height="117" background="images/WS_addF F_EN/WS_ad dFF_EN_05. jpg" onclick="document.form1.su bmit();" >
and i's working on my machine (winXP) but on another machine I have Mac os10 it doesn't go to experts page.
Does anyone know why???
I tried
<form name="form1" method="post" action="https://www.experts-exchange.com"">
<td height="117" background="images/WS_addF
and i's working on my machine (winXP) but on another machine I have Mac os10 it doesn't go to experts page.
Does anyone know why???
No, you cannot write text on an image on foreground. Actually you can but only in newer browsers by using absolute positioning of the text. What I was suggesting is to have different button images in different languages and change the src of image button based on language.
For the very same reason support for TD onclick isn't very good. Don't know specifically about Max OS but I won't be surprised if it doesn't work.
If you have different images for different languages, that should work in all browsers but obviously that would require more from the image designers and I don't know how many languages and how many buttons you have. If number of images is a concern, try the <a> link method.
For the very same reason support for TD onclick isn't very good. Don't know specifically about Max OS but I won't be surprised if it doesn't work.
If you have different images for different languages, that should work in all browsers but obviously that would require more from the image designers and I don't know how many languages and how many buttons you have. If number of images is a concern, try the <a> link method.
ASKER
Thanks for all your help
<div align="center" onclick="document.form1.su