Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Sep 2012
    Posts
    16
    Thanks
    4
    Thanked 0 Times in 0 Posts

    Question Image change on the click of a button?

    Hello everyone,

    I'm currently creating a page to advertise different bundles for a product and I was wondering if it'd be possible to have three buttons which all display a different image.

    For example, in the middle of the page would be a banner, on the click of button 2 this would then change to a different header. I'm not too sure if this is possible through PHP but any help would be fantastic !
    Last edited by spudmonkee; 11-17-2012 at 07:46 PM.

  • #2
    Senior Coder DanInMa's Avatar
    Join Date
    Nov 2010
    Location
    Salem,Ma
    Posts
    1,577
    Thanks
    13
    Thanked 248 Times in 248 Posts
    not really specific enough and you haven't shown any examples, but you will most likely want to do this client side with JavaScript as if you did it with just PHP you'd have to refresh the page on every click.

  • #3
    New Coder
    Join Date
    Sep 2012
    Posts
    16
    Thanks
    4
    Thanked 0 Times in 0 Posts
    I managed to find a suitable method via JQuery, would've seemed more appropriate to use JavaScript/JQuery. Thanks!


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •