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.

bk7

Members
  • Joined

  • Last visited

  1. Perfect - worked a treat. I'd like to keep this thread open as the page is far from complete and I'm sure I'll have another question soon enough.
  2. Hi, I'm using javascript to replace the value of a string with the options selected from a series of drop down boxes. The code works perfectly here: http://jsfiddle.net/QLXGq/1/ But when I try to insert it into a html file the button stops working, and I can't figure it out! This is the code I have on my webpage: <html> <head> <style type="text/css" media="screen"> #results { color: black; } </style> <script type="text/javascript"> $('button').click(function() { var searchTerms = "?page=index&opr=sales-current&pageno=1".substr(1).split('&'); var parameters = {}; for (var i = 0; i < searchTerms.length; i++) { var parts = searchTerms[i].split('=', 2); parameters[parts[0]] = parts[1]; } parameters['page'] = '' + document.getElementById('page').value; searchTerms = []; for (var key in parameters) { if (parameters.hasOwnProperty(key)) { searchTerms.push(key + '=' + parameters[key]); } } parameters['opr'] = 'sales-' + document.getElementById('opr').value; searchTerms = []; for (var key in parameters) { if (parameters.hasOwnProperty(key)) { searchTerms.push(key + '=' + parameters[key]); } } parameters['pageno'] = 'sales-' + document.getElementById('pageno').value; searchTerms = []; for (var key in parameters) { if (parameters.hasOwnProperty(key)) { searchTerms.push(key + '=' + parameters[key]); } } var result = searchTerms.join('&'); $('#results').text(result); }); </script> </head> <body> <select id="page"> <option>a</option> <option>b</option> <option>c</option> </select> <select id="opr"> <option>a</option> <option>b</option> <option>c</option> </select> <select id="pageno"> <option>a</option> <option>b</option> <option>c</option> </select> <button>Click me!</button> <div> result goes here:</div> <div id="results"></div> </body> </html> Can anyone please help! Bk7
  3. thank you very much Jock, worked like a charm. $_SERVER['REMOTE_ADDR']; is one to be remembered!
  4. Valid point and I know that by no means its a method of fully tracking spam etc, but at least with an IP address I can find the rough location the message was sent from, which is useful enough for me. I had heard of a form which could do this and I know it is possible, I just don't know enough about php to integrate it myself.
  5. Dear Web Designer Forum, I was hoping that someone might be able to tell me how I can integrate some form of IP address note into my contact form. My contact form as it stands has validation for fields required, and only basic validation of email addresses for "#@#.#" so name"@"domain. When someone sends a message, I receive an email with the name, subject, and message. I would like that same email that I receive to give me the IP address of the browser which sent the message. The php code used is within the contact page itself, and I have copied it here: <?php //If the form is submitted if(isset($_POST['submit'])) { //Check to make sure that the name field is not empty if(trim($_POST['contactname']) == '') { $hasError = true; } else { $name = trim($_POST['contactname']); } //Check to make sure that the subject field is not empty if(trim($_POST['subject']) == '') { $hasError = true; } else { $subject = trim($_POST['subject']); } //Check to make sure sure that a valid email address is submitted if(trim($_POST['email']) == '') { $hasError = true; } else if (!eregi("^[A-Z0-9._%-]+@[A-Z0-9._%-]+\.[A-Z]{2,4}$", trim($_POST['email']))) { $hasError = true; } else { $email = trim($_POST['email']); } //Check to make sure comments were entered if(trim($_POST['message']) == '') { $hasError = true; } else { if(function_exists('stripslashes')) { $comments = stripslashes(trim($_POST['message'])); } else { $comments = trim($_POST['message']); } } //If there is no error, send the email if(!isset($hasError)) { $emailTo = 'support@emailaddress.co.uk'; //Put your own email address here $body = "Name: $name \n\nEmail: $email \n\nSubject: $subject \n\nComments:\n $comments"; $headers = 'From: My Site ' . "\r\n" . 'Reply-To: ' . $email; mail($emailTo, $subject, $body, $headers); $emailSent = true; } } ?> I have tried to read around and have read often that the ip address is best gathered at the last second, in the sent email only, rather than in the form itself (because this can be manipulate?) Thanks
  6. Please can anyone help?
  7. cheers, can anyone recommend anything else, any other solutions? i looked through that article but nothing is really geared towards what i'm trying to do - the "calendar" part of this is somewhat of a misnomer. i'm not especially interested in the date/time keeping aspect of it - rather just a chronological list in an easy to understand view where the events are descriptions and a link to wherever the site has been mentioned in the news/other blogs. bk7
  8. Hello all When I first started this website I created a media links page using a tumblr blog roll to present media coverage in a chronological list, as on this page: http://www.nottinghamhouse.co.uk/inthemedia.html It was never a great solution (visually or to manage) and it has got to the point where I need something a lot better. Can you recommend any services which allow such a thing, which I might be able to embed into the page? I've also been looking at calendar style displays such as: http://demo.tutorialzine.com/2010/01/advanced-event-timeline-with-php-css-jquery/demo.php http://www.vam.ac.uk/whatson/events/month/201006/ But ideally I need something really simple to read and even easier for me to update! Cheers, Bk7
  9. Does anyone familiar with lightbox know what this might be happening? Cheers, Bk7
  10. ive got a good system going with that script: http://tutorialzine.com/2009/09/cool-jquery-gallery/ which works perfectly just by uploading images to a folder on the server. However I am having trouble getting the light box to work as it should.. its putting the images at the bottom of the page rather than floating them in the centre as a lightbox should. Any thoughts?
  11. Thanks but I don't need artwork, I need those images to present properly.
  12. Apologies for double posting but I really wanted to highlight this post: In the last few hours i have been working with this script: http://tutorialzine.com/2009/09/cool-jquery-gallery/ I like a lot of its aspects, and have even managed to work with the php side of it. the results as yet are here: http://nottinghamhouse2.bhavikmorar.co.uk/sat_bains.php However, I have an issue with the subsequent lightbox: when you click on the images with grey borders, the lightbox does not work as it should. Instead it is revealing the image some distance below the page when clicked. Maybe its the lateness but I can't seem to figure out what is missing. Please help! Bk7 --- I think i've managed to narrow down the conflict to the lightbox css... i say that because when you scroll right down, and hit the close button below the image, it does disappear again, which suggests everything but the css is working.
  13. ---Deleted original post--- Apologies for double posting but I really wanted to highlight this post: In the last few hours i have been working with this script: http://tutorialzine.com/2009/09/cool-jquery-gallery/ I like a lot of its aspects, and have even managed to work with the php side of it. the results as yet are here: http://nottinghamhouse2.bhavikmorar.co.uk/sat_bains.php However, I have an issue with the subsequent lightbox: when you click on the images with grey borders, the lightbox does not work as it should. Instead it is revealing the image some distance below the page when clicked. Maybe its the lateness but I can't seem to figure out what is missing. Please help! Bk7 --- I think i've managed to narrow down the conflict to the lightbox css... i say that because when you scroll right down, and hit the close button below the image, it does disappear again, which suggests everything but the css is working.
  14. Thanks very much mteam - i intend to look into that as soon as I fix a new problem I have stumbled across: Please ignore the below - i had the z-index affecting the wrong id, all fixed now! ----ignore---- I have just tried to implement this dropdown menu (by http://thinkhtml.blogspot.com/2009/09/timos-float-drop-css-only-dropdown-menu.html) http://nottinghamhouse2.bhavikmorar.co.uk/ However there appears to be a clash between the jquery auto flow image slider and the drop down menu, where the drop down menu is hidden behind the scroller. The only thing i know how to do is fiddle witht he z-index of each element but that appears to have no effect. Hoping someone can help, ----ignore----
  15. Just hoping to prompt this topic for a few more replies? Does anyone know a way of delaying that effect by adding something to the existing css drop down menu above? Cheers!

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.