I just wanted to know what <% these exactly do? %> I've used these for exporting some html tables and data to excel, but i don't really know what it's function is. any answers are appreciated.
so like when i use these in below coding, am i actually using asp?
<body>
<%
String exportToExcel = request.getParameter("exportToExcel");
if (exportToExcel != null && exportToExcel.toString().equalsIgnoreCase("YES")) { //application/vnd.ms-excel
response.setContentType("application/vnd.ms-excel"); //application/vnd.opentextformatsofficedocument.spreadsheetml.sheet
response.setHeader("Content-Disposition", "inline; filename=" + "whatever.xls");
}
%>
i got it from http://www.quicklyjava.com/export-web-page-to-word
Answered over here: Name for Angle Bracket Percent Sign. Which then links to another answer.
In short, they are code render blocks which execute when the page is rendered. They are expressions as a part of the ASP.net framework, from what I can gather.
More information: here
EDIT: As others have commented, I found all this from a quick search.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With