Jump to content

HTML/CSS Formatting Issue w/ Chrome

I am working on a project in my high school Web Design course in which we are required to use Adobe Dreamweaver to construct a website using HTML and CSS, which we then published to the Internet. My issue is with an ordered list which i have centered on the webpage. In Adobe Dreamweaver, every section of the list appears perfectly centered and aligned,  but when viewed in Google Chrome, the column of numbers align to the left of the page, with the list content(the text within the <li> tags) remaining centered. I assume that this is due to Chrome, and requires a change in the way I have centered the ordered list. If anyone could help me with this, I would greatly appreciate it. 

 

Here is the selector for the <ol> in CSS: 

 

ol {
    text-align: center;
}

 

The ordered list is nested directly inside the body in the HTML. Attached is a screenshot of my webpage when opened in Chrome.

 

I am aware of the off position of the table, and it is on my to-do list to fix.

  

post-193657-0-38474000-1445356891.png

Link to comment
Share on other sites

Link to post
Share on other sites

So you want the number to be aligned properly with the corresponding list entry? Or do you want the number gone?

"We're all in this together, might as well be friends" Tom, Toonami.

 

mini eLiXiVy: my open source 65% mechanical PCB, a build log, PCB anatomy and discussing open source licenses: https://linustechtips.com/topic/1366493-elixivy-a-65-mechanical-keyboard-build-log-pcb-anatomy-and-how-i-open-sourced-this-project/

 

mini_cardboard: a 4% keyboard build log and how keyboards workhttps://linustechtips.com/topic/1328547-mini_cardboard-a-4-keyboard-build-log-and-how-keyboards-work/

Link to comment
Share on other sites

Link to post
Share on other sites

So you want the number to be aligned properly with the corresponding list entry? Or do you want the number gone?

Sorry, I should have clarified. Yes, I want the numbers to be aligned properly with the list entries.

Link to comment
Share on other sites

Link to post
Share on other sites

Mhh if I understand your problem right, add following code:

list-style-position:inside;

This should fix your problem! If not, can you give the html code?

Business Management Student @ University St. Gallen (Switzerland)

HomeServer: i7 4930k - GTX 1070ti - ASUS Rampage IV Gene - 32Gb Ram

Laptop: MacBook Pro Retina 15" 2018

Operating Systems (Virtualised using VMware): Windows Pro 10, Cent OS 7

Occupation: Software Engineer

Link to comment
Share on other sites

Link to post
Share on other sites

Sorry, I should have clarified. Yes, I want the numbers to be aligned properly with the list entries.

Mhh if I understand your problem right, add following code:

list-style-position:inside;

This should fix your problem! If not, can you give the html code?

Have you tried this? (Also, I recommend following your topic to be notified of new replies)

"We're all in this together, might as well be friends" Tom, Toonami.

 

mini eLiXiVy: my open source 65% mechanical PCB, a build log, PCB anatomy and discussing open source licenses: https://linustechtips.com/topic/1366493-elixivy-a-65-mechanical-keyboard-build-log-pcb-anatomy-and-how-i-open-sourced-this-project/

 

mini_cardboard: a 4% keyboard build log and how keyboards workhttps://linustechtips.com/topic/1328547-mini_cardboard-a-4-keyboard-build-log-and-how-keyboards-work/

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×