asp.net core html not updating - c#

my html code:
<div class="header"></div>
<div class="tiles"></div>
<div class="list"></div>
<div class="footer"></div>
changed to:
<div class="header"></div>
<div class="content">
<div class="tiles"></div>
<div class="list"></div>
</div>
<div class="footer"></div>
I made a content div around tiles and list.
My problem is by doing that my html won't update in my browser.
and yes i already cleared my browser cache, I disabled caching in devtool.
I added no cache meta tag. I rebuild my solution, clean solution no luck. Whatever code i add or delete nothing happens. My css is updated not the html.
I tested it by just deleting my content and when I run my project I still had every content on my browser. What else can I do to fix this?

Related

Is it possible to give name to Quasar Uploader in <form>

I have a <form> where I am using Vue.js and Quasar, and submits in as a HTML form in asp .net core 3.1
The problem is when I am using Quasar Uploader (https://quasar.dev/vue-components/uploader).
The functionality works fine, but when I submit the form (post i C# and .net core).
I cant get the the file in the controller.
As you can see from this example: https://codepen.io/cbrown___/pen/GRZwpxw
When the Uploader is rendered it does not have the attribute name. From the example above you have this input:
<input tabindex="-1" type="file" title="" class="q-uploader__input overflow-hidden absolute-full">.
I guess that is why I cant get it from my Controller. How can I solve this when I am using .net Core 3.1 to submit this form?
And I see no good solutinos in letting people upload files through my API before the record is created.
Is it a option here I do not see?
EDIT:
The <input> is on the plus-icon. So by using inspect elements you should be able to see that no name occurs.
EXAMPLE CODE:
HTML
<div id="q-app">
<div class="q-pa-md">
<div class="q-gutter-sm row items-start">
<q-uploader
url="http://localhost:4444/upload"
style="max-width: 300px"
></q-uploader>
<q-uploader
url="http://localhost:4444/upload"
color="teal"
flat
bordered
style="max-width: 300px"
></q-uploader>
<q-uploader
url="http://localhost:4444/upload"
label="Upload files"
color="purple"
square
flat
bordered
style="max-width: 300px"
></q-uploader>
<q-uploader
url="http://localhost:4444/upload"
label="No thumbnails"
color="amber"
text-color="black"
no-thumbnails
style="max-width: 300px"
></q-uploader>
</div>
</div>
</div>
JS:
new Vue({
el: '#q-app'
})
If any body else need this I ended up with using this:
:name="'file_description[' + index + ']'"
That way each one got one name...and from another array I knew how many file_description it would be.

Prevent NavBar showing

I have a C# MVC application with a pretty-much standard Bootstrap display.
As usual the Navbar is provided by Shared\_Layout.cshtml.
However one of my pages will only be used for generating a PDF using an HTML/PDF converter, so I don't want the Navbar to appear.
Is there a way to prevent this for specific pages?
I realised all I had to do was to add a querystring parameter that I can check for in _Layout.cshtml, i.e.:
<body>
#if(Request.QueryString["noheader"] == null)
{
<div class="no-print navbar navbar-inverse navbar-fixed-top">
<div class="container">
<div class="navbar-header">
...

MVC #RenderPage not working

I am using Asp.net MVC. In the layout page I want to store footer in a file and call it using RenderPage. It looks that everything is OK but when I run the website I get this error:
this is the file tree for project
_Footer.cshtml is located in Shared Folder
content for _Footer.cshtml
<div id="copyrights">
<div class="container clearfix">
<div class="col_half">
</div>
</div>
</div><!-- #copyrights end -->
In ASP.NET MVC you can use
#Html.Partial("_Footer") or #{Html.RenderPartial("_Footer");}

HtmlAgilityPack reading HTML in a wrong way?

I have been using HAP for a pretty long time. And now I have a really simple question.
How to correctly load a webpage?
The reason I'm asking is because there is a website and a specific part in the formatting messes up with HAP:
<div class="like-bar">
<div class="g-bar"><div class="green-bar" style="width:55.47%"/></div></div>
<div class="like-descr">76 Likes, 61 Dislikes</div>
</div>
So the part I'm having the problem with is "style="width:55.47%"/></div></div>". So there is a closing tag for the g-bar class, a closing tag for the "green-bar" class, but the greenbar class by itself has the closing bracket (/>). As you could imagine, this screws up the whole formatting and makes it impossible to parse.
When I use inspect in any browser the "/>" tag is just not there. How can I figure out what writes it down? I download the page using the Load method from the HtmlWeb class.
Update #1
For some really strange reason, the following does not work:
<div class="like-bar">
<div class="g-bar">
<div class="green-bar" style="width:55.474452554745%"></div>
</div>
<div class="like-descr">
<span class="bold">76</span><span>Likes</span>, <span class="bold">61</span><span>Dislikes</span>
</div>
</div>
The last is not associated to the class like-bar, instead it links to a parent.
What's wrong with this?
Thank you for your attention!

Javascript Back Button Behavior

I have a site I'm building where one of my pages contains several tab-panes. Whenever the user clicks on one of these tab-panes it updates the browser's history and thus affects the browser's back button functionality in an undesirable way. I've searched around on this site, but everything I found was people wanting the browser to take the user back to the previous tab, which isn't what I want. I want the browser to take the user back to the previous page, not the previous tab on the same page, if that makes sense.
I assume there should be a simple way to do this, but I just can't find it. Seems like I'm kind of alone in this want of mine.
The site is built with aspx and visual studios mvc framework.
here is a small code sample.
<ul class="nav nav-tabs">
<li class="active">Tab1</li>
<li>Tab2</li>
<li>Tab3</li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="tab1">
</div>
<div class="tab-pane" id="tab2">
</div>
<div class="tab-pane" id="tab3">
</div>
</div>
this is a know issue
you will need to use the javsacript method window.location.replace(url);
using window.location.replace() the current page will not be saved in session history

Categories

Resources