473,322 Members | 1,409 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Makeing a button invisible.

KeredDrahcir
426 256MB
I want to be able to use CSS to make a button invisible but for people still be able to select it if they manage to mouse over.

I have no control of the HTML of the button and though this might be the best way of hidding it so I can put an image in it's place.

Is this the best way to go about it, and if so how do I do ir. I've set this visibility to none but it doesn't seem to let me click on it.
Apr 13 '11 #1

✓ answered by KeredDrahcir

Yes I did solve it, perhaos I can make myself more clear in case anyone else has this problem.

I changed the background colour, border colour and text colour of the button to the same colour as the background of the div it was in to hide the button and then changed the background image of the button to the image I wanted to use and changed the dimesnions of the button to fit the image.

4 3199
Rabbit
12,516 Expert Mod 8TB
You don't need to overlay an image on a button to make a clickable image. Just use an image with an onclick event or if you're just trying to link them to another page, use an anchor with an image.
Apr 13 '11 #2
KeredDrahcir
426 256MB
As I pointed out. I haven't got access to the source HTML, only the CSS.

I thought the onclick had to be included in the HTML rather than the CSS. Is that right? I think there is the same problem doing an anchor when an image.

Also the button is already included in the source which is why I need to hide it. I have sorted it but changing the border, background colour and text colour of the button the same same colour and setting the background image to the image as the button dimensions to fit.
Apr 14 '11 #3
Rabbit
12,516 Expert Mod 8TB
It sounds like you resovled your problem but I can't be sure. I'm having difficulty understanding what you're saying.
Apr 14 '11 #4
KeredDrahcir
426 256MB
Yes I did solve it, perhaos I can make myself more clear in case anyone else has this problem.

I changed the background colour, border colour and text colour of the button to the same colour as the background of the div it was in to hide the button and then changed the background image of the button to the image I wanted to use and changed the dimesnions of the button to fit the image.
Apr 15 '11 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: FantaJ | last post by:
Hi, Is it possible to make a html button invisible using javascript? I can certainly disable it: var x=document.getElementById('button2'); x.disabled=true; //x.type = 'hidden'; // read...
6
by: tshad | last post by:
I have 2 buttons: <asp:ImageButton ID="ExpandButton" runat="server" Font-Size="2" ImageUrl="../images/expand.jpg" Width="16" Height="16" CommandName="Select" AlternateText="Click here to see...
6
by: MW de Jager | last post by:
I'm trying to create an html page that will change dynamically. I need to switch html -buttons between visible and invisible. Is there any way I can do this with a script? Regards MW
8
by: massimo capetola | last post by:
I would like to make invisible the SIP button in my VB.net project, here is what I do on load event of the form "frmToto" Dim hWnd As IntPtr = FindWindow(Nothing, "frmToto") RC =...
1
by: shapper | last post by:
Hello, I have a link button which signs out the user when it is clicked. I place on by button the code line ibLogout.Visible = My.User.IsAuthenticated. So, when the user is authenticated...
1
by: esateesh | last post by:
how to make a print button invisible in the printed page when a print is given
0
by: esateesh | last post by:
HI i have a .aspx page with a print button and am calling java script function i.e onclick="window.print()" when a print is given am gettng print button in the pirnted page, but it should not be...
5
by: Andy B | last post by:
I have 2 TextBoxes and an Add button on a page. When the user fills in the TextBoxes, the values are added to a dataset table. When the page gets done reloading, the TextBoxes are turned into...
2
by: somacore | last post by:
I have a webform in C#. This form has both a gridview and a formview. The formview displays the details of the selected gridview index. No problem there. On the formview is a button. When this...
6
by: ghjk | last post by:
I have a menu which is contain image buttons. I want to hide some buttons in some pages. This is my code and it's not working. I couldn't find the error. Please help me. <script...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.