# Help with simple javascript using flickrshow

**URL:** https://forum.kirupa.com/t/help-with-simple-javascript-using-flickrshow/326855
**Category:** Uncategorized
**Created:** [January 17, 2012, 1:29am UTC](https://forum.kirupa.com/t/help-with-simple-javascript-using-flickrshow/326855 "2012-01-17T01:29:55Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Numinus](https://avatars.discourse-cdn.com/v4/letter/n/9fc29f/32.png) [@Numinus](https://forum.kirupa.com/u/Numinus)
#### Post date: [January 17, 2012, 1:29am UTC](https://forum.kirupa.com/t/help-with-simple-javascript-using-flickrshow/326855/1 "2012-01-17T01:29:55Z")

</div>

```auto
<script src="flickrshow-7.2.min.js">
</script>

<script>
  var cesc = new flickrshow('picturesIframeDiv', {
  autoplay:false,
  interval:7000,
  license:null,
  user:'72247751@N07'
  });
</script>

```

I need the above code to execute only after i press a button. When i place it directly in a div, it loads up a slideshow from flickr when you open the page. But i need the slideshow to be hidden until a button is pressed. I’ve tried making the div which holds the script visible:hidden; however, the slideshow still pops up. I tried making the div display:none. But the script won’t execute (that is the slideshow never shows up) after i change it back to display:block. So my next step is to find a way for the script to execute one i press a button. How do i code this?
