If I open the symbolic link with PAINT, I can see the expected image. So it means that the symbolic link is working.
The only issue is when I load the image using Electron app in Windows.
.fullscreenBackground{
background-image: url("../myimage.png");
}
myimage.png points to /../src/logo.png.
And it works if I directly provide the path like below
.fullscreenBackground{
background-image: url("../../src/logo.png");
}
Also no warning on the console.
Related
I uploaded my own created personal site on Github (includes CSS and HTML only). The link doesn't open the site very well as my CSS contents doesn't get displayed but when I open the same file locally on my chrome browser it opens correctly.
Below I'm attaching the 2 screenshots of what it's like when I open.
1)With Github(Error while loading)
2)Locally opened using VScode(Correctly opened)
I was hoping that my uploaded file gets opened correctly like did in VScode so that I can share the link of my site.I am mentioning the link here too if anyone finds the fault then please help me rectify it.
https://dewansh28.github.io/PersonalSite/
I have developed an application using HTML 5. To make the application compatible with the mobile devices I have used cordova/phonegap.
Now the problem is that, the PDf files which is there inside the application is only getting downloaded, when clicked on the link. I need to get it opened in the browser, when clicked on the link. It works fine with the PC. But not with the mobile devices.
I stored the link to a variable and passed that variable to google. Now using some sort of services from google, the link is getting opened in the browser.
I tried installing inAppbrowser plugin also.
window.open(Furl, '_system', 'location=yes');
This was the line of code used, where Furl is the name of the variable, into which, the url address of the pdf file is passed.
This line of code works fine, when url address of a webpage is passed to the variable. But not with the pdf files.
Apart from that idea, is there any other solution for this problem?
Can someone help me out with this problem?
-Thank you
As stated already on a comment, it is possible on modern browser since they have in-built PDF viewer. This isn't the case for Android or iOS currently. What you could do is to convert the PDF to PNG image and then show that. There is a PDF2PNG plugin available for this purpose. Also, if you only need to support iOS 6 & 7, you can take a look at the PDF Viewer plugin.
I had created a IBM Worklight project and its working fine for android and IOS, but with wp8 it's not working.
All the local image files are added to HTML DOM by using id in the image tag and providing url to content property, but for wp8 i have to provide inline src to call the images.
My question is how to call local images in the same way through external css file in windows phone?
I had tried calling the image from root folder but its not working i.e., content:url("www/default/images/abc.png");
Windows Phone 8 file path handling differs than other environments. Your path should be relative. You can look at the multiple pages tutorial's sample project for special handling done for this purpose. Although you're done this in the HTML, so it's gonna be a bit of a problem...
By why not do this via CSS?
For example, if you have some DIV and you can want to give a background using an image that exists locally in the application's web resources, you can do this:
HTML:
<div id="test"></div>
CSS:
#test {
background-image:url("../images/icon.png");
height: 30px;
width: 30px;
display:inline-block;
}
I am new in Ubuntu, as well as using lampp, My problem is, after storing image in image folder of my apps, image is not showing in HTML file ( image not found ). localhost document root is /opt/lampp/htdocs/, and my root folder is f_21 if I use the following link
http://localhost/f_21/index.html // not works
But image showing works well if I use following link:
file:///opt/lampp/htdocs/f_21/index.html // but it works
Any idea ??
You should keep both image and index.html files under htdocs.
for you,place your index.html and image files under f_21 folder and update src attribute of img tag in your index.html
If the link to the image is an absolute path based on your file system with the file protocol, then you won't be able to load it when viewing the html page over http.
Chrome doesn't (I'm not sure about other browsers) allow loading local resources on a file requested with http.
If you're using chrome, you can press ctrl+shift+j to see the console, which will show any errors. You might see something like: Not allowed to load local resource.
The solution is to change the src of the image to be relative to the html page it's on.
hi i m not able to load an image in chrome using img src="E:\pic1.jpeg" when i run this code in internet explorer its working bt not in chrome . on the other hand when i give the name of image instead of path in src then its working ...
plz help ... regards Prabjot
Chrome probably doesn't handle file system paths (or at least not without using file://). Even if this did work, that link would only work on your local machine as the person browsing your website wouldn't have an image at that location.
You should be using URLs for your resources (i.e. images), not file paths.
Have you tried using file:// to prefix your image local path?