HTML Code with Image links are not displaying images - html

Im looking for a way to be able to display images in a html file.
I use excel vba to take the HTML code and save it into a .HTML file and it displays the text and formatting fine. But does not display any images. The HTML code does have links to images like this:
<h1><img src="**********/Image.png" alt="" /></h1>
I've tried saving as a .MHTML but this comes up blank, and i have tried saving in other formats such as word documents but they just fail.
Is there anything i am missing?
Any help would be greatly appreciated.

That HTML seems to be valid.
For example,
<h1><img src="https://en.wikipedia.org/static/images/project-logos/enwiki.png" alt="" /></h1>
works for me.
It's somewhat unclear what you are doing with Excel here, but is it maybe just that the paths to the images are invalid, maybe because they are relative?
Have you tried opening it in Chrome's F12 and looking for the problem there?

Related

Display GIF in html 5

Is there a way to display a gif in HTML 5?
I've tried this code, and it doesn't work (images work though)
<img src="loading.gif">
I've spent hours trying to find out how to do this, thanks!
The reference to your image is incomplete since your code itself is fine.
Your code reads as: the image is located at http://example.com/loading.gif.
You need to either put the complete url path (https://media.giphy.com/media/jUwpNzg9IcyrK/giphy.gif or use ellipses (../media/giphy.gif) to go back a directory.
<img src="https://media.giphy.com/media/jUwpNzg9IcyrK/giphy.gif">

HTML img tags won't work though the link is correct

HTML img tags won't work though the link is correct
I have been trying for a long time to solve this problem and I searched a lot of websites and tested everything but to no avail.
I just want to show the picture.
<img src='https://jdwel.com/image/teams/eng_newcastle_united.png' width="50px" height="50px" alt="This is an image"/>
Click here (https://i.stack.imgur.com/3r0du.png) to show the result of this code
The code seems to be fine. Could you add the console logs for this error.
Since you are getting a 403 error, it seems your request is getting blocked which comes when you access resource you do not have access to
Attributes height="50", width="50" need pixel values, without % sign. Additionally, use css to style the dimensions. Details here, explaining img tag. If still not working, image have have hot linking protected.

Base64 encode image in visual composer WordPress

I try to get a base64 in my img src like this: <img src="data:image/jpg;base64,etc..."/> into my WordPress website through the visual composer in text mode. It's all working fine when I save it but when I edit it again the src attribute is just gone. The image does get displayed but the code disappears when I try to edit it. When I update it without editing anything it just saves <img /> without anything in it. So no image is shown. This only happens when my src starts with the standard base64. It stays when I just throw in a URL. What is going wrong here and how do I fix this?
Edit:
I use text block element which I would like to keep this way cause Im using a json plugin.
When I inspect it, it removes the: image/jpg part.
Use Visual Composer backend editor and add the img src code through 'Raw HTML' element.
I tried replicating your issues using this encoded image code
https://jsfiddle.net/casiano/xadvz/
<img src="data:image/gif;base64"/>
but I never faced that issue.

HTML mail template - Embedded images don't show

I've been trying to make an HTML template to use in emails. I want to embed inline images from my computer. I'm using:
<img src="images/footer.png" alt="" width="100%" style="display: block;" />
However when I copy the template in the email, the images don't show up. I don't have that isue if instead of using an image from my computer I use an image from a web server. So apparently the imagen won't get attached to the email and that's why they don't show up. Is there any way I can get to use images from my local computer and send them with the email?
Let me explain what I want to do more in detail:
I Code a template in HTML
I display the template in a browser
and copy it.
I paste it in the email.Once the template is
in the email I edit it and add text, images, whatever I want.
Everytime I want to use it I just want to copy the template from
another email and edit it.
Any solutions?
Thanks in advance.
Couple things here:
Make sure your image isn't hosted on a local server; your audience will not be able to see it if it is.
I see you are using a relative file path. You need to use an absolute path. For example:
Instead of
<img src="/images/photo.gif">
You would code it like this:
<img src="http://www.website.com/email/images/photo.gif">

Whats the HTML Tidy Config value to put every tag on a new line?

im trying to html tidy my document
currently im' getting code like this though
<div class="ImageContainer">
<img width="740.953125" height="561" src="pages/channels_home.png" usemap="#map_channels_home" />
</div><map name="map_channels_home" id="map_channels_home">
</map>
Is there a configuration value to turn this on?
I've looked here: http://tidy.sourceforge.net/docs/quickref.html
but not sure which config value
I would recommend displaying it as viewed on firebug, with head body footer... close to left margin, and moving towords the right as you develop inside each div/span...
Doesn't really matter, it sould be nicely accessible if you need to change/modify your script. If you look at google's script every thing is on one line (browser speed maybe). Firebug is a browser plugin if you're wondering.