-
Apr 22nd, 2018, 10:16 PM
#1
Save html/php file to a database and load it dynamically? For "protection" purposes.
I just want it to be a little bit difficult for others to see my code so I am contemplating on saving them in the database and just load them dynamically, would that be feasible? It's like a CMS but I am not sure if they are the same since I want to save the entire contents of the file instead.
Any other solutions are welcome!
TIA
-
Apr 23rd, 2018, 03:16 AM
#2
Re: Save html/php file to a database and load it dynamically? For "protection" purpos
Maybe but what's the point?
A firebug like will expose every bit of client side code anyhow.
Also depends if you are writing on server side or client side. Server side would be more difficult to manipulate in order to reach the web page "fixed" for creating the html.
Client side can be manipulated. I was doing some coding a while back, using html templates, maybe you can take a look at those. You can just get you inputs ready and fill the data from server side. But I guess you mean the code written dynamically, so that's why I said what is the usage in that? If it is server side then it can't be read anyhow and if it's client side it would need to be translated to html, javascript, the lot, in order for the browser to interpret it, so you can't really hide it.
If you are determined then search for javascript or html obfuscation . See if you can find anything (doubt it).
ἄνδρα μοι ἔννεπε, μοῦσα, πολύτροπον, ὃς μάλα πολλὰ
πλάγχθη, ἐπεὶ Τροίης ἱερὸν πτολίεθρον ἔπερσεν·
-
Apr 23rd, 2018, 12:35 PM
#3
Re: Save html/php file to a database and load it dynamically? For "protection" purpos
I send HTML to my pages using AJAX calls after they load all the time. I even have "hot re-load" capability so I can make changes and re-load that HTML without forcing a login from scratch.
Some of that HTML comes from tables in the database and others from small snippet files on the web server.
I also send JavaScript to my pages using AJAX calls - that is also stored in the database. That way my SlickGrids can have function stubs for BEFORECELLEDIT and ONCHANGE events...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|