Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Style sheet (CSS ) protection from public

Tags:

html

css

We need to protect my external style sheet downloading from others

eg: if click the save as button from a browser that will get all images, html and style sheet of the website. we need to block downloading my website images, html and CSS

how is it possible

please help me .......

like image 275
Sainul Avatar asked Jul 30 '11 07:07

Sainul


People also ask

What are the 3 types of CSS style sheets?

There are three types of CSS which are given below: Inline CSS. Internal or Embedded CSS. External CSS.

Should CSS be in public?

Just your application should use it. In public folder you would have all your compiled and minified scripts for production. So css and js should be in the resources/assets and then compiled and published to the public part.


1 Answers

That is technically impossible and illogical. Your HTML, CSS and images need to be available to everyone that can access the site, otherwise they wouldn't be able to view them in the first place. And by definition, you have no control over the client's browser which handles the downloading and saving of said resources.

By the way, there are some tricks employed by people wanting to do the same (like using Javascript to block the right click menu) but such tricks are just that: Tricks. They trick the naive user into thinking that some resources can't be downloaded/saved. However such tricks are easily circumvented by a user with very little knowledge.

like image 178
edgerunner Avatar answered Oct 04 '22 01:10

edgerunner