Forums
This topic is locked
Replacing Y and N values with a gif in table cell
Posted 20 Apr 2001 10:42:20
1
has voted
20 Apr 2001 10:42:20 Davy Fennell posted:
Does anyone know how I can replace the values of Y and N with a gif? The values are returned from an Access DB to a table cell on the user's browser.DETAIL:
I have a table that is displaying rows of Y and N values in individual cells of a table. I would like to replace the Y and N values with a respective small gif to make the table easiar on the eye. Even better would be the ability to change the colour of the cell. Is there a behaviour or extension anyone knows of that can do this. Note: I guess two gifs would exist. One for Y and N respectively. Also, can the replaced Y and N values be a path to a gif stored in the \images folder.
A big HIP HIP HOORAY for anyone who can answer this.
Many thanks,
Davy<b></b><b></b>
Replies
Replied 20 Apr 2001 12:40:44
20 Apr 2001 12:40:44 Waldo Smeets replied:
Davy, I think you need the Conditional Region extension: www.UDzone.com/go?66
Use the DB Field and Script server behavior of that suite to show or hide images depending a value from the database.
There's also a basic tutorial at www.UDzone.com/go?355 .
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Use the DB Field and Script server behavior of that suite to show or hide images depending a value from the database.
There's also a basic tutorial at www.UDzone.com/go?355 .
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Replied 20 Apr 2001 15:18:30
20 Apr 2001 15:18:30 Davy Fennell replied:
Waldo,
Thanks for the prompt reply. However, after looking at the tutorial and installing the extension it is not obvious to me how to replace a returned value with a gif path, e.g. \davy\images\pic.gif for example.
This extension allows you to Show or Hide a value. Is there something else I should be doing?
Cheers,
Davy
Thanks for the prompt reply. However, after looking at the tutorial and installing the extension it is not obvious to me how to replace a returned value with a gif path, e.g. \davy\images\pic.gif for example.
This extension allows you to Show or Hide a value. Is there something else I should be doing?
Cheers,
Davy
Replied 20 Apr 2001 17:03:51
20 Apr 2001 17:03:51 Waldo Smeets replied:
Davy, the trick behind this extension is not that you are writing the value directly to the page. What you are going to do is to use the value to show a region or not. So you need to put both an image for yes and an image for no in your document.
Then select the yes image and apply the Conditional Region > DB Field and Script Server Behavior to your page. For the database table and database field you need to select the table and the field that contain the value yes or no. Then type in script the value that your database returns for true (f.e. "true".
Right now your image will only be show when the value of the database field equals true.
I think the tutorial will give you some more infor on how to use this extension. I have to admin that it seems to be a littlebit difficult in the beginning. But once you understand how it works it'á very usefull <img src=icon_smile.gif border=0 align=middle>.
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Then select the yes image and apply the Conditional Region > DB Field and Script Server Behavior to your page. For the database table and database field you need to select the table and the field that contain the value yes or no. Then type in script the value that your database returns for true (f.e. "true".
Right now your image will only be show when the value of the database field equals true.
I think the tutorial will give you some more infor on how to use this extension. I have to admin that it seems to be a littlebit difficult in the beginning. But once you understand how it works it'á very usefull <img src=icon_smile.gif border=0 align=middle>.
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Replied 20 Apr 2001 17:34:41
20 Apr 2001 17:34:41 e site replied:
Hi Waldo!
that sounds great! And the extension is also more clear to me now
But does this also work for one FIELD in a record?
Cause I'm dealing with a similar thing:
I'm having an e-commerce thing going on and in my Acces DB I have a checkbox to show Yes or No a "Buy" button.
So if the product is in stock, the checkbox in the DB is checked and thus shows the "Buy" button.
I did not find a place to apply the extension on a field only...
Could you gimme a hint?
Groetjes uit België
e_site
that sounds great! And the extension is also more clear to me now
But does this also work for one FIELD in a record?
Cause I'm dealing with a similar thing:
I'm having an e-commerce thing going on and in my Acces DB I have a checkbox to show Yes or No a "Buy" button.
So if the product is in stock, the checkbox in the DB is checked and thus shows the "Buy" button.
I did not find a place to apply the extension on a field only...
Could you gimme a hint?
Groetjes uit België
e_site
Replied 20 Apr 2001 17:40:21
20 Apr 2001 17:40:21 Waldo Smeets replied:
Contact me at
with MS Messenger (don't send me mails there.. I don't read them at that address), and I'll try to help you out.
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Waldo Smeets - www.UDzone.com Webmaster
------------------------------------------
www.UDzone.com : A dynamic Dreamweaver,
Ultradev and Fireworks site for developers
by developers.
------------------------------------------
Replied 20 Apr 2001 17:46:55
20 Apr 2001 17:46:55 e site replied:
Hi Waldo,
cool!
I'll install that MSN messenger first and I will surely contact you when I'll be working on that page!
Thanx so much...
en nog een goei weekend!
e_site
cool!
I'll install that MSN messenger first and I will surely contact you when I'll be working on that page!
Thanx so much...
en nog een goei weekend!
e_site