It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
Is there any way to hide css files on WP? I need to hide style.css file and file route.
Not only style but also need to hide other css file and their routes.
The fact is, any and all Style Rules are required to be either written directly to the document itself, or referenced in the head element in the form of a link tag.
There's no big secret to styling, so I'm not entirely certain why you would want to "hide" your stylesheet from prying eyes. Even if you were to create several hundred decoy CSS files and use cleverly placed #import rules to "confuse" somebody trying to find the actual filepath, what's to stop them from using a Web Inspector and seeing the active rules and the stylesheet in which they're contained?
Sorry to say, but you're pretty much going to have to deal with the fact that Style rules can be accessed by anybody.
Related
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 9 years ago.
I do a lot of front end work and was thinking of picking up CSS LESS, but midway through learning it, realized it may not work the way that I thought it would work and might not be able to help me as much. So I think below is how CSS LESS works, could someone who have used it just confirm please?
CSS LESS works using the SimpLESS compiler and makes the process of
initial css coding more easy with programming elements implemented.
However, before uploading the css code, it must be converted from the
dynamic .less format to the normal .css format and once uploaded to
the server, can only act as a static .css file.
Is the above correct? I ask because I work with a lot of wordpress websites and themes that already have the majority of their stylesheet created, and if I have to compile the .less format to .css format and reupload every single time rather than being able to use it as a dynamic pre-loaded library like jQuery, then I might not be able to get as much out of CSS LESS as I previously thought it would benefit me.
Both LESS and SASS are technologies designed to aid in the development and maintenance stages of creating CSS files; they work similarly to how Coffee Script is designed to work for javascript. In the end, however, LESS and SASS end up as CSS files just as Coffee Script results in plain old js files.
In any case, there are workflows that automatically handle compilation/save/upload of CSS files to prevent that step from taking extra time and work on your part, but no - browsers do not understand them by default. You can use javascript implementations as comments have mentioned, however.
LESS/SASS have their strengths, but making minor tweaks or customizations of existing themes and styles might not necessarily be one of them. This is not to say that you might not actually get a lot out of the technologies, but that is beyond the scope of your present question and would not even be something I am presently qualified to answer.
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 9 years ago.
When I first started learning front end development I used to see the first line comment
/* css document */
or something to that extent, I can't remember what it was...
I haven't used it recently. Is it even necessary anymore?
Was that just a dreamweaver thing?
Could having your first line of css as a comment be dangerous?
CSS doesn't need any declaration like HTML documents do need DOCTYPES (well they don't need them but it's highly recommended)
Having a comment as first line in your CSS isn't dangerous at all. (In fact WordPress themes requires this, but that's something completely else)
You never have. From what I recall, the first line css comment was a, somewhat unnecessary, feature of dreamweaver at some point. Its only purpose was to remind the user that they were writing a css file, which was only necessary because dreamweaver would automatically save the document as .css if you clicked New>CSS File.
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I dont know how to include SCSS file in my website but I have completely developed .scss file using notepad. Please let me know how to include it in my website?
You can't have a link to SCSS File in your HTML page.You have to compile it down to CSS First. No there are lots of video tutorials you might want to check out.
Lynda provides great video tutorials on SASS.
there are also free screencasts you can google...
For official documentation visit this site
http://sass-lang.com/documentation/file.SASS_REFERENCE.html
And why have you chosen notepad to write Sass??
you can easily download some free text editors for better code handling.
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I am working on a custom CSS file within a wordpress theme installation.
Within the CSS, there are times when I need to identify something like '.example', other times when it must be displayed as '#example' and other times when it is fine to keep it as 'example'.
Could someone please clarify the rules and how I can distinguish and decide for myself in the future which one to use in each instance?
This might have something to do with div ids and classes.
There is no 100% rule but generally:
An id must be unique, therefore any styles applied to an ID are only usable for the one element on the page. Therefore it usually makes more sense to style by class rather than ID because the mjority of the time you are going to want to reuse your styles. Additionally using an ID makes it harder to override the style later because id's hijack specificity.
I even take this one step further in that nothing should EVER be styled by ID but rather always styled by class. The one exception i occasionally make is for page-level scoping based on the id of the body tag. But even then a class is just as useful.
Id recommend reading up on OOCSS (note: i dont use any of the files used to illustrate the examples - im solely referencing the FAQ)
It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center.
Closed 10 years ago.
I wrote a rule for URL Rewrite and it works fine, but after I put it in place, the images in the pages no longer appear.
It's because you have addressed your images relatively, which means their addresses will be rewritten accordingly.
For example, if you page at /folder/page.html gets rewritten to /folder/pages/page and you have an image at image.png the browser will try to locate it at /folder/pages/page/image.png instead of /folder/image.png.
To avoid this, either address them using their absolute path, or use a rewrite condition that avoids rewriting URLs that point to existing files or directories.
Use a <base> tag in the head, to solve this problem.