Back To Start Of Archive
Taken From The Forum: Help & Support for DHTML Menu Version 5+
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:36
Quirkiness with menu & XHTML
Poster: HLCJeffIT
Dated: Thursday March 25 2004 - 21:35:49 GMT
Okay, so I'm converting my pages over to XHTML and everything is great, but when I put my <DOCTYPE> tag at the beginning of each page, the padding in my menu goes to hell. Any thoughts?
Example is any page at http://63.166.197.49
Thanks,
Jeff
Poster: Maz
Dated: Thursday March 25 2004 - 22:11:30 GMT
I'm not sure about the padding problem in particular.
First its a good idea to validate your page with w3 validation service.
Then you would realize you need to use CDATA tag to hide the menu script in xhtml. If you are not sure what it is see the thread on bug fixes where I posted an example. Sorry bugfixes has gone, take a look at my source code in -www- link.
Its also a good idea to start your paths with a slash / from the root.
Where you have subimagepadding you don't need the quotes.
Where you have no subimage its best to remove it completely.
Usually we use menustyles like fontweight=bold;oncolor=#000000; for individual menuitems or <style=color:#000000> </style> would be correct in xhtml.
Let us know if any of those fixes make a difference.
maz
Poster: John
Dated: Thursday March 25 2004 - 22:30:48 GMT
You also might want to try backing off of strict until we get it all sorted out. I use the following in all my docs with no problems that I know of...
Code:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
Poster: HLCJeffIT
Dated: Friday March 26 2004 - 15:37:56 GMT
John wrote:
You also might want to try backing off of strict until we get it all sorted out. I use the following in all my docs with no problems that I know of...
Code:
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
I tried Transitional first then strict to see if it would change it.
I validated the code in the afternoon yesterday and spent a little while fixing those mistakes. Im sure its just a matter of cleaning up the code some more.
-------------
Update #1
And now, mysteriously it all seems to look like it should. I completed my <script> tags to look similar to mercury exposure's menu <script> tags and put my license number up.
crazy, man.
-------------
Update #2
Figured it out. I also did my <!DOCTYPE> tag the same as mercury exposure and added the <?xml version="1.0" encoding="iso-8859-1"?> tag and THIS is what brough my padding back.
Thanks all!