Jump to content

Wickham

Advanced Member
  • Posts

    1,114
  • Joined

  • Last visited

  • Days Won

    5

Everything posted by Wickham

  1. I can't see anything wrong with the php code and you are getting the email with the other fields, so it's probably not getting the field from the form. Remember that with radio buttons the name has to be the same for all radio buttons, only the value is different, like:- > </pre> <li>Male Female Child</li>
  2. I suppose it depends on what sort of site you are designing. I don't design many websites and those that I do build are very individual, like a village community website, so if someone searches Google for the village name it's almost bound to be near the top of the list. There's only one other website dedicated specifically to the village, for the village hall bookings, so my website and that one are normally 1 and 2. There are other websites that include the village, like a local authority website or a site for holiday accommodation, but they usually rate lower in Google. I'm sure it helps to have the site's subject in the domain name. If you are building a site for retailing shoes, it must be much more difficult to get near the top of the ratings because there are so many other shoe retailers. So get a domain name that reflects exactly what you sell or where you are, like chicagopizzadelivery.com
  3. IE7 was showing correctly but Firefox was overlapping #content over or behind #menu. Adding margin-left: 200px; fixed Firefox in my test:- div#content { margin-left: 200px; width:590px; }
  4. I don't use ems except in very special cases, I find it inconvenient to code. I use px for everything. Now that modern browsers have a zoom, a person with bad eyesight can use it and still see everything on the page in the same relationship. Before zooms, people could only increase text size which made the relationship of text to images and container sizes all wrong, so some coders used ems to get over that problem. I recommend that you either use px for everything or ems for everything, don't mix them.
  5. I agree that px for all sizes is probably easier to code if you are a beginner. IE won't let a viewer change only the text size if the font is px, but Firefox and other browsers allow you to increase text size without increasing images or the text containers (so text may overflow or get cut off but the containers and page size remains the same). IE7 and IE8 have a zoom, like Firefox and most other browsers, which increases everything on the page, so you have to scroll a lot more but nothing should overflow the container if it fitted originally. ems is related to the default font size, so it's a good idea to size everything in ems like divs, tables, images, margins, padding, etc. as well as text. Then if the default font size is changed, everything changes in proportion. Remember that if you have a default font size of 1em and then a style (say for a p tag) of 0.8em and then a class used within a p tag also with 0.8em, the text will have the 0.8 applied to the parent's 0.8 so the text size will be 0.64 of the default size. It's very easy to forget that when using classes within parents that both have a different em size from the default.
  6. Not me; although I'm retired I'm busy enough all day.
  7. OK, I have used some of your video tutorials, Stefan, and they got me started, thanks, but I've still got a long way to go. It takes time and practice. Generally with javascript you can download a script and just use it unedited, but PHP code that you take from somewhere nearly always needs editing.
  8. PHP would be the best solution, but difficult to learn. You could use "chained select boxes" which use Javascript and all the coding is given to you here:- http://www.dynamicdrive.com/dynamicindex16/chainedselects/index.htm The item you select in the first box changes the options in the next, and so on. It can't "search" for anything as you have to code a fixed set of options.
  9. 1. Making the page center. Code a wrap div like Eric said, but also with position: relative:- #wrap { width: 900px; margin: 0 auto; position: relative; } Then structure your page body section:- .........all page content......... Any position: absolute elements inside the #wrap div will probably need the left size edited because position: absolute divs take their position from the top left corner of the position: relative wrap div instead of the top left corner of the window or screen, so when the wrap div moves to center in large resolutions because of margin: auto, the position: absolute divs move with it but retain their positions inside. 2. A page which always fits the window width requires all widths to be in % totaling 100%. That includes all divs, tables, table cells, lists, forms and also side padding and side margin. It also needs all images to be sized in % like:- Borders can't be sized in % so if you have side borders in px, total the other items to 97% or 98% to allow for the borders in px. It's much harder to code a totally fluid page width as content will get squashed up or very spread out. It works best when there isn't much content on the page. You can use min-width and max-width as an alternative but that doesn't work in IE6.
  10. First, you've got a lot of double >> in the html file like > High-End Servers so dElete one. Your #contentframe is 800px wide so I made the side divs 159px (800*20% less 1px side border) and the #landing-main-content-1 div 480px wide and made all three float (firsty two float left and the third float: right) and they all fit neatly together. Then add clear: both to #footer. * { margin: 0; padding: 0; } body { margin: 0px; padding: 0px; font-family:Trebuchet MS, sans-serif; font-size: 10pt; text-align: center; background-color: #F0F2FF; } #outerframe { background: pink;/*#ffffff; */ width: 800px; margin-top: 0px; margin-right: auto; margin-left: auto; padding: 0px; text-align: left; border-left: solid 2px #3A6E8E; border-right: solid 2px #3A6E8E; } /*Path Links*/ #pathlinks{ width:100%; padding-top:20px; padding-left:20px; padding-bottom:10px; font-family:Trebuchet MS, sans-serif; float: left; font-size: 9pt; } #pathlinks a:link{ color: #344654; text-decoration:none; } #pathlinks a:visited{ color: #344654; text-decoration:none; } #pathlinks a:hover{ color: red; text-decoration:underline; } /*End of Path Links*? /*Forms*/ #form1 { width: 200px; } #search1 { width: 350px; background-image: url(/images/search-background.jpg); vertical-align: top; } #search1, #submit { vertical-align: top; } .error { color:red; } /*End of Forms*/ /*Header and Top menu*/ #header{ background: green; width: 100%; border:0px; padding:0px; } .logo { padding:0px; background-color:#ffffff; } .logo img{ border:0; } .logo a:link{ text-decoration: none; } .logo a:visited{ text-decoration: none; } .logo a:hover{ text-decoration: none; } #topmenu{ background: red; height: 32px; text-align:center; background-image:url(/images/header-menu-1.jpg); width: 100%; } #topmenu ul{ margin: 0px; padding: 0px; font-family: Trebuchet MS, sans-serif; font-size: 10pt; color: #344654; line-height: 30px; white-space: nowrap; } #topmenu li { list-style-type: none; display: inline; } #topmenu a { text-decoration: none; padding: 7px 10px; color: #344654; } #topmenu a:link { font-weight: bold; color: #344654; } #topmenu a:visited { font-weight: bold; color: #344654; } #topmenu a:hover { font-weight: bold; color: #344654; } /* End of Header and top menu bar*/ /*Side Menu*/ #enquiry{ width: 20%; border-right: 1px solid #000; padding: 0 0 1em 0; font-family: Trebuchet MS, sans-serif; font-size: 10pt; background-color: #686147; color: #333; } * html #enquiry{ /*IE 6 only */ width: 147px; /*Box model bug: 180px minus all left and right paddings for #blueblock */ } #enquiry ul{ list-style: none; margin: 0; padding: 0; border: none; } #enquiry li { border-bottom: 1px solid #686147; margin: 0; } #enquiry li a{ display: block; padding: 5px 5px 5px 8px; border-left: 10px solid #76662A; border-right: 10px solid #D2AB1A; background-color: #B6992C; color: #000000; text-decoration: none; width: 100%; } html>body #enquiry li a{ /*Non IE6 width*/ width: auto; } #enquiry li a:hover{ border-left: 10px solid #978955; border-right: 10px solid #D9BC4E; background-color: #D1B034; color: #000000; } #server-list{ float: left; width: 159px;/*20%; */ border-right: 1px solid #000; padding: 0 0 1em 0; font-family: Trebuchet MS, sans-serif; font-size: 10pt; background-color: #2B536B; color: #333; } * html #server-list{ /*IE 6 only */ width: 147px; /*Box model bug: 180px minus all left and right paddings for #blueblock */ } #server-list ul{ list-style: none; margin: 0; padding: 0; border: none; } #server-list li { border-bottom: 1px solid #1E303A; margin: 0; } #server-list li a{ display: block; padding: 5px 5px 5px 8px; border-left: 10px solid #25485D; border-right: 10px solid #497C9B; background-color: #3A6E8E; color: #000000; text-decoration: none; width: 100%; } html>body #server-list li a{ /*Non IE6 width*/ width: auto; } #server-list li a:hover{ border-left: 10px solid #406276; border-right: 10px solid #5097C3; background-color: #4D99C7; color: #000000; } #server-list2{ float: right; width: 159px;/*20%;*/ vertical-align:top; border-right: 1px solid #000; padding: 0 0 1em 0; font-family: Trebuchet MS, sans-serif; font-size: 10pt; margin: 0 0 0 auto; background-color: #2B536B; color: #333; } * html #server-list2{ /*IE 6 only */ width: 147px; /*Box model bug: 180px minus all left and right paddings for #blueblock */ } #server-list2 ul{ list-style: none; margin: 0; padding: 0; border: none; } #server-list2 li { border-bottom: 1px solid #1E303A; margin: 0; } #server-list2 li a{ display: block; padding: 5px 5px 5px 8px; border-left: 10px solid #25485D; border-right: 10px solid #497C9B; background-color: #3A6E8E; color: #000000; text-decoration: none; width: 100%; } html>body #server-list2 li a{ /*Non IE6 width*/ width: auto; } #server-list2 li a:hover{ border-left: 10px solid #406276; border-right: 10px solid #5097C3; background-color: #4D99C7; color: #000000; } /* End of Side Menu*/ /*Server List Side Menu*/ #server-sub-list{ width: 20%; border-right: 1px solid #000; padding: 0 0 1em 0; font-family: Trebuchet MS, sans-serif; font-size: 10pt; background-color: blue; /*#2B2B5E;*/ color: #333; } * html #server-sub-list{ /*IE 6 only */ width: 147px; /*Box model bug: 180px minus all left and right paddings for #blueblock */ } #server-sub-list ul{ list-style: none; margin: 0; padding: 0; border: none; } #server-sub-list li { border-bottom: 1px solid #1E303A; margin: 0; } #server-sub-list li a{ display: block; padding: 5px 5px 5px 8px; border-left: 10px solid #434361; border-right: 10px solid #7F7FAB; background-color: #6868B2; color: #000000; text-decoration: none; width: 100%; } html>body #server-sub-list li a{ /*Non IE6 width*/ width: auto; } #server-sub-list li a:hover{ border-left: 10px solid #5B5B76; border-right: 10px solid #A6A6D0; background-color: #7676C7; color: #000000; } /*End of Server List Side Menu*/ /*Main Body Content*/ #contentframe{ width: 800px; border:0px; disssssplay:inline; padding:0px; position:relative; background-color: lime;/* #ffffff;*/ } #main-content{ margin: 0; padding: 0; font-family: Trebuchet MS, sans-serif; background-color: skyblue;/*#ffffff;*/ font-size: 10pt; position:relative; color: #333333; width: 79.8%; float:right; padding-bottom:20px; } #main-content ul{ padding-left: 16px; padding-right: 16px; padding-top:10px; padding-bottom:10px; } #main-content li{ list-style-type: square; font-size: 9pt; color:#525252; padding-right:24px; padding-left: 8px; margin:0em 0em 0em 1em; } .server-image{ width: 30%; background-color:#ffffff; border:0; padding-left:15px; padding-top:20px; float:left; } .server-content{ width: 61.5%; float:right; padding-top:15px; padding-bottom: 15px; padding-right:15px; background-color: #ffffff; } .server-content p{ font-size: 10pt; padding-bottom: 15px; } .server-content ul{ padding-left:0px; margin-left:0px; list-style-image: url(/images/link-icon.png); } .server-content li { margin-left:0px; list-style-image: url(/images/link-icon.png); } .server-content-list{ width:95%; float:right; padding-left:15px; padding-right:15px; padding-top:15px; } .bl {background: url(/images/bottomleft.gif) 0 100% no-repeat #E4EEED; width: 100%;} .br {background: url(/images/bottomright.gif) 100% 100% no-repeat; width: 100%;} .tl {background: url(/images/topleft.gif) 0 0 no-repeat;} .tr {background: url(/images/topright.gif) 100% 0 no-repeat; padding:5px;} .clear {clear: both; width: 100%; height: 0; visibility: hidden; background: #fff; font-size: 0; line-height: 0;padding-bottom:10px;} .title { font-size: 16pt; font-weight: bold; color: #344654; margin-top: 20px; margin-bottom: 10px; } .title1 { font-size: 16pt; font-weight: bold; color: #344654; margin-top: 20px; margin-left: 20px; } .sub-title-bullet{ margin-top: 5px; font-family: Trebuchet MS, sans-serif; margin-left: 0px; margin-bottom: 0px; font-size: 13pt; } .sub-title-bullet p{ font-size: 13pt; font-weight: bold; color: #344654; margin-left: 15px; } .sub-title-bullet ul{ list-style-type:circle; } .sub-title-bullet li{ padding-left:10px; list-style-type:circle; line-height:16pt; } /* End of Main Body Content*/ /*Footer*/ #footer{ clear: both; width: 100%; border:0px; background-color:#3A6E8E; font-family: Trebuchet MS, sans-serif; font-size: 9pt; color: #EEEEEE; float: none; } .footer-links{ height:35px; text-align:center; } .footer-links p{ padding-top: 8px; } .footer-links a:link{ color: #ffffff; padding: 0 10px; font-weight: bold; text-decoration: none; font-size: 9pt; } .footer-links a:visited{ color: #ffffff; font-weight: bold; text-decoration: none; } .footer-links a:hover{ color: #cccccc; font-weight: bold; text-decoration: none; } /*End of Footer*/ /*Landing pages*/ #landing-main-content-1{ float: left; padding: 0; vertical-align:top; font-family: Trebuchet MS, sans-serif; background-color: yellow;/*#ffffff;*/ position:relative; width: 480px;/*40%;*/ margin: 0 auto; padding-bottom:20px; } #landing-main-content-1 p{ font-size: 10pt; color: #333333; padding-left:20px; padding-right:20px; padding-top:10px; } #landing-main-content-1 ul{ padding-left: 16px; padding-right: 16px; padding-top:10px; padding-bottom:10px; } #landing-main-content-1 li{ list-style-type: square; font-size: 9pt; color:#525252; padding-right:24px; padding-left: 8px; margin:0em 0em 0em 1em; } .seo-text { font-size: 10pt; font-weight: bold; color: #344654; margin-top: 15px; margin-bottom: 0px; padding-left:20px; } #sun-server{ padding:20px; } /*End of Landing pages*/ /*Site Map*/ #site-title{ width:100%; padding-left: 30px; color:#4b4b4b; float: left; line-height:14pt; padding-top:10px; } #site-title a:link{ padding:1px; color:#4b4b4b; text-decoration:none; font-weight: bold; } #site-title a:visited{ color:#026730; text-decoration:none; font-weight: bold; } #site-title a:hover{ text-decoration:underline; color:#8D041A; font-weight: bold; } #level1{ width:100%; padding-left: 30px; color:#4b4b4b; float: left; line-height:14pt; } #level1 a:link{ padding:1px; color:#026730; text-decoration:none; font-weight: bold; } #level1 a:visited{ color:#026730; text-decoration:none; font-weight: bold; } #level1 a:hover{ text-decoration:underline; color:#8D041A; font-weight: bold; } #level2{ width:100%; padding-left: 15px; color:#4b4b4b; float: left; line-height:14pt; } #level2 a:link{ padding:1px; color:#4b4b4b; text-decoration:none; } #level2 a:visited{ color:#4b4b4b; text-decoration:none; } #level2 a:hover{ text-decoration:underline; color:#4b4b4b; } #level2 ul{ width: 95%; float: left; padding-top:5px; } #level2 li{ padding-left:10px; font-size: 9pt; } #level3{ width:100%; padding-left: 40px; color:#4b4b4b; float: left; line-height:14pt; } #level3 a:link{ padding:1px; color:#4b4b4b; text-decoration:none; } #level3 a:visited{ color:#4b4b4b; text-decoration:none; } #level3 a:hover{ text-decoration:underline; color:#4b4b4b; } #level3 ul{ width: 95%; float: left; padding-top:5px; } #level3 li{ padding-left:10px; font-size: 9pt; } /*End of Site Map*/ Leave my background colors temporarily so you can see the size of each div. The html file only had the >> reduced to >
  11. That's odd. I've just tried my file again in IE7 with ActiveX enabled and in Firefox with Javascript and it only shows the 320px wide image. If I remove the s from https both images show.
  12. I downloaded your files and images and just did what the comment in the html file said; I changed http:// to https:// There was a delay loading but the smaller image was gone. I didn't really expect a https page to work with my page on my computer but it did. The second url was just http://
  13. A word of warning about reputation buttons. On another forum the plus and minus buttons were added but it was soon noticed that people were being vindictive and malicious with the minus button so it was removed, just leaving the plus button as a way to say "Thank You for a useful post". In the first few days people were giving a plus to their own posts and building up a reputation of 80 or 100 very quickly which gave a false impression, so adding reputation to your own posts was disabled.
  14. Yesterday I tried Wickham Wickham in the Name input box but the was just ignored. Today I tried Wickham \r\n Wickham in the Name input box and it went through without an error showing the same text all on one line. I didn't think it would work as the input box is text and \r\n is just text, there's no php to process there. So I'm still not sure whether the code will stop a spambot or how to test like one. php.net says:- int preg_match ( string $pattern , string $subject [, array &$matches [, int $flags [, int $offset ]]] ) so is the format correct in my code? (Leaving out the square brackets // Security code to prevent addition of new lines entered into the $name and $email fields by spambots elseif ( preg_match( "\r\n", $name ) || preg_match( "\r\n", $email ) ) { header( "Location: $errorurl" ); exit ; } raises a php formatting error). I don't understand the terminology in php.net. What if a spambot uses \n\r instead of \r\n or just \r or just \n on their own?
  15. I had this code in a web form, taken originally from Eric ewwatson on the old forum // Security code to prevent addition of new lines entered into the $name and $email fields by spambots elseif ( eregi( "[\r\n]", $name ) || eregi( "[\r\n]", $email ) ) { header( "Location: $errorurl" ); exit ; } which I understand is deprecated and will be removed from PHP 6.0 so I changed it to // Security code to prevent addition of new lines entered into the $name and $email fields by spambots elseif ( preg_match( "[\r\n]", $name ) || preg_match( "[\r\n]", $email ) ) { header( "Location: $errorurl" ); exit ; } I assume that preg_match can be a straight substitution. The form does work and doesn't raise any PHP errors, but my main question is how do I test like a spambot? What do I enter into a form input box to get the error and rejection?
  16. There are several ways to highlight the menu tab for the current page. Item 1 here is the simplest, but needs a different code for every page, so if you want to change a link url or add a link, you have to edit every page:- http://www.wickham43.net/highlighthome.php The second example enables you to have the same menu code for every page, which you put in a PHP "include" file, so you don't have to edit every page when you change a link url or add an extra main page, you just change the menu in one file. However, you will have to edit them in the beginning to add a different id for every page, then the common menu has "matched pairs" code so that when the page id matches an id in the menu, the menu style changes. The matched pairs styles for the stylesheet are shown:- #home li#homelink a, #about li#aboutlink a, #services li#serviceslink a { background-color: #ff0000; } The third example similar, but with colored buttons and the fourth example is all PHP.
  17. Perhaps Kaymeis didn't understand that float is a technical CSS coding term. If he means images that move across the screen then this could be done with javascript, jQuery or Flash. Hotscripts http://www.hotscripts.com/category/javascript/scripts-programs/ might have a suitable script. This page http://www.hotscripts.com/category/javascript/scripts-programs/image-effects/animations/ lists two "Bouncing Images" scripts that might be what is wanted. I don't know whether they can be controlled in a straight line or whether they bounce up and down as well.
  18. Do you mean floating several images on the same line? CSS img.left { float: left; } HTML
  19. First I started looking in the code but didn't see a code, I thought it might be a bullet which is • from here http://www.tedmontgomery.com/tutorial/HTMLchrc.html Then because there were so many css files I decided to use Firefox Tools Page Info Media which lists all the images used on a page, and it was there. Very simple. The code for the first link Style is Style so the gif is probably a background image for the span tag, but I haven't got the time to find it. Here it is #nav .panel li a { font-size: 0.688em; border-top: 1px transparent; color: #fff; background: transparent url(images/nav_pipe.gif) no-repeat scroll 100% 49%; }
  20. The red dots? See this http://www.kineda.com/wp-content/themes/vega/images/nav_pipe.gif very small dot.
  21. Wickham

    Captcha

    You will need to edit your php process code, can you post it here, and the page code with the form? LSW's method and mine are similar: I have text next to the input box "Enter H8yMF6 in the box" He has "What is 2+3; enter the answer in the box" Both methods cannot be answered by a computer, only by a human. Then your php process code has to check that the value of the field is equal to the answer, or an error is shown.
  22. I've changed a lot more than Virtual has. I changed the order of divs in the html file so that the float: right div #main-content is first and the other divs without a float follow, so you don't need a negative margin-top to raise the floated div. I also reset all margins and padding to 0 http://www.wickham43.com/forumposts/divzindependentsunsupport100119.html http://www.wickham43.com/forumposts/divzstyles100119.css
  23. Over 67 like me?? New forum's looking good.
  24. Assuming that your two menus have a containing ul or div, give each a different id, then style them separately:- #menu1 a:link { color: red; } #menu1 a:visited { color: blue; } #menu1 a:hover { color: lime; } #menu1 a:active { color: purple; } #menu2 a:link { color: green; } #menu2 a:visited { color: skyyblue; } #menu2 a:hover { color: teal; } #menu2 a:active { color: violet; }
  25. Wickham

    Captcha

    My codes would probably need adapting to your PHP coding. We would need to see the form and the PHP process file, if that's a separate file.
×
×
  • Create New...