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.

gormo7

Members
  • Joined

  • Last visited

  1. Have to say i wasn't that particularly bothered before the adverts. But now Yuri is my God (No not Yuri from COD!!) Just goes to show how 60 seconds on an advert can propel you to international stardom!!
  2. Hiya mate, have to say i really like your site!
  3. Welcome Lady Shiraz. have fun!
  4. Thanks for all the advice guys, its much appreciated. I've actually got it all working now!! i know its only really simple but its a big achievement for me! Now going to look at making the validation more thorough but at least now its at the lowest acceptable level! this is the code i used for anyones future reference - hopefully this will help someone else out someday, its took me 7 bloody hours!!! <?php $con = mysql_connect("localhost","*****","*****"); if (!$con) { die('Could not connect: ' . mysql_error()); } $fullname=$_POST['fullname']; $email=$_POST['email']; //if no fullname entered and no email entered print an error if (empty($fullname) && empty($email)){ print "No email address and no name was entered.<br>Please include a name and email address."; } //if no name entered send print an error elseif (empty($fullname)){ print "No name was entered.<br>Please include a name."; } //if no email entered send print an error elseif (empty($email)){ print "No email address was entered.<br>Please include your email."; } //if the form has both an email and a message elseif (!empty($fullname) && !empty($email)) { mysql_select_db("*****", $con); if(mysql_query("INSERT INTO email_list (fullname, email) VALUES ('$fullname', '$email')")) echo "Your email has been added to our list!"; } mysql_close($con); ?>
  5.    gormo7 reacted to a post in a topic: Database advice needed!
  6. Thanks Kensha, I have variables in the INSERT table now. The rest of what you put went straight over my head haha!! But as 'isset ()' returns a boolean value wouldnt i have to have some other php code somewhere to say what to output depending on boolean value? I really need to learn this stuff quick!!! anyway here is what i have so far. <?php $con = mysql_connect("localhost","*****","*******"); if (!$con) { die('Could not connect: ' . mysql_error()); } $fullname=$_POST['fullname']; $email=$_POST['email']; mysql_select_db("********", $con); if(mysql_query("INSERT INTO email_list (fullname, email) VALUES ('$fullname', '$email')")) if (empty($fullname) && empty($email)){ print "No email address and no name was entered.<br>"; } elseif (empty($fullname)){ print "No name was entered.<br>Please include a name.<br>"; } elseif (empty($email)){ print "No email address was entered.<br>Please include your email."; } else { echo "Your email has been added to our list!"; } mysql_close($con); ?> I can understand why its submitting the form first and then displaying the relevant error message, but if i put the INSERT INTO bit at the end of the code it doesnt work at all!!
  7. Thanks Adam, Yeah i have created variables now im trying to write a code to validate the form before its submitted. Struggling a bit here though! The form is submitting regardless of whether a/all field is empty, but still displaying the correct error message! This PHP lark is going to be a steep learning curve!!
  8.    gormo7 reacted to a post in a topic: Database advice needed!
  9.    gormo7 reacted to a post in a topic: Database advice needed!
  10.    gormo7 reacted to a post in a topic: Database advice needed!
  11.    gormo7 reacted to a post in a topic: Database advice needed!
  12. what a tail i really am, in the HTML i had < form action='submit.php' action='POST'> POST is meant to be method='' Well i say im a tail, i hardly know any php/mysql and i got this off of a blog! very amateurish!! Thanks for all your help though mate!!
  13. Yeah using 'id' didn't make a difference
  14. I did try id's but i'll try again anyway and try both static/dynamic too
  15. Arrrghhhhh I'm starting to hate php/mysql already!!!!! i've spent all morning on this, and looks like i'll be spending all day on it!! Tried as much as i could think of but it just wont work with the dynamic parts!
  16. Ok using Static Values Worked, i'll try mess around with it a little more but its doing my bloody head in today lol!
  17. Table is called email_list i have id, fullname and email columns
  18. Hi Guys, Ok i've made a simple Form for my website, code as follows; <form action='submit.php' action='POST'> <p><input type='text' name='fullname' />Full name </p> <p><input type='text' name='email' />Email</p> <input type='submit' value='Sign Up!' /> </form> I have created a table in my database on my host. here is my submit.php code; <?php $con = mysql_connect("localhost","*****","*******"); if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("********", $con); if(mysql_query("INSERT INTO email_list (fullname, email) VALUES ('".$_POST['fullname']."', '".$_POST['email']."')")) { echo "Your email has been added to our list!"; } else { echo "There was an error adding your email to our list. Please try again."; } mysql_close($con); ?> Ok so here is the problem, i uploaded everything to the host and filled out the form a few times to make sure it worked. and i got the message "your email has been added to our list" all 3 times. When i went to my table on phpmyadmin the table showed there were 3 records, but the 'name' and 'email' fields were blank......???! Any one have any idea why? You can probably guess im kinda new to php/mysql but trying my bloody best to learn!
  19. Hi guys, Currently my site has a vertical nav menu on the left of every page. I have coded a Horizontal Nav bar to be Just under the Header area of the page but i'm having trouble making it responsive. I have a margin of 5% set left and right to slightly center the whole content. And due to length of some titles in the nav bar have set width to 85px for the border of each menu item. How the hell do i make this responsive? When viewing the new horizontal menu bar on different size screen it puts the whole page all over the place!!
  20. Ok scrap this post, think i've done it now! Seems to be working fine anyway! Heres the code i used (i decided on redirecting all to the non www site) RewriteEngine On RewriteCond %{HTTP_HOST} ^www.buyforyourboyfriend.co.uk [nocase] RewriteRule ^(.*) http://buyforyourboyfriend.co.uk/$1 [last,redirect=301] If anyone knows if thats 100% right or not would still be greatful!

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.