Solved

how to write Server.HtmlEncode

Posted on 2013-06-28
4
314 Views
Last Modified: 2013-06-28
I am trying to validate this page: http://roofgenius.com/test2.asp
called from this page: http://roofgenius.com/test.asp
Evidently I need to add Server.HtmlEncode somwhere in this code:
 <% name = request.querystring("name")
  response.write "Dear: "& name & ",<br />Thank you for sending us the following:"
  comment = request.querystring("comment")
  comment = Replace(comment, vbcrlf, "<br />")
   response.write "<br />" & comment & "<br /><br />If you have asked us to contact you, we will be using the following email address:<br>"

  email = request.querystring("email")
  response.write "<span class=""redbold""> Email : " & email & "</span><br /><br />"
   %>
    If any of this information is incorrect, please click the back button and change it.
We thank you for taking the time to help us be a better company.<br />
    <br />    
      Sincerely, <br />Manager, Roof Genius Customer Support
        <div style="text-align:right;margin-top:20px">             
      <a href="jmail.asp?<%=Request.QueryString%>">    
     <img src="images/buttonsubmit.gif" width="91" height="23" alt="Submit" title=""/> </a>  
      <a href="support.asp?<%=Request.QueryString%>">
      <img src="images/buttongoback.gif" width="91" height="23" alt="Go back" title=""/></a>




But how ?
0
Comment
Question by:isnoend2001
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 53

Expert Comment

by:Scott Fell, EE MVE
ID: 39286178
This is what htmlencode does http://www.w3schools.com/asp/met_htmlencode.asp

Are you trying to validate your final html code or validate input?

What is the specific error you are having?
0
 

Author Comment

by:isnoend2001
ID: 39286200
I am trying to validate the source W3C on page2
see attached
errors.jpg
0
 
LVL 53

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 39286229
<div style="text-align:right;margin-top:20px">             
      <a href="jmail.asp?<%=Server.HTMLEncode(Request.QueryString)%>">    
     <img src="images/buttonsubmit.gif" width="91" height="23" alt="Submit" title=""/> </a>   
      <a href="support.asp?<%=Server.HTMLEncode(Request.QueryString)%>">
      <img src="images/buttongoback.gif" width="91" height="23" alt="Go back" title=""/></a>

Open in new window

0
 

Author Closing Comment

by:isnoend2001
ID: 39286230
thanks it validates, your the man
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

As a result of several questions about how to use Bootstrap I thought it would be a good idea to write down the development aspect of creating a Bootstrapped website in as little time as possible. Part 1 of this article will only concentrate on g…
This article discusses four methods for overlaying images in a container on a web page
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…
Suggested Courses

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question