Can't get rid of the invisible sign - html

I found invisible sign in my DOM. It is strange that I dont have it on my local website. When I send it on the server it appears there.
I tried copying this file to notepad++ and converting to UTF-8 without BOM and I was copying and pasting it to notepad.exe but also without any result. The server page keeps showing me this sign.
I also clicked in notepad++ to show me all invisible signs and it shows only CR LF.
Browser inspect of the file on my local machine:
Browser inspect of the file on the server:
Why it keeps showing there? and why the head content is moved to body?
I'm sure that aliens did it! Please help me.

The invisible character was hiding in .env file or one of the config files. I just converted them all to utf8 without bom in my notepad++ and its fine now!
ps. Yes, I still think that aliens did it!

Related

Same HTML source files but display differently

I'm new to bootstrap. I want to use the bootstrap on my previous project. But once I included the bootstrap.min.css it failed, while it can work fine if I create a new html from scratch.
I've uploaded the sample files in GitHub: https://github.com/kid551/toolbox/tree/master/bootstrapSameFiles . You can check that the test.htm and test2.htm are the same files but they will display differently like this:
test.htm:
=============================
=============================
test2.htm:
=============================
=============================
I think you can rebuild this issue by directly downloading from GitHub.
I don't know why it happens and how I fixed this.
Thanks.
You're running into some encoding issues. Even though your code base seems to be the same - it isn't. Let me show you visually.
The moment I switch from UTF-8 to UTF-16 BE, your working versions (test.htm) code gets cryptic, while the other one seems to be pretty well working.
test.htm (UTF-16 BE)
test2.htm (UTF-16 BE)
So eventually you might have copied your code from somewhere else or even used a wrong encoding.
EDIT
You can test that with any editor which is able to show you some code. Just try to delete a linebreak by hitting backspace at the first index of a row. You'll notice on almost every row that you're not deleting the linebreak but an 'invisible character' instead. So that again means, you're just not able to see those charecters your editor is not able to encode properly.
I have downloaded your source from the GIT. You are right both are similar but there is something wrong with the test2.htm file. I have NetBeans installed on my local. When I open test2 file its showing source as empty in NetBeans.But if I open the same file using notepad++ it's showing the source. So maybe file is corrupted. What I suggest is try to create the new file or use NetBeans. After saving using NetBeans its displaying same as test.html

Brackets.io error opening file, "Brackets currently only supports UTF-8 encoded text files"

I was working on my index.html, a lot of work was going on. So the next day when I went to open it up. I get this message, screenshot below.
I don't know why this happened

PDF link not working on webpage

Ok so I have a intranet webpage that I am making using HTML and I want to put a link (absolute or relative) on my page that opens a PDF.
The code I use is
Privacy and Security
Now what ends up happening is that I get this error:
404 - File or directory not found. The resource you are looking for
might have been removed, had its name changed, or is temporarily
unavailable.
Is there anything wrong with my code or where I am placing the document?
Thank You
If you are running this on a local machine check the permissions on the PDF file that they are world readable. I have this happen a lot in my OS X web directory, some files dragged in seem to have different permissions.
I see a number of small... oddities... in your sample line, which may or may not be significant in themselves, but could cause problems if you're doing any post-processing of the line before it goes live.
http://harold.local/documents/sandP.pdf is a good destination, correct? If you drop that by itself in to the address line of your browser, you can confirm that the PDF document can be found and displayed?
If you're doing any further processing of that string, should you be escaping the slashes or backslashes by doubling each one?
There's a stray space between your target= argument and your _blank value, again a possible risk if something later on will attempt to parse the string.
There is what appears to be a stray Left Angle Bracket (or Less Than) symbol ("<") immediately in front of your Privacy and Security text, which could be misinterpreted as the start of a <p tag, probably not what you want.
I would start by verifying the destination, then adding the context around it a bit at a time until something breaks. Failing that, find a similar working example of the <a usage on your local machine, and use that as a starting point for the link to your sandP.pdf document.

random characters appearing when site is rendered

On a couple sites I've made random ASCII characters have been appearing in the middle of the document. It's always been on test sites and has never been a problem until my most recent project for a client that it just appeared on. They aren't displayed in the development environment I use (aptana 3), but then appear both on screen and in the source code when viewed in a browser.I've looked around and it looks like others have had the issue but I haven't been able to find any real solution. I tried messing with the text-encoding but nothing changed. Has anyone been able to solve this issue?
Did you try saving your file as UTF-8?
Did you verify that your file is actually saved as UTF-8?
A Linux command to check the file type is:
file -i filename.html
Did you verify the content-header being sent from the webserver?
Is any of the text coming from a database?
You could also try adding the following meta string:
<meta charset="utf-8">
With your example site: http://www.oryxwebstudio.com/saloncruz/#contact
Maybe I'm blind but I do not see any invalid characters in IE, Firefox or Chrome. Here is a screenshot of Firefox:

File:// link doing nothing in all browsers

I have a link being generated that looks like so:
<a target="_blank" title="Test" href="file:///c:/test.xls">Test</a>
This link is inside an iframe.
When I click on it (in any major browser), nothing happens. Fiddler records no traffic.
Pasting the URL into the nav bar works fine - the file download box comes up, and I can download the file no problem.
I've tried every variant of the URL structure (correct and incorrect, colons, slashes, backslashes, etc.) that I can think of.
I'm certain that it's some kind of security restriction, but I can't for the life of me find out what it is or how to get around it. I'm feeling pretty foolish at this point. Any simple explanations?
Sorry, if you are pulling this page off of a server (acessing it as http://), the security settings won't let you link to local content (acess links as file://). I've had this same problem accessing shared .doc files in a wiki. Never came up with a good solution.
Try a colon instead of a pipe ;)