473,513 Members | 2,323 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Simple CSS not even working for me

47 New Member
Hi everyone,

I'm new to CSS of course, and have been trying to learn it. However, when I try to pull off something as simple as positioning of text . . . nothing works in my index page. So in frustration I made a test page. Just a but of words to test only the code I'm looking for.

Still nothing!

I apologize if this question is a nuisance, but could anyone perhaps at least let me know what I'm doing wrong with this very simple thing? I figure if I can just get a simple thing going, I can move onward with fewer trouble, but I can't even get this part!

The page giving me trouble is this:
Test Page (workmenforChrist.org/test.html)

The CSS file, simple enough, has only this in it:
Expand|Select|Wrap|Line Numbers
  1. /*The different styles for the website*/
  2.  
  3. /*Sidebar positioning/*
  4.  
  5. .sidebar {
  6. position:       absolute;
  7. width:          150px;
  8. top:            0px;
  9. left:           0px;
  10.  
  11. }
  12.  
  13. a.sidebar {color: #2f4f4f}
  14.  
I'm sure it's something simple I'm just not getting . . . but I cannot figure it out for the life of me! I even copied the sidebar positioning code from somewhere else in case I was doing something wrong (just changed the width number, and added "px" to the end of it because I noticed it was missing . . .)!

I really appreciate the help on this, and apologize if it's a nuisance, thanks in advance for the help!

~Michael
Sep 20 '07 #1
2 1416
Bruno43
16 New Member
Hi everyone,

I'm new to CSS of course, and have been trying to learn it. However, when I try to pull off something as simple as positioning of text . . . nothing works in my index page. So in frustration I made a test page. Just a but of words to test only the code I'm looking for.

Still nothing!

I apologize if this question is a nuisance, but could anyone perhaps at least let me know what I'm doing wrong with this very simple thing? I figure if I can just get a simple thing going, I can move onward with fewer trouble, but I can't even get this part!

The page giving me trouble is this:
Test Page (workmenforChrist.org/test.html)

The CSS file, simple enough, has only this in it:
Expand|Select|Wrap|Line Numbers
  1. /*The different styles for the website*/
  2.  
  3. /*Sidebar positioning/*
  4.  
  5. .sidebar {
  6. position:       absolute;
  7. width:          150px;
  8. top:            0px;
  9. left:           0px;
  10.  
  11. }
  12.  
  13. a.sidebar {color: #2f4f4f}
  14.  
I'm sure it's something simple I'm just not getting . . . but I cannot figure it out for the life of me! I even copied the sidebar positioning code from somewhere else in case I was doing something wrong (just changed the width number, and added "px" to the end of it because I noticed it was missing . . .)!

I really appreciate the help on this, and apologize if it's a nuisance, thanks in advance for the help!

~Michael
Close your Css comment style tag correctly
/* */
That will get your css working :)

Also it is good practice to close your statments properly
a.sidebar {color: #2f4f4f}
should be
a.sidebar {color: #2f4f4f;}

Add the Semicolon ;)
Sep 20 '07 #2
Michael7
47 New Member
Ah, I KNEW it had to be something as simple as the comment close! Sheesh!

Thanks so much for that!

And thanks for the advice about the semicolon. I always wondered about it, but everywhere I saw, they only put the semicolons on multiple declarations.

Thanks again for the help!
Sep 20 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

17
6491
by: savesdeday | last post by:
In my beginnning computer science class we were asked to translate a simple interest problem. We are expected to write an algorithm that gets values for the starting account balance B, annual...
5
2623
by: calaha | last post by:
Hi all, I have been working with this since last night, and can't quite figure out why it's not working. I have a simple login box form that is set to be my startup form in my Access app (upon...
2
8374
by: Hazzard | last post by:
I just realized that the code I inherited is using all asp.net server controls (ie. webform controls) and when I try to update textboxes on the client side, I lose the new value of the textbox when...
5
1793
by: Logickle | last post by:
Hi, all. I'm working on an application which requires communicating session info between separate web apps running on the same web server. The out of process server method sounded ideal, and...
18
3015
by: Q. John Chen | last post by:
I have Vidation Controls First One: Simple exluce certain special characters: say no a or b or c in the string: * Second One: I required date be entered in "MM/DD/YYYY" format: //+4 How...
2
1741
by: dondraper | last post by:
I have an application that uses a popular but simple set of JavaScript routines that implement an AJAX call used to populate a drop-down. It works for thousands of user but I have one customer...
5
1272
by: Newbie | last post by:
Hi all, Just want to comment on this thread. Seems like every discussion about this matter (setting up DB provider for membership) and all the samples/references given by some MVPs always...
6
9355
by: sathyashrayan | last post by:
Dear group, Following is a exercise from a book called "Oreilly's practical C programming". I just wanted to do a couple of C programming exercise. I do have K and R book, but let me try some...
10
110153
true911m
by: true911m | last post by:
This is a simple walkthrough to get PyInstaller up and running. I decided to give PI a try, because it claims to be more selective about what it bundles into its executable files by default, and...
0
7267
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7553
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7542
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5697
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5100
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4754
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
1609
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
809
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
466
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.