Hi everyone. i am not new here Lost my login and discoverred the login via facebook button so there you go.
Anyway, i am having a bit of a cross browser issue on a site in development. Basically whenever i add the form tag to the page the site seems to break in IE9. Every other browser behaves as intended.
The affected container is the red one with “E-News & Updates as the title”.
Only when I include the form tag does this happen, otherwise the site behaves itself! Any help would be appreciated.
First it’s worth validating the site/page, there are a couple of errors in there.
The other issue is that the entire page is wrapped in a form tag, so adding a form inside a form can give you all sorts of weirdness…
Yes, I was about to say the same thing as you can’t have nested forms.
The validator flags it up along with some other errors.
IE9 likely closes the first form tag when its error checking clicks in and sees another form starting and ends up breaking the layout in the process.
Yeah that will be the daft CMS i have to use at work.I have noticed that form tag and unfortunately nothing i can do about it as it it part of the cms and its functionality. I can bet if I dropped the site into WordPress these issues wouldn’t occur I am not too worried wether or not it validates at this point as i tend to go through that after if need be.
I will certainly look intro that, maybe its an update of the cms that seems to be messed up as i haven’t come across this problem before. DNN websites leave a huge footprint and usually don’t do a great job at validating!
Mr. Tomas, The validation errors that you SHOULD be concerned about are the mismatched divs and the like. That will break an otherwise well designed web page in a heartbeat. It is foolish to take them for granted and ASSume that all devices will be able to figure out where the close tags are supposed to be.
I have just checked a few other dotnetnuke based websites and it seems it is part of the cms fucntion
I never assume that and always cross browser check
That’s a major flaw in the CMS if it forces pages to be wrapped in a
form tag, apart from it being daft I’d hate to guess what confusion it causes people who use screenreaders and other assistive technology.
Can you see why the tag needs to be there, maybe you could remove it altogether?
I wish I could! Unfortunately this CMS is main one used by the agency I work for. Personally i would pick anything but DNN. It has so many flaws and it heavy on code. Take a look at any DNN based website and you will find the same code and a huge footprint it leaves.
I usually dont bother validating my DNN based websites and go for a simple cross browser check because by the time the client gets hold of it all the work you put in validating it will be pointless…think word and copy and paste
Wordpress and Umbraco I find to be clean and easy to manage in terms of validation…but of course then you have plugins…Its a big old game of cat and mouse we play…
I will certainly bring it up in the DNN forum because it is certainly something that needs addressing.
Wow, that certainly is bizarrre. Even the DNN site has almost the entire body content wrapped inside a form. I have no doubt that they
Mr. Tomas, I apologize for my rudeness. My ignorance is showing. I have a very hard time remembering that CMSs can be so flawed and that the coder has no control over their output.
Can’t you just remove the nested form tags and handle that submission through the main form or with click handlers of some sort.
<input type="email" placeholder="Email address">
<input type="submit" value="Get It Now">
If you remove those form tags above I believe IE9 may work because then it won’t close the form prematurely.
So you’re sayong IE does something like
<tag> they must have forgot the
</tag> so I’ll be nice and add one in before this other
It’s hard enough coding for things you know browsers do let alone trying to code for things they might do !
Yes, it does something similar to that I believe.
If you look at the developer tools In IE9 at the generated html for this page it moves the actual closing form tag from the bottom of the page to a position mid-way up the page and at the same time removes the nested form tag.
Here’s what the snippet I posted before now looks like:
<input type="text" placeholder="Email address">
<input type="submit" value="Get It Now">
<div class="container main">
That’s why valid pages are essential
This is very interesting As I said, I would much rather work with wordpress. This isn’t the first time I have had trouble with forms in DNN likely because of this issue. I have tried with feedburner forms that simply wont run, aweber and getresponse too.
I certainly wont be offering DNN this to my own clients in the future. May look at Joomla or Drupal as a replacement if they are as clean as wordpress.
No problem If I had a choice I wouldn’t choose DNN, but I am stuck with it for the project. I soon learned after starting with the agency that validating pages in DNN was pointless and the key was just to get them to work via good old fashioned cross browser testing.
I believe you may have hot the nail on the head there…
I am going to try this when I get back into work on Monday and let you know how I get on!
Alternately you could try pulling your forms in via an iframe, It’s the work-around we usually use to allow forms onto our DNN pages.
That is exactly what I have been doing until now.
I have however found a solution since then! Although I have only managed to get it working for mailchimp so far, which is fine as there are plenty of contact form solutions, I only needed an autoresponder solution.
The solution is below to my complete sign up form. I know that there are not very many here using DNN but you never know when you may find it handy!
MailChimp Form.txt (721 Bytes)
Why I’ve always hated (the old-style) ASP pages. Runat=server form BS, used to break every single Opera, every single time.
Glad to see at least IE9’s on the ball here. I’m cheering you, IE9! CHEERING.
ASP updates don’t use the form method anymore. I forget what it’s called… razor? Some weird Microsoft thing, but it’s much much much cleaner than this old stuff, and does not need to wrap every HTML page in a form.