In my project i have master page that looks like this:
<asp:Content runat="server" ID="content1" ContentPlaceHolderID="Content">
<div id="RightBar">
<asp:PlaceHolder runat="server" ID="plhRightbar"></asp:PlaceHolder>
</div>
<div id="content">
<asp:ContentPlaceHolder ID="MainContent" runat="server"></asp:ContentPlaceHolder>
</div>
</asp:Content>
for some reason ff 3.6 renders the <div id="content"> inside <div id="RightBar">, needless to say that this behavior is messing with the whole website layout.
this bug is happening only in ff 3.6, even IE6 render it correctly.
so far i tried the following steps:
1. changing the DOCOTYPE.
2. looking for unclosed tags inside each placeholder.
3. changing css.
the css:
#RightBar{float:right;width:225px}
#content{width:707px;float:left;overflow:hidden}
but none of these work.
any ideas?
EDIT: i can't give you a link because it still in development, but in ff 3.6 it looks like this:
<div id="RightBar">
...right bar content here...
<div id="content">
...content here...
</div>
</div>
My first impulse is to get rid of the float:left; for content or at least change it to float: right; (several floats on the same side stack upon each other when there is enough room)
If that fails, try using a table to get the layout you want. Yes, I can hear you cry out in horror but the rule for tables is "use tables only when they make sense" and not "never ever under no circumstances whatsoever use tables".
I suggest running the generated HTML code through the W3C Validator -- it sounds very much as if you have some kind of HTML syntax error; I can't see it in the code you've posted, but the validator will pick it up.
Use the browser's 'view page source' option, and paste the whole thing into the validator's text area.
The validator can be found here: http://validator.w3.org/
Related
I'm creating a table of contents using the id linking method. How do I get it to work properly? I've triple checked and for some reason, it's not responding when I click on the link.
I've tried creating an id and name within the tag. It only seems to work for the top of page id. I'm using Shopify's blog editing feature which accepts HTML.
1. Example
<h3 id="Test">My Header Here</h3>
I've got it to work before but it's not anymore. Maybe I have to clear my cache?
you just add height at your tag
for example
<html>
<head>
</head>
<body>
<div style="height:600px">
1. Example
</div>
<div style="height:600px">
<h3 id="Test">My Header Here</h3>
</div>
</body>
</html>
The code is correct.
What happens if you try the code below instead? Both of these should be valid, so it would be weird that one works and the other doesn't.
1. Example
<a name="Test"><h3>My Header Here</h3></a>
i'm using bootstrap CSS for my application. I have asp:login control with "remember me" checkbox.
my problem is there is a space between checkbox and the word "remember me". i removed all checkbox css from my css files, but still couldn't fix the issue.
I tried this css code to remove the white space
.chkbox{margin-left:0px;padding-left:0px;white-space:nowrap;}
and this is my Login control
<div class="contact-address span3" style="/*width:250px;*/margin-top:15px;padding-left:5px;">
<h3 style="color:#1872AB;font-weight:normal;">LOGIN:</h3>
<div class="login">
<asp:Login ID="user_Login" runat="server" OnAuthenticate="user_Login_Authenticate" RememberMeText="Remember me" TitleText="" UserNameLabelText="Email:" PasswordLabelText="Password:" OnLoggedIn="SAP_Login_LoggedIn" >
<LoginButtonStyle CssClass="con-tbutton"/>
<CheckBoxStyle CssClass="chkbox"/>
</asp:Login>
<table style="width:100%;">
<tr><td style=""><label>Forgot your password</label></td></tr>
</table>
</div>
but still, it looks like the image below
any ideas?
I just quickly made a sample aspx page, and it works just fine:
This is unstyled. As you see, the checkbox aligns just fine. I don't see any bootstrap styling in your example, or classes for that matter. It might be the closing </div> tag you're missing... This is the best I can give you without a live html example from you on JS Bin or somewhere simlilar. Try what I suggested in my last comment.
I have an adsense block that I'm adding to wordpress I'm using a plugin to add the shortcode.
I want it to wrap the text around. So I add the code:
<div style="float:left;">
ADSENSE CODE
</div>'
But it just positions it to the left with the text underneath.
On my other blog, this works just fine. But on a new blog that I'm making it doesn't work at all. I'm pulling my hair out trying to figure out why!
I changed the theme to 2010, 2011 and 2012 and it's always the same. But as I say, on my other blog it works just fine!
I've tried different browsers, cleared cache, etc.
It looks like a typo:
- <div style="left;">
+ <div style="float:left;">
or even better use classes and ids to set it up in a stylesheet that you can use on other pages as well.
<style>
.ads{float:left;}
</style>
...
<div class="ads">
Trying to set a page break in the page I'm working on but in the print preview I'm still seeing things on the page that aren't supposed to be there. Can't figure out why this isn't working.
In my css style:
.applicant-break hr {page-break-after:always;}
In my ASP.NET code...partial view of code the start tags are there:
<b>Resume</b>
<br />
<asp:Literal runat="server" ID="litResume"></asp:Literal>
<br />
<br />
<hr class="applicant-break" />
</ItemTemplate>
</asp:Repeater>
</asp:Panel>
Any help would be appreciated.
Your css needs to be
hr.applicant-break {page-break-after:always;}
EDIT:
Doing some reading on the W3Schools website, it seems this css property is meant for table elements
"Set the page-breaking behavior to always break after a table element"
EDIT:
Doing some more reading, it seems browsers do support more than the table element, however some browsers have trouble with it on HR and BR tags (Reading here)
try putting a div after the hr like so
<hr />
<div class="applicant-break"></div>
and changing your CSS to
div.applicant-break {page-break-after:always;}
So apparently I'm silly, I was trying to trust the print preview of Chrome instead of just actually printing it myself, upon printing it I see that the page break does in fact work, thanks for your assistance m.t! :)
So fair warning to anyone else reading this, while it is useful it doesn't always give you an accurate look at your print job all the time.
I am using the DNN MobiNuke Module (v02.00.03) from DataQuadrant to create a mobile version of a website I have created. Everything is going well EXCEPT a weird issue I am running into with the Mobile Skins. I have a simple Mobile Skin that looks like this:
<div id="mobile_frame">
<div id="mobile_header">
...
...
</div>
<div id="main_wrap">
<div id="mobile_main" class="sub">
<div id="ContentPane" runat="server"></div>
</div>
</div>
<div id="mobile_footer">
...
...
</div>
</div>
The issue that is arising is that ANY content in the ContentPane that has an empty div tag will change itself when rendered in a mobile browser:
<div class="xxxx"></div>
Will change itself to
<div class="xxxx" />
The biggest problem that this is causing is that the browser is interpreting the tag as an opening div tag with no closing tag. Therefore it is placing an ending div tag essentially wherever it wants. It's causing ALL of the markup after this area to get very messed up.
Here is an example of the code as it should be, and how it is rendering on the page:
Should be:
<div id="main_wrap">
<div id="mobile_main" class="sub">
... Content Here ...
</div>
</div>
<div id="mobile_footer">
...
</div>
</div>
But it renders as:
<div id="main_wrap">
<div id="mobile_main" class="sub">
... Content Here ...
</div>
<div id="mobile_footer">
...
</div>
</div>
</div>
I can fix this in the markup that I have control of by putting inside of the tags, but I do not have the time/energy to go through EVERY module that might be showing up in the ContentPane to check for empty tags. In addition, there are places where I want an empty tag to fill it with content later with javascript.
Lastly, I did a TON of research to look this up and I cannot find a thing. The closest that I found is that this happens in XSLT when transforming some XML, but as far as I know MobiNuke is not doing that.
Any help is greatly appreciated. Thanks!
I have figured out the issue after having a discussion with the vendor. There is a setting in the module settings called "Enable content adaptation". Apparently the setting will try to make the HTML to be XHTML compliant, but it was definitely not working for me. Hope this helps anyone else seeing this.