Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
html tags not matching
01-20-2012, 11:36 AM,
#1
html tags not matching
Tim,

I started using the check_closing_tags script. So far most of the problems it reports are due to code, written in this fashion:
if (condition) {
echo '<table class="table1">';
some code;
}
else {
echo '<table class="table1">';
some other code;
}
echo '</table>;

The script reports that there are two opening tags and only one closing tag.
I see two ways to fix it:
1. Separate html and php, so there is no html inside the if-else statements.
2. Put complete html statement in each side of if-else, so there is always a pair of opening and closing tags.
We should select one way to do it and keep it throughout the code.

Reply


Messages In This Thread
html tags not matching - by vitaliy_s - 01-20-2012, 11:36 AM
RE: html tags not matching - by phil - 01-20-2012, 03:11 PM
RE: html tags not matching - by vitaliy_s - 01-21-2012, 06:02 AM
RE: html tags not matching - by vitaliy_s - 01-21-2012, 08:07 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)