473,404 Members | 2,174 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,404 software developers and data experts.

How to change the background picture of a web page by clicking on button.

I am working in Java Script. How to chang the background image(picture) of a web page by clicking on a button?

Please reply soon.

Regards.
Feb 29 '08 #1
1 1539
hsriat
1,654 Expert 1GB
I am working in Java Script. How to chang the background image(picture) of a web page by clicking on a button?

Please reply soon.

Regards.
[html]<button onclick = "document.body.style.backgroundImage = 'url(new_bg_image.jpg)';">Change Background Image</button>[/html]
Feb 29 '08 #2

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

Similar topics

7
by: John Baker | last post by:
Hi: I imagine there are hundreds of responses to this question, but i cant find any on the site using a search. How do you change the background color of buttons? I know there must be an easy...
2
by: Scott | last post by:
Is it possible to have a button change colour OnClick ? Thanks.
0
by: Lyn | last post by:
This one is driving me crazy. I have a table which stores pictures in an OLE Object column, one per record with a few other text fields (caption, date, etc). This table is maintained with a...
0
by: Jeff Griffin via DotNetMonster.com | last post by:
im trying to make it to where when i submit the page by clicking a button, if a certain check box is checked it will add a watermark to the excel document that is opened upon submission (just...
1
by: AA Arens | last post by:
How to change the color of the buttons or the button from the switchboard? I use Access2003 but the database is from <2003, so the buttons are gray and squaired. Bart
7
by: Bon | last post by:
Dear all I create a master page with image buttons on the left-hand side for navigation. When a user clicks the student button, the content (i.e. ContentPlaceholder) in masterpage will be...
3
by: vj | last post by:
how to change images based on action. Even clicking changed images should do respective actions. and while displaying only one image at a time sholud get displayed. I am using three images for a...
1
by: cccc2046 | last post by:
hi, i am a rookies in ASP.Net(C#). and i am using visual studio 2005 i am creating a webpages.and using CSS, Master page, and Content page in my CSS ( myStyle.css) i set my background picture...
5
by: deadlyhunta | last post by:
Hello all, I have used javascript a little bit (along time ago) so my knowledge is pretty limited (very limited). I am trying to figure out a way that I can change a css background when a certain...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new...

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.