Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

mattwellis

Members
  • Joined

  • Last visited

  1. I am creating a photography website and am almost there with coding a very simple image viewer with clickable thumbnails etc. I have used the following script to change the images; <script> function changeImage(filename) { document.mainimage.src = filename; } </script> the main image is like this; <img name="mainimage" src="../Images/wedding-photo-01-bride-getting-ready.JPG" title="bride getting ready"/> And the links/images are like this..... <a href="javascript:changeImage('../Images/wedding-photo-01-bride-getting-ready.JPG')"> <img class="thumbbox" id="mainimage" src="../Images/wedding-photo-01-bride-get-thumb.JPG" alt="wellis photography logo" title="bride getting ready"> </a> This works fine, but I would also like a caption underneath the main image that changes at the same time. Is there a way to do this simply? Perhaps using some variation of the following script? <script type="text/javascript"> document.write(document.getElementById('myimage').title); </script> Thanks in advance
  2. I am trying to create my own very simple image viewer using html/css. I can get everything to work other than 1 aspect.......i am using % widths, not pixels, as I do a lot of panoramas, and would like people with larger windows to be able to see them bigger.....i can get the image to do exactly this, however when i use a standard 3:2 image in the viewer, it results in being way to big for the viewer. I have tried setting a maximum height, which works, but ends up distorting the image as the 100% width still applies. So does anyone know a way to have the width at 100% UNTIL the height reaches 500px, at which point width becomes fixed at the appropriate proportions of the image?! I hope this make sense! Thanks
  3. Thanks very much....no time to check now, but quickly put that code in and all seems to look like it will work once iv sorted images out etc!! Where did you find that script, because i viewed source on the page, found the div relating to the photo slider and couldnt see any of what you've just copied. Thanks again for the help!
  4. Thanks for suggestion...Doesn't seem to work though. I wonder if it not actually finding the images. Don't know why that would be either though! Do you know if I should be needing to edit any of the photoslider.js document that i downloaded or whether i should be able to make it function simply through the source code page? I realise the I'll be able to use the .css file to style afterwards, but for now I'd just like to be able to make something happen!! Any help much appreciated...
  5. Hi, First post here, as I have just attempted using jquery/javascript for the first time....following the tutorial on the link below... and have hit a brick wall! I understand as far as step 3, but can't work out where to put the FOTO.Slider.reload('default'); line. Should it also be inside the <script type> tag? If anyone knows how this works, your help would be much appreciated! Thanks very much! http://opiefoto.com/articles/photoslider#example And this is what I have so far... <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Untitled Document</title> <link rel="stylesheet" type="text/css" media="screen" href="file:///Macintosh HD/Users/matthewwilliams-ellis/Wellis Photography/photoslider.css" /> <script type="text/javascript" src="file:///Macintosh HD/Users/matthewwilliams-ellis/Wellis Photography/jquery.js"></script> <script type="text/javascript" src="file:///Macintosh HD/Users/matthewwilliams-ellis/Wellis Photography/photoslider.js"></script> </head> <body> <div class="photoslider" id="default"></div> <script type="text/javascript"> $(document).ready(function(){ //change the 'baseURL' to reflect the host and or path to your images FOTO.Slider.baseURL = '!This link to my site root!'; //set images by filling our bucket directly FOTO.Slider.bucket = { 'default': { 0: {'thumb': 'bannerimagethumb.jpg', 'main': 'bannerimage.jpg', 'caption': 'Opnumero uno innit'}, 1: {'thumb': 'bannerimageoperathumb.jpg', 'main': 'bannerimageopera.jpg'}, 2: {'thumb': 'bannerimage03colourthumb.jpg', 'main': 'bannerimage03colour.jpg'}, } }; }); </script> </body> </html>

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.