Welcome guest. Before posting on our computer help forum, you must register. Click here it's easy and free.

Author Topic: css help  (Read 6757 times)

0 Members and 1 Guest are viewing this topic.

nymph4

    Topic Starter


    Specialist

    Re: css help
    « Reply #15 on: September 09, 2010, 04:08:19 PM »
    This is what I was doing.

    <HTML>
    <HEAD>
    <style type="text/css">
    h1
    {
    text-decoration:underline;color:white;font-family:Times New Roman,Serif;
    }
    </style>
    </HEAD>
    <body bgcolor="#ffffff" background="wall.jpg">

    <h1>My headline text I type</h1>
    </BODY>

    This sould work right? This is my whole code I was useing I just found it??

    Big



      Beginner

      Thanked: 4
      • Experience: Experienced
      • OS: Windows XP
      Re: css help
      « Reply #16 on: September 09, 2010, 04:44:49 PM »

      Yes that should work.
      Alright just for the record, you forgot the end HTML tag, which is </HTML>.
      Put it at the end please. I know browsers still understand your code without it, but it's better to put it.

      I changed your code a bit:

      color:red;

      Then it looks like this , because I don't have your background image called wall.jpg. This image should be in the same folder as your html file.

      Please change text color to red, or your background color to #000000 (black), or you won't be able to see your text. I think that is your problem. =)

      Big
      Computerhope is corrupt.

      reddevilggg



        Expert

        Thanked: 69
      • Experience: Beginner
      • OS: Windows 7
      Re: css help
      « Reply #17 on: September 09, 2010, 04:49:27 PM »
      Please change text color to red, or your background color to #000000 (black), or you won't be able to see your text. I think that is your problem. =)

      Big


      I think that is the problem, i've just checked it in 2 browsers (IE and FF) and nothing showed up.

      @ Nymph4, But would it not be easier to just check it, other than posting asking for someone else to check it and wait for a reply. ??
      « Last Edit: September 09, 2010, 05:00:15 PM by reddevilggg »
      11 cheers for binary !

      nymph4

        Topic Starter


        Specialist

        Re: css help
        « Reply #18 on: September 09, 2010, 10:27:34 PM »
        OK I did not forget the  </HTML>  in my web page I forgot to post it up here.

        And my photo is of a Stone Wall and my text for my Headline is white.

        And this code is what shows up on my page as text and not as HTML and not hidden.
        I realy think maybe I am missing a  ;  or :  or something

        Big



          Beginner

          Thanked: 4
          • Experience: Experienced
          • OS: Windows XP
          Re: css help
          « Reply #19 on: September 10, 2010, 04:21:52 AM »

          Alright, a few questions..

          1) Printscreen please

          2) What browser are you using precisely (version)

          3) Did you save your file as mypage.html or mypage.html.txt (to see the file's full name, go to 'My Computer' -> 'Tools' -> 'Folder Options' -> 'View' -> uncheck 'Hide extensions for known file types', click 'Ok', then go to the directory where your .html file is and see if it's .html or .html.txt)

          4) CSS syntax is like this:

          ElementName
          {
              attributeName: value;
          }

          Not really hard to understand. A semicolon is used in most languages as a seperator, a sort of 'Enter'.
          That's all. Try to use this style, it's more readable.

          5) Is it a white stone wall?

          6) Is your stone wall actually displayed on the page?

          5 & 6 need a printscreen. lol


          Quote
          And this code is what shows up on my page as text and not as HTML and not hidden.
          Your whole code or just that CSS line?

          Please answer all the questions so we can further help you better.


          Big
          Computerhope is corrupt.

          kpac

          • Web moderator
          • Moderator


          • Hacker

          • kpac®
          • Thanked: 184
            • Yes
            • Yes
            • Yes
          • Certifications: List
          • Computer: Specs
          • Experience: Expert
          • OS: Windows 7
          Re: css help
          « Reply #20 on: September 10, 2010, 11:50:49 AM »
          Also, now that you're using CSS to style your pages you should try and use XHTML wherever possible, i.e. small HTML tags (<html> and not <HTML>), don't use <body bgcolor=""> etc.. This will further help with cross-browser compatibility.