Re: validating asp code

On Thu, 27 Jun 2002, Michelle Podd wrote:

> We have created ASP pages to make an online shopping cart. It is this cart
> we are validating. Correct me if I'm wrong, but I understood the validation
> process to be this:
>
> - parse the page in question through a browser
> - copy the source code into a new .htm document and upload
> - run this .htm page through the w3c's html validator
> - repeat the same page if it has more than one condition (example, if basket
> is empty display this, if not, display that).
>
> By using the method above, I have validated the shopping cart at
> http://www.iqnetcom.com/democart.asp and added the appropriate icon to the
> bottom of the page.
>
> Here's the problem: if you go the above url, put something in your basket
> and run through the validation process on the basket.asp page (for either
> condition), the page validates. However, if you click on the icon at the
> bottom of the page, it runs the page through the html validator and it does
> not validate anymore.
>
> There are two errors: it tells me there is a closed table tag when there is
> no open table tag (that's crap).

When the basket is empty (as it is to the Validator), you have an extra
</table> tag (on line 78).  When the basket has something in it, there is
no extra </table> tag.

> Second, it tells me there is a closed form
> tag when there is no open form tag (also crap).

When the basket is empty (as it is to the Validator), you have no <form>
tag.  When the basket has something in it, the <form> tag appears.

-- 
Liam Quinn

Received on Thursday, 27 June 2002 15:45:30 UTC