Click here to Skip to main content
15,898,939 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: how to prevent direct access to pdf file? Pin
Greg Chelstowski17-Jun-09 21:48
Greg Chelstowski17-Jun-09 21:48 
GeneralRe: how to prevent direct access to pdf file? Pin
Christian Graus17-Jun-09 21:50
protectorChristian Graus17-Jun-09 21:50 
GeneralRe: how to prevent direct access to pdf file? Pin
Greg Chelstowski17-Jun-09 21:52
Greg Chelstowski17-Jun-09 21:52 
GeneralRe: how to prevent direct access to pdf file? Pin
Vimalsoft(Pty) Ltd17-Jun-09 21:54
professionalVimalsoft(Pty) Ltd17-Jun-09 21:54 
GeneralRe: how to prevent direct access to pdf file? Pin
Abhishek Sur17-Jun-09 22:01
professionalAbhishek Sur17-Jun-09 22:01 
GeneralRe: how to prevent direct access to pdf file? Pin
Vimalsoft(Pty) Ltd17-Jun-09 22:24
professionalVimalsoft(Pty) Ltd17-Jun-09 22:24 
QuestionHtml Encryption due to security reason? Pin
Tridip Bhattacharjee17-Jun-09 20:51
professionalTridip Bhattacharjee17-Jun-09 20:51 
AnswerRe: Html Encryption due to security reason? Pin
Abhishek Sur17-Jun-09 21:37
professionalAbhishek Sur17-Jun-09 21:37 
I think it is not possible to encrypt your HTML.. as otherwise your browser will not render it correctly. Rather what you can do, is just strip spaces and new lines from the html so that everything will be rendered in a single line.

Do it in your custom handler. Also use GZip/Deflate compression to shrink the response.

s = Regex.Replace(s, "^\\s*",string.Empty, RegexOptions.Compiled | RegexOptions.Multiline);
s = Regex.Replace(s, "\\r\\n", string.Empty, RegexOptions.Compiled | RegexOptions.Multiline);
s = Regex.Replace(s, "<!--*.*?-->", string.Empty, RegexOptions.Compiled | RegexOptions.Multiline);


Just use regEx replace to do your job easy in your custom StreamFilter.
Hope you understand.


QuestionHow to put java script.... Pin
igaurav17-Jun-09 20:50
igaurav17-Jun-09 20:50 
AnswerRe: How to put java script.... Pin
Amol-11117-Jun-09 21:31
Amol-11117-Jun-09 21:31 
GeneralRe: How to put java script.... Pin
igaurav17-Jun-09 23:15
igaurav17-Jun-09 23:15 
AnswerRe: How to put java script.... Pin
himanshu256117-Jun-09 21:34
himanshu256117-Jun-09 21:34 
GeneralRe: How to put java script.... Pin
igaurav17-Jun-09 23:19
igaurav17-Jun-09 23:19 
GeneralRe: How to put java script.... Pin
himanshu256117-Jun-09 23:58
himanshu256117-Jun-09 23:58 
GeneralRe: How to put java script.... Pin
igaurav18-Jun-09 0:26
igaurav18-Jun-09 0:26 
AnswerRe: How to put java script.... Pin
httplover18-Jun-09 4:52
httplover18-Jun-09 4:52 
QuestionHighlighting selected menu item with Content Pages Pin
NetQuestions17-Jun-09 20:49
NetQuestions17-Jun-09 20:49 
AnswerRe: Highlighting selected menu item with Content Pages Pin
DoctorMick17-Jun-09 23:14
DoctorMick17-Jun-09 23:14 
GeneralRe: Highlighting selected menu item with Content Pages Pin
NetQuestions18-Jun-09 6:08
NetQuestions18-Jun-09 6:08 
QuestionGrid View Problem Pin
Amit Patel198517-Jun-09 20:42
Amit Patel198517-Jun-09 20:42 
AnswerRe: Grid View Problem Pin
Vimalsoft(Pty) Ltd17-Jun-09 21:15
professionalVimalsoft(Pty) Ltd17-Jun-09 21:15 
QuestionSet home page to center on screen Pin
misCafe17-Jun-09 20:37
misCafe17-Jun-09 20:37 
AnswerRe: Set home page to center on screen Pin
Vimalsoft(Pty) Ltd17-Jun-09 21:38
professionalVimalsoft(Pty) Ltd17-Jun-09 21:38 
GeneralRe: Set home page to center on screen Pin
misCafe17-Jun-09 21:59
misCafe17-Jun-09 21:59 
Questionplease help me Pin
sivasampathkumar17-Jun-09 20:27
sivasampathkumar17-Jun-09 20:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.