Impossibile caricare la risorsa: il server ha risposto con uno stato di 404 (non trovato)

2022-07-29 10:30:24

Non riesco a risolvere il mio problema di collegamento. Potresti aiutare su questo per collegare CSS e file JS?

CSS:

<link  href="../Jquery/jquery.multiselect.css" rel="stylesheet"/>
<link  href="../Jquery/style.css" rel="stylesheet" />
<link  href="../Jquery/prettify.css" rel="stylesheet" />

JS:

<script  src="../Jquery/jquery.multiselect.js"></script>
<script  src="../Jquery/prettify.js"></script>

Errore:

Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/jquery.multiselect.css
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/style.css
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/prettify.css
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/jquery.multiselect.js
Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8080/RetailSmart/jsp/Jquery/prettify.js

Fai riferimento a questo link Struttura della directory.

inserisci qui la descrizione dell'immagine

- user3331535

Source
Risposta


89
  • I tuoi file non si trovano nella cartella jsp ecco perché non viene trovata. Devi tornare indietro di 1 cartella Prova questo:

    <script src="../../Jquery/prettify.js"></script>