Mark Forums Read
  #1  
Old 04-22-2006, 09:23 PM
ClarkF1 ClarkF1 is offline
Junior Member
 
Join Date: Apr 2006
Posts: 1
ClarkF1 is on a distinguished road
Question Problem with form tag in XHTML

I have the following code for my webpage:

HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <head> <**** **********="Content-Type" content="text/html;charset=utf-8" /> <link rel="stylesheet" type="text/css" href="layout.css" /> <title>Photo Gallery Admin Panel</title></head><body> <div id="main"><h1>Set Password</h1><p> <form action="gallery_admin.php?act=new" name="setpassword" method="post"> <label for="password">Enter admin password: </label> <div id="finput"><input id="password" type="password" name="pass" size="20" /> <div id="finput"><input id="submit" type="submit" value="Set Password" /></div> </form></p> </div> <div id="footer"><p /><p /> <table class="f1"> <tr><td></td></tr> <tr> <td></td></tr> <tr><td><h3>Photo Gallery Wizard by <a href="http://trionite.chris-kent.co.uk">Trionite Design</a></h3></td></tr> <tr><td class="f2"> <a href="http://validator.w3.org/check?uri=referer"><img src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0 Strict" height="31" width="88" /></a></td></tr> </table> </div> </body> </html>
However I'm getting:

Code:
# Error Line 10 column 58: document type does not allow element "form" here; missing one of "object", "ins", "del", "map" start-tag. <form action="gallery_admin.php?act=new" method="post"> The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element. One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").
I can't see what the problem is.
Reply With Quote
 #Add to Ads's Reputation  
OldSponsored Ads
Ads AdsPromoter is online
Member
 
Join Date: LongTime
Posts: 1100
Ads is on a distinguished road
Default New Sponsored Ads



This message will go away once you are registered. Also, by registering, you will have access to all post topics, communicate privately with other members (PM), respond to polls, upload graphics, and access other special features! Registration is fast, simple and absolutely free so please Click Here to join our Web Hosting community today!
Reply With Quote
  #2  
Old 08-11-2008, 06:11 AM
Sakari Sakari is offline
Member
 
Join Date: Jul 2008
Posts: 34
Sakari is on a distinguished road
Default

Quote:
Originally Posted by ClarkF1 View Post
I have the following code for my webpage:

HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <head> <**** **********="Content-Type" content="text/html;charset=utf-8" /> <link rel="stylesheet" type="text/css" href="layout.css" /> <title>Photo Gallery Admin Panel</title></head><body> <div id="main"><h1>Set Password</h1><p> <form action="gallery_admin.php?act=new" name="setpassword" method="post"> <label for="password">Enter admin password: </label> <div id="finput"><input id="password" type="password" name="pass" size="20" /> <div id="finput"><input id="submit" type="submit" value="Set Password" /></div> </form></p> </div> <div id="footer"><p /><p /> <table class="f1"> <tr><td></td></tr> <tr> <td></td></tr> <tr><td><h3>Photo Gallery Wizard by <a href="http://trionite.chris-kent.co.uk">Trionite Design</a></h3></td></tr> <tr><td class="f2"> <a href="http://validator.w3.org/check?uri=referer"><img src="http://www.w3.org/Icons/valid-xhtml10" alt="Valid XHTML 1.0 Strict" height="31" width="88" /></a></td></tr> </table> </div> </body> </html>
However I'm getting:

Code:
# Error Line 10 column 58: document type does not allow element "form" here; missing one of "object", "ins", "del", "map" start-tag. <form action="gallery_admin.php?act=new" method="post"> The mentioned element is not allowed to appear in the context in which you've placed it; the other mentioned elements are the only ones that are both allowed there and can contain the element mentioned. This might mean that you need a containing element, or possibly that you've forgotten to close a previous element. One possible cause for this message is that you have attempted to put a block-level element (such as "<p>" or "<table>") inside an inline element (such as "<a>", "<span>", or "<font>").
I can't see what the problem is.
Hi


can anybody tell us the minor problem in this code and sort out our queries


thanks
__________________
web design services
Free Templates
Reply With Quote
  #3  
Old 06-27-2009, 11:07 AM
gkumar gkumar is offline
Senior Member
 
Join Date: Jun 2009
Posts: 203
gkumar is on a distinguished road
Default

Hi,
im trying to put a search box in my page, and search box is not working on my mobile,
what am i missing
i have tested the functionality online it works!
will open in IE too, ive programmed it to give WAP2.0 when accessed via browser.
the following is the code, when i type something, and i hit enter, the index.p
Quote:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//WAPFORUM//DTD XHTML Mobile 1.2//EN" "http://www.openmobilealliance.org/tech/DTD/xhtml-mobile11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Search Results for : web</title>
<link rel="stylesheet" href="/wap/wireless.css" type="text/css" />
</head>
<body>
<p class="title">
<img src="/wap/images/logo.gif" width="80" height="25" alt="" />
<br /></p>
<p class="title2">Search </p>
<form method="get" action="/wap/">
<p class="content2">
<input type="text" id="search" name="search" size="10" value=""/>
<input type="submit" value=" Go " />
</p>
</form>
<p class="content"><a href="/wap/" accesskey="1">HOME</a></p>
</body>
</html>
Reply With Quote
 #Add to Ads's Reputation  
OldSponsored Ads
Ads AdsPromoter is online
Member
 
Join Date: LongTime
Posts: 1100
Ads is on a distinguished road
Default New Sponsored Ads



This message will go away once you are registered. Also, by registering, you will have access to all post topics, communicate privately with other members (PM), respond to polls, upload graphics, and access other special features! Registration is fast, simple and absolutely free so please Click Here to join our Web Hosting community today!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT. The time now is 01:35 AM.


Powered by vBulletin Version 3.6.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
SEO by vBSEO 2.4.0