Chrome doesn't download archive files(zip) - vue.js

I'm working on a Vue.js project where users can download any files. Everything works fine, but for some reason, chrome doesn't download jar/zip files. There are any errors in chrome console. Moreover, it works on my local machine and doesn't work on production server. Here is vue.js code:
<a
:href="file.path"
target="_blank"
class="icon-link block q-pr-xs"
>
<q-icon name="get_app" size="sm"></q-icon>
</a>
and generated html
<a data-v-52d0018a=""
href="http://myserver.com:9000/portal-fileuploader/static/file.rar"
target="_blank"
class="icon-link block q-pr-xs">
<i data-v-52d0018a=""
aria-hidden="true"
role="presentation"
class="material-icons q-icon notranslate">
get_app
</i>
</a>
I don't even know the direction of research, so will be grateful for any ideas.

Starting from Chrome 83 version, browser blocks downloading insecure files on HTTPS.
link: https://www.chromestatus.com/feature/5691978677223424

Related

Nuxt js static pages relative URL change my link button

I am working on some static pages using Nuxt.js (MPA). Whenever I run the generate command, all URLs start from page, i.e /customer/. For example, my structure is:
pages
|customer
|new
- index.vue
- index.vue
And in index.vue I have linked to customer/new page as:
<nuxt-link to="customer/new"> <b-button class="btn-sm btn-success" >nuevo</b-button></nuxt-link>
all works fine if I use:
npm run dev
But if I use:
npm run generate
the link in the button link change to /customer/customer/new instead of /customer/new.
Thank you.
Your link have to be relative to the base URL of your app, see https://nuxtjs.org/api/configuration-router#base
So to fix your issue, declare your link with a starting slash as follows:
<nuxt-link to="/customer/new"> <b-button class="btn-sm btn-success" >nuevo</b-button></nuxt-link>

VueJS Image Tag Source is not working, how can i fix it?

I have the following img tag :
<img class="logo" src="../../assets/logo/logo_blue.png">
project structure
I don't know why but I only get the following error message:
GET http://localhost:8080/assets/logo/logo_blue.png 404 (Not Found)
try <img class="logo" src="#/assets/logo/logo_blue.png">
here '#' refers to root directory
will this work?
<img class="logo" src="./assets/logo/logo_blue.png">
I believe the path to that image entirely depends on the relative path between the page and image at deployment time. If you're not using HTML5 history mode, this ./assets/ prefix should always work.

Electron doesn't render any html after an select box

I have a basic html form with Angular JS.
<div class="form-control" id="alarm">
<select ng-model="vm.clock.alarm" ng-options="option.title for option in vm.alarms track by option.url"/>
</div>
This runs fine in a chrome browser window. However, when I run this inside of an electron app, the select box renders and functions fine, but no html is rendered after it. There are no javascript errors. When I inspect the html, there is no html after the select element in the dom. Why is electron not rendering the html just like a chrome browser?
I am using the latest version of electron, chrome, and 1.4.8 of angular.
The issues was with the select option and not having a closing </select> tag. Must be a bug in electron or electron's chromium version.
<div class="form-control" id="alarm">
<select ng-model="vm.clock.alarm" ng-options="option.title for option in vm.alarms track by option.url">
</select>
</div>
works

Symfony2 in subdirectory Alias, assets bundle not working

I'm trying to run Symfony2 application from a Apache alias /example-site/
The issue is that some of the assets get prefixed with /example-site/bundles/... while some directly start with /bundles.. and do not include the prefix.
What is the cause?
I have found that the problem was the following:
I was using asset command like this (note the / at the beggining):
<img src="{{ asset('/bundles/frontend/images/logo.png') }}" alt="">
Changed it to this solved the problem (removing / from beggining):
<img src="{{ asset('bundles/frontend/images/logo.png') }}" alt="">
So hope maybe helps someone not to lose hours looking for a solution.

Apache-Solr: JSP support not configured

I'm using apache-solr from bitnami I downloaded a week ago. Everything is going fine about indexing and searching, but I can't execute jsp files.
When I try to open main.jsp, the file isn't executed, the browser only shows the codes I wrote on main.jsp. Here's the codes on main.jsp I got from a tutorial website:
<html>
<head>
<title>Using GET and POST Method to Read Form Data</title>
</head>
<body>
<center>
<h1>Using GET Method to Read Form Data</h1>
<ul>
<li><p><b>First Name:</b>
<%= request.getParameter("first_name")%>
</p></li>
<li><p><b>Last Name:</b>
<%= request.getParameter("last_name")%>
</p></li>
</ul>
</body>
</html>
And then, when I try to open /solr/admin/stats.jsp, it says:
>HTTP ERROR 500
>
>Problem accessing /solr/admin/stats.jsp. Reason:
>
> JSP support not configured
>
>Powered by Jetty://
So, then I tried to configure the JSP support by typing:
>$ java -jar jetty.jar OPTIONS=Server,jsp
in Cygwin. But it says:
>Error: Unable to access jarfile jetty.jar
I've tried to add this snippet in jetty.xml:
<Call class="java.lang.System" name="setProperty">
<Arg>org.apache.jasper.compiler.disablejsr199</Arg>
<Arg>true</Arg>
</Call>
And after restarting the apache and solr, it doesn't resolving my problem, either. I want to try adding this snippet to start.ini:
>-Dorg.apache.jasper.compiler.disablejsr199=true
But, I can't find start.ini.
Please help me.