CSS center is working on two pages but not the other - css

The CSS centering works on this page: http://www.paragondictionary.info/A.html
But not on this page: http://www.paragondictionary.info/C.html
Both HTML pages are using the same CSS link so I don't know why the centering is not working on one page. Any help is appreciated.

The reason it's not working on the second one is because you forgot to add the
<div class="center">
</div>
that surrounds the definition list in the body
If you look at the first page in view source, you can see on line 20 there's a class called
.center
That is used to presumably, center the content.

you have forgotten to use {div class="center"} in the second page.

Related

How to Disable CSS of one of two col-md-12 divs

I have made 2 Divisions out of bootstrap property <div class="col-md-12" > on the same page. In the first one, I have added a different Background and some hover property, now in the second one I have to make a "Sign Up" Div but with other properties with the same <div class="col-md-12" > ie. Full page width row. But the changes are happening on both the Divisions.
Can somebody Help ?
I am using Visual Studio 13 for aspx webpage.
Sorry if it is a silly question.
Thanks In Advance.
You can append another class to the ones you want to style:
<div class="col-md-12 styleme">
Content
</div>
CSS:
.styleme {
background-color: #000;
}
This way, you can style the div using your own custom class as opposed to overriding BootStrap's native one.
NOTE: ensure to place the custom style in your own custom CSS file and ensure it is referenced in your site AFTER the BootStrap CSS file.

How do I center an embeded iTunes button?

I am trying to embed this iTunes button that I am putting on a site, but it seems to automatically alight left. Where and how in this code would I make the button center itself? Please see the example code below. Thanks!
Here's a quick fix if you have access to the css you could easily do this with flex box.
Wrap your anchor tag:
<div class="itunes">
</div>
add this css:
.itunes {
display:flex;
justify-content:center;
}
jsFiddle
Although adding inline-styles is frowned upon..., if your in a pinch this will work as well. Please don't do this unless you must:
<div style="display:flex;justify-content:center;">
</div>
note: flex box works on most browsers.

Wordpress div class container, is it special in wordpress?

Hiall,
could someone please tell me, is the
<div class="container">
class/element some kind of special class for wordpress???
This div is currently wrapping all the content on my site and I am trying to put html code outside of this div, but no matter what I do it won’t let me and it automatically puts everything inside this div.
I’m looking at the file that contains the ending
</body>
</html>
tags for the document and when I try to put code right before the end like
<div class=“myotherrclass”></div>
</body>
</html>
When I load the page in the browser the last tag before , it automatically always puts the closing tag for the container div! eg.
<div class=“myotherrclass”></div>
</div> <!— container class closing div, automatically appears from no where! —>
</body>
</html>
Any help trying to understand what is happening would be great
I started with the Underscores.me starter theme and just deleted the "container" div from both header.php (the opening) and footer.php (the closing). And...nothing bad happened! Will report back if something does, but right now I'm deleting div tags not being used in order to make sense of what's going on. This one's gone!

Loading a HTML Page inside a DIV

Hi I have a div question,
on my home page I have a menu its in a div. The body has another div. Can I put or somehow call a specific div content from another page into the div of the homepage body when I call for it from my menu. or how can I put the other page inside the body div with out using Iframes. For example:
<html>
<body>
<div>content from the another_page.html div.</div>
or
<div>another_page.html inside here</div>
</body>
Can this be done? Thank you in advance.
You can use jQuery for solving this.
Please refer to this for loading div from another page inside div:
Load content of a div on another page
And for loading another page inside div:
loading html page inside div
You have a number of ways to do this, as commented already, ajax is probably what is used in most cases. However it can also be done using PHP, jQuery, and an HTML object.
Link to similar question: here
You could try this and style it with css
<body>
<iframe src="page1.html">
</iframe>
<iframe src="page2.html">
</iframe>
</body>

Why is my footer not aligned at center on pages without a sidebar?

My footer isn't aligned at the center on pages without a sidebar. On pages with a sidebar, the alignment is perfectly fine. Why is this happening? Can anyone help please?
Here's a link to the site I'm working on: http://www.thesuperwomanlifestyle.com/
The home page has no sidebar so the footer isn't aligned at the center. If you check other pages that have a sidebar, the alignment is alright.
Please help!
Fix your code errors, like the missing closing </p> and </div> tags. Those errors will throw the footer out of alignment. See [Invalid] Markup Validation of thesuperwomanlifestyle.com - W3C Markup Validator. Scroll down in the validation report to see line numbers and source code. Find the source in index.php and footer.php, but that depends on your theme. Start fixing the code errors and revalidate.
And fix the BOM file type of your header.php and index.php files, as per the warning in the validation report. Change them to unicode no BOM.
I have checked your code by using view source page for both home page and inner pages. I found that in home page the is inside and in inner pages the is outside .
So check your PHP template file for inner pages and close the div of "insidewrap" after footer's div.
Hope it solves your problem.
There are several reasons, in your footer you have diferent code in the diferent sections, and there are a image than not loads. Due to you use IDs for the DIVs, should be a good solution make the DIVs floating in the CSS code.
<div id='footer_left'>
<img src='http://www.christiflynn.com/wp-content/uploads/2014/03/Take-the-Lead3.jpg' />
</div>
<div id='footer_optin'>
<script type="text/javascript" src="//www1.moon-ray.com/v2.4/include/formEditor/genbootstrap.php?method=iframe&uid=p2c9303f30&version=1"></script>
</div>
#footer_left, footer_optin {
float:left;
width: 10em;
}
You might need to create another footer-page.php template. Then, rearrange another footer. Call the footer template by using get_footer('page');
Of course, when creating this, you will need to create a new template for footer so you can move it to the left.
If it's possible, we'd like to see your code for footer and the page code, please, so we can solve the problem.

Resources