locked
C# Based Web Page Builder RRS feed

  • Question

  • User1928065626 posted

    I have created a web page builder using javascript, HTML5, and web api but I cannot hide my scripts from view.

    Thus, I tried to create a web page builder using the Windows Forms WebBrowser control and then embed it in a webpage but there were too many limitations; the biggest one being the lack of support by browsers other than IE.

    Can someone suggest how I can create a web builder using C# or some other language where users cannot see my code, thanks.

    Thursday, November 23, 2017 2:47 PM

All replies

  • User753101303 posted

    Hi,

    I'm not sure to get what you want to hide. For a  web site server side code (usually C#) is not visible to users (should have been the case for your web api). Whatever is rendered to the browser (HTML, CSS and JavaScript) is visible to users.

    If you mean that you want to hide the generated HTML content you are building for a user you just have no way at all to do that (it needs to be transmitted to the browser and the user can use "view source" once shown in the browser).

    Thursday, November 23, 2017 5:07 PM
  • User1928065626 posted

    Hi, thanks for replying. I'm Ok with people seeing my markup and styles but I would like to at least be able to hide my JavaScript but everywhere I look online everyone said it cannot be done.

    Thursday, November 23, 2017 5:33 PM
  • User753101303 posted

    JavaScript is downloaded as well to the  browser where it runs. At best it could obsfucated.

    Server side code (C#, VB.NET etc...) runs on the server and could be "seen" only by those having access to the server side OS (ie not those accessing the server through the web site).

    Edit;, you have also node.js that allows to run JavaScript code server side (but I assume your code heavily interact with the browser DOM)

    Thursday, November 23, 2017 8:25 PM