Images not shown properly in ASP.NET MVC - asp.net

I am trying to use some images with ASP.NET MVC. I've created a folder to store them and then I've pulled them from the solution explorer to code.
View code :
<a asp-area="" asp-controller="Home" asp-action="Index" class="navbar-brand">
<img src="~/Images/Logo.png" width="125" height="74" class="img-responsive" />
<img src="~/Images/Logo.png" />
</a>
Code of the page when inspected on Google Chrome :
<img src="/Images/Logo.png" width="125" height="74" class="img-responsive">
When I run the application they appeared broken on the browser. I have checked the path, properties, and everything is correct, but I can't fix this.

you could trying using #Raw
<dd>
<img src="~/Images/#Html.Raw(Model.PhotoUrl)" alt="Image" style="width: 500px; height: 300px;"/>
</dd>

Just found the problem. I create a folder name "Images" in solution explorer to store all my images, but that was conflit with the forder "images" in the "CSS" folder. I move my image to the "image" folder in "CSS" folder and everything works perfect.

Related

Images not showing on Amp version

Images work on normal page but the amp-version the images doesn't show.
here is a HTML code of a picture, I use WordPress and upload via media library and insert:
<img class="aligncenter wp-image-312" src="http://mysiteexample.com/wp-content/uploads/2016/11/review-1024x768.jpg" alt="Stanley Review" width="256" height="192" />
"
Is there a script I need to insert or something for it to work on amp?
Thanks for your time, I appreciate it.
Use amp-img instead of img for the amp version of your site.
<a href="#">
<amp-img src="http://mysiteexample.com/wp-content/uploads/2016/11/review-1024x768.jpg" width="256" height="192" layout="responsive" alt="Stanley Review"></amp-img>
</a>

Image Could not be loaded - Wordpress issue

I am having issue on my wordpress website. Where I have gallery plugin and the images in that gallery showing this error message when you click on the image. In past those used to pop up when you click on it. But currently it show this error message. I think there is some js conflict please help me here. screenshot- here
webpage - http://www.marvelrealtors.com/residential-properties/izara/
image url is missing in anchor tag. please check.
<a href="#" class="poppup">
<img src="http://www.marvelrealtors.com/wp-content/uploads/2015/05/Izara-Dining-Room.jpg" title="Dining" alt="Dining" data-lazy-loaded="true" style="display: inline;"><noscript><img title="Dining" src="http://www.marvelrealtors.com/wp-content/uploads/2015/05/Izara-Dining-Room.jpg" alt="Dining"/></noscript>
</a>
Working script:
<a class="image-popup-no-margins boxed_shadow" href="http://www.marvelrealtors.com/wp-content/uploads/2015/06/Izara-site-plan.jpg" target="_self">
<img src="http://www.marvelrealtors.com/wp-content/uploads/2015/06/Izara-site-plan.jpg" class=" vc_box_border_grey attachment-full" alt="layout" data-lazy-loaded="true" style="display: inline;"><noscript><img src="http://www.marvelrealtors.com/wp-content/uploads/2015/06/Izara-site-plan.jpg" class=" vc_box_border_grey attachment-full" alt="layout" /></noscript>
</a>
The problem comes from file names, no accent, space or special character and it will work.

How can I add pagination to my site's gallery?

I'm trying to integrate CSS pagination into a thumbnail gallery I have set up on my site. So far, I haven't found any tutorials pointing to how to customize pagination into a existing script.
From what I see out there, there are a lots of great CSS pagination solutions. Here's a page with lots of pagination stylings (no plugins, integration seems to be very general so any will do). I've downloaded a few in hope that a tutorial directs me to what I want but have had no luck so far.
My code is taken from Pure CSS image gallery. I had a look at integrating Gallerific but found the instructions difficult, and so I'm looking for a pure CSS solution.
At first I wanted to used multiple div's for the same gallery, much like Gallerific, only to find JavaScript (or some kind of jQuery solution) would be needed to connect the links necessary for the gallery to work like that.
Currently, the gallery is contained within one div (the way it has to be in order to work). I'm looking at adding pagination just on the thumbs e.g. "...<a href="#prev01"><img src="images/img/thmbs/01.jpg" alt="" class="thumb" />
..."
And here for purpose of the post is my code so far:
<div id="gallerycenter">
<ul id="gallery">
<li>
<a href="#prev01"><img src="images/img/thmbs/01.jpg" alt="" class="thumb" />
<span><img src="images/img/01.jpg" id="prev01" class="showcase" alt="" /></span></a>
</li>
<li>
<a href="#prev02"><img src="images/img/thmbs/02.jpg" alt="" class="thumb" />
<span><img src="images/img/02.jpg" id="prev02" class="showcase" alt="" /></span></a>
</li>
<li>
<a href="#prev03"><img src="images/img/thmbs/03.jpg" alt="" class="thumb" />
<span><img src="images/img/03.jpg" id="prev03" class="showcase" alt="" /></span></a>
</li>
<li>
<a href="#prev04"><img src="images/img/thmbs/04.jpg" alt="" class="thumb" />
<span><img src="images/img/04.jpg" id="prev04" class="showcase" alt="" /></span></a>
</li>
<li>
<a href="#prev05"><img src="images/img/thmbs/05.jpg" alt="" class="thumb" />
<span><img src="images/img/05.jpg" id="prev05" class="showcase" alt="" /></span></a>
</li>
</ul>
</div>
The only thing I have thought of but haven't tried is changing the ".thumb" to ".pagination" in order to start the "pagination" in a class form but still, that doesn't give me enough to go on
Can anyone help me piece together the possibilities or confirm that I'm crazy and I'm asking way too much of CSS?
You've misunderstood the link you posted. It is providing style only, not functionality, because CSS does not provide this functionality. Pagination is not a matter of adding style to a page, it is achieved programatically, either server-side or in client-side JavaScript. You should pick an existing jQuery pagination plugin and use it, you will not find a solution which uses only CSS to provide pagination as that is fundamentally not what CSS is for.

<a href> with image is disable in Chrome

hey, i have a .net C# function thats write html image links code such as:
<img src="..." />
and show it by asp:literal,
it works fine in Explorer and Firefox but in chrome the clicking is disable,
any ideas?
example code:
<div class=\"whitebox\" style=\"width:500px;\">
<div style=\"float:left;\">
<a href=\"../reader/Default.aspx?u=4&t=2&sr=f-53D\">
<img width=\"75px\" height=\"75px\" src=\"http://www.Knu.com/main.jpg\" />
</a>
</div>
</div>
The only problem I can see with that is if you're somehow outputting it exactly like that, with the C# escaping included.

Html is being truncated on save in drupal (full html)

If I unput a certain piece html into my page, it seems to be truncating:
<div id="slideshow">
<img style="cursor: pointer;" src="files:img/slideshow/3.png" id="left_slide" alt=""/>
<img style="cursor: pointer;" src="files:img/slideshow/1.png" id="center_slide" alt=""/>
<img style="cursor: pointer;" src="files:img/slideshow/2.png" id="right_slide" alt=""/>
</div>
It all looks good in the preview, but when I save it it becomes:
<div id="slideshow">
<img style="cursor: pointer;" src="http://local.drupal.com/sites/default/files/img/slideshow/3.png" id="left_slide" alt="" />
</div>
I'm at a loss! I'm not using any nasty WYSIWYG editors and the input format is full html. The second code example indicates that I'm using the path filter module but I've also tried disabling that and resaving. It still truncates.
I'm using Drupal 6.19.
You certainly print the teaser only.
To publish to the front page the complete node Go to Administer > Content Management > Post Settings > Choose 'unlimited' from the 'length of trimmed post' select box.
You can also manually controlling the teaser break point by inserting:
<!--break-->
If you use a views you can control if you want to show the complete node or the teaser in the settings of the view.

Resources