please take a look , pictures cannot be loaded
[link]http://markizasklep.website.pl/altea/agency-index.html
when i start website at localhost there is everything ok, but when i start from my ftp server i think JavaScript doesn't work. I've checked size of paths (jpg - JPG , etc.) and it is not a reason i think. Have You got some ideas ?
To edit file i am using Dreamweaver ,maybe it is important ;)
If you open the developer tools e.g. in chrome you will see that the browser doesn't find at least two files: prettyPhoto.css and jquery.prettyPhoto.js.
Try uploading them.
First: Next time provide smaller sample :) and second You give 404 for jquery.prettyPhoto.js so reason is probably that you have this file on localhost but on on server.
Related
I'm suddenly getting a 404 error on the file undefinedpageWebRequest.js file my website tries to load. I have no idea what the .js is for, why the 404 is showing up (I didn't delete any files from FTP?) and I also can't find anything about the file on Google.
Also when I run my page through Google Mobile tool I get about 6 errors. How can I go around and fix this? I have no idea where to begin in the first place.
https://search.google.com/search-console/mobile-friendly?hl=nl&id=FjRctNhGZy3ybi6o1aAmug&view=fetch-info
Website URL: www.melvinosenga.nl/home
The .js file your webpage is loading is the following one:
https://www.smartsuppchat.com/loader.js
And I guess it is a requirement for a plugin you have installed in your Wordpress site, which is most likely dead.
If you are not using the plugin you should uninstall it, and if it doesn't work you can search for the line where it is called in the headers and remove it by-hand(not very neat, I would do this as a last option).
In the other errors you have there is a Image error and some missing fonts, you should check that and refill the fonts that are missing.
Let me know if I can help you in any of this procedures.
So, i was doing a link to download an image from a data url(a LARGE one):
<a download='fileName' href="data:image/png;base64,/9j/4WSsRX...">something</a>
However, whenever i try to click in that link i receive an error telling me some net problems.
I have make a fiddle test, but its LARGE(15mb of text) and it will take sometime to load:
https://jsfiddle.net/jjydp1ek/
As the jsfiddle is hard to load, i added a file in mediafire:
http://www.mediafire.com/download/p85y1g442ne9v6m/new++7.html
The test is an image with the same data url value as the link, the image is visible, however i see that the option to open image in a new tab on chrome isn't working.
I do it with canvas in ie 11 and is failing too
Questions:
It is ever possible to make it work with the download link as it is now?
Is there a limit size with the data url to download a file, which is?
How do i do to make the user able to download that image?
Also, ask questions here, or correct any error in the text you see if you think its not understandable.
Thanks.
I have a 70Mb broadband and a powerhouse of a PC and that JS fiddle won't even open.
I don't think it's feasible to have a 15MB encoded string, since that has to be downloaded onto the page each time on every visit. I would try the following:
Optimise the image, you could incorporate gulp-imagemin if you have/want to have Gulp for a build system. I think there are alternatives for Grunt if you wanted to go that way.
Store the file on the server and just place a link to the path, this is the preferred solution.
In response to your questions
The limit:
Length limitations
Although Mozilla supports data URIs of essentially
unlimited length, browsers are not required to support any particular
maximum length of data. For example, the Opera 11 browser limits data
URIs to around 65000 characters.
Source: data URIs - MDN
Downloading
The above suggestion on optimising the image as small as you can get without losing quality if that's a concern. Try it then. If not, it's not a problem to give the user a link to the image / display it on the page. The user can right click and save.
Note
By the time I finished writing this response JSFiddle timed out.
I inherited a website, I'm trying to serve its content over https, but when I do so I get an error that this "content" is being delivered insecurely. The certificate and all that good stuff is set up correctly.
<script type="text/javascript" src="https://domain.com/?dynamic=js"></script>
This doesn't seem to actually reference a file. I've googled but can't find anything to lead me in the right direction. Can anyone provide some insight, or better yet explain why this leads to the security problem?
Yes, it is valid so long as https://domain.com/?dynamic=js generates a javascript file. See this page for more info on dynamic files:
http://www.dynamicdrive.com/forums/showthread.php?21617-Dynamic-external-js-scripts-and-css-stylesheets-with-PHP
If you are running under secure connection (https) then all the resources in your domain have to be also serving via https - like images etc...
check to see if some image is using http: and not https
There's no problem with the script-tag. You don't actually need a .js-extension for it to be valid, as long as it returns JavaScript the browser will be happy.
Also, this line has nothing to do with the HTTPS-error you're getting. You should make sure that ALL the content linked on that page is delivered through HTTPS
Make sure ALL of the assets on the page are served up with relative paths. Images. css. scripts, etc.. Then they will load no matter if you are on https or not.
Relative = "/images/test.jpg" instead of "http://test.com/images/test.jpg"
Also can do Protocol relative url : "//test.com/images/test.jpg" (Thanks to commenter)
Im trying to open a .docx File like Sharepoint does.
I've set up an apache2 web server such as the webdav part.
I know that it works with the following small javascript Code:
var obj = new ActiveXObject('SharePoint.OpenDocuments.3');
But when I use that piece of code I've got the Problem that it opens the .docx with the specified edit bar in Word, but if I click on edit the document stays in read only mode.
What could be the problem ?
Below you find my apache/webdav config part.
Another question is, that this piece of code will not work in FF because of the ActiveXObject, has anybody any idea what I could do that it also works in FF ?
Beacause we have already a big application for wich im trying to implement this, it isn't an opinion for us to switch the whole application to sharepoint.
apache 2 conf:
DavLockDB WebDAV/Locks
Directory Uploads
Dav on
ForceType text/plain
AuthType Basic
AuthName "Mein WebDAV"
AuthUserFile C:\Users
Require valid-user
AllowOverride None
Options Indexes
Sincerly
k3n0b1
Solved!
The problem was that my WebDAV Folder was in the same structure as the http docs.
I think it was that, because when i defined another Folder outside of the http docs path it started to work.
All you need is the small piece of javascript:
var obj = new ActiveXObject('SharePoint.OpenDocuments.3');
obj.EditDocument('https://localhost/uploads/****.docx');
and a correct configured webdav in apache2.
Now I just have to handle how it works in ff, chrome, etc.
I need to know how to get full path from fileupload using javascript,
I tried using the following coding but of no use
<input type="file" id="picField" onchange="preview(this)">
<script type="text/javascript">
function preview(test){
var source=test.value;
alert(source);
}
</script>
but in the alert message, i am getting only
Filename.extension
I am not getting full path, but it is showing full path in File Upload box please help how to solve this problem
Thanks
This is a browser security restriction, in modern browsers you cannot get the full client file-system path of the selected file, nor set a path programmatically...
Maybe for security reason, javascript doesn't allow this to happen. And if you come to think of it, Server side pages cannot access your local files. Not that I have a solution for your question.
Actually, there is some kind of solution.
Albeit, it will help only if you can run Electron desktop app on local machine: https://stackoverflow.com/a/59990858/9390914