Why doesn’t my website update even though the file has been uploaded successfully? (FTP) - html

I have been trying in vain to update my website. I use the following information for a connection:
server
name + password
port
SFTP
When I save the file, I get a message that the file was uploaded successfully.
However, the website does not update.
In addition, the file on the server does not seem to correspond to the file displayed on the e.g. homepage.
I am happy about every answer.
Thank you in advance.

Maybe the files are cached so even though you change the files, server might be responding you with cached results. To check if that's the case, open your developer console, then go to Network tab and then refresh your page. When the data is loaded, check if it says "cached" on "Status" column. If so, try force refreshing your page by pressing CTRL+F5.

Related

IE html anchor tags don't work when referencing local files that were made on other computers

I'm working on a large project, which uses IE (IE11) to display local htm pages. (Yes, IE is required. I can't use a different browser). We aren't using a web server; everything is pulled from the local drive. No http requests are made during this.
We're planning to send parts of it out to remote locations to use on those sites. Atm I'm using a self-extracting rar, so that the htm, js, css, and media files can all be put in the proper locations. After deployment, the file structure on the remote location should mirror that of the Dev system. Everything works fine on the Dev system. However, at the remote sites some of the anchor links stop working. After some testing, it appears that if the file I'm trying to link to originated from a different computer, the link does nothing. But if I were to make a new file, copy everything from the old file to the new file, and replace the old one with the new one, the link works. The files are identical in content, but only the one that originated from the remote site works.
Link
The above would work if foo.htm was created on that computer, but not if it was created on a different computer (such as the Dev computer). This issue appears to occur with .htm/html files, as well as .css and .js files. It might also occur for media files, but I didn't check.
I imagine there is some kind of security setting or something that needs to be changed, but I can't figure out what. We plan to distribute to a lot of sites, so I can't manually fix the problem for every site.
Any idea why this is happening?
Edit: No errors pop up in the console when I click on the links. I didn't check out the network tab, since everything is local, but that might be a thing to try tomorrow. Also, I didn't know about file blocking. I'll check that too. If that were to be the case, how can I unblock the files automatically? This may be deployed to people who don't have a strong grasp of computers.
From the description of the issue, it looks like when you send the zip file to another machine then on that machine file gets blocked.
Below are some ways to unblock the file or to prevent the blocking. You can choose the suitable way as per your requirement.
The easiest way to unblock the file is to, right-click the zip file then click on properties and click on the Unblock Checkbox and click the OK button. Then after try to unzip the file. It will unblock all files together.
You can also try to unblock the zip file by using the PowerShell command below.
dir "folderpath" -Recurse | Unblock-File
Note: Make sure to run the script as an administrator.
Further, you can set a group policy to prevent blocking the file.
Group policy path:
User Configuration-> Administrative Templates-> Windows Components-> Attachment Manager
Policy name: Do not preserve zone information in file attachments
You can double click this policy and disabled it.
Note: Please note this will leave you vulnerable to malware & is not recommended..

Link will not direct to local server resource

After running code I generate a link to redirect me to a directory found on the local server to which I have full access.
When clicking the link after run i get error message in the console : "not allowed to load local resource", but if I copy the same link and put it in a new browser tab, it functions correctly and redirects me to the specified directory. This issue is not specific to browser, the problem appears in all types of browsers.
Example for link using File Protocol :
Link
When you put a URL directly in the address bar then you, the user, are explicitly requesting it and (in theory) know what you are doing.
When you click on a link, the browser doesn't trust that the author of the page isn't trying to trick you, so additional security restrictions are applied.

How can I display an image from a file server with HTML

I have a website that displays a lot of messages and images, usually through normal HTML tags. We now have a file server where we would like it to be our one stop place to retrieve files and images.
I can create links that allow me to download files from the server but I can't find anyway of displaying the images on the web pages.
To clarify a bit more, our web page is running through a server we'll call SERVER1, and we used to just retreive our files from that server. Now we are still running the website through SERVER1 but want to display images from a different server named FILESERVER.
links like
http://SERVER1/imagedocs/image.jpg used to work but
http://FILESERVER/imagedocs/image.jpg doesn't work
while
file://FILESERVER/imagedocs/image.jpg does work but I believe this is because I have a local connection to the server and will not work if I apply it to the website.
Any clues on what I should be looking for as a solution.
the file:\\ means it's a local file opened by your browser.
There might be various reasons why you can't access stuff that are currently on your server. I will take as granted that the file is actually on your second server, and you havent made a typo ( you can still double check it though, double check the filepath too (( maybe it was ROOT/dir/image.jpg and now it's ROOT/image.jpg)) ). Do you know if your 2nd server is blocking connections perhaps ? Have you succesfully connected to it? i'd suggest you to ping your server adress to see if you got a response, if it does ping, we going to need more infos about the way your server have been set up.

Files on the ftp server are not showing up on html site

I've been uploading files to my site successfully up until now. Unfortunately I've been encountering this inexplicable error.
File and edits that show up in the files in my ftp server, are not showing up on my website.
What's happening!
First, double check that you are naming the new/updated files exactly as they are named in the code for your site. It's possible that you are adding files to the server but your current code is linking to pages or documents with the previous names/spellings, not your new files. Second, are you using a client such as FileZilla to upload these files to the ftp server? If so, be sure to check that you are transferring the local files in the queue to the server after they have been added. Additionally, you could try clearing your browser history. Perhaps your browser is using an outdated, cached version of your site.
Is there a better way to clear my cache?
Yah, most easy way is to use CTRL + F5 combination.
This works in most cases and order browser to reload CURRENT page, not from cach, but from the Internet

From the browser, how to make the web server refresh/invalidate a cached static-html-webpage?

PROBLEM:
Today, we modified a static html web page in a client's website -
we added a couple of images and modified the font. And FTPed the file to client's web server.
We realized we made a mistake with the font-size, corrected it, and FTPed the file again.
Even with a 100 refreshes, the website was displaying only the file (with wrong font) that we had FTPed the first time.
We FTPed the corrected file several times, but the file with the wrong font was the only file being served by the web server.
OUR GUESS:
We think that the web server cached the file that we had FTPed the first time, and is serving it back to us on subsequent requests even though the file had changed.
We tried the following techniques (but were unsuccessful):
We added a parameter to the querystring (?R=33343545)
We tried the technique suggested below - i.e. posting to the webpage in question, but got a "405 Method not allowed. The HTTP verb used to access this page is not allowed."
http://www.mnot.net/blog/2006/02/18/invalidation
Please advise if we were on the right path and if there is anything else that we can try in such situations ?
EDIT:
We would like to find out if there is a way (similar to the 2 methods above) to do it just from the browser..and not touch the settings on the webserver.