• Register
0 votes
522 views

Problem :

I am unable to solve my link problem. Can anybody help on to this to link the CSS and JS File?

I am facing below error :

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

 

6 5 3
7,540 points

Please log in or register to answer this question.

1 Answer

0 votes

Solution :

Please note your failing URL:

Failed ... http://localhost:8080/RetailSmart/jsp/Jquery/jquery.multiselect.css

Now you need to examine one of your links:

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

Here "../" is a shorthand for "The containing directory", or a "Up one directory". This is the relative URL. And I guess, you have the file in /jsp/<somefolder>/ which contains a <link /> and <style /> elements.

So I recommend you to use an absolute URL as below:

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

The reason behind using the absolute url is that I'm guessing that your links are contained in some of the common file and if you try to correct your relative paths by adding the second "../", then you may break any files contained in the /jsp.

9 7 4
38,600 points

Related questions

0 votes
0 answers 31 views
0 votes
1 answer 23 views
23 views
Problem: When I try to upgrade my database from Mvc-AngularJs to wcf-Rest, I get an error like Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:9706/EmployeeService.svc/UpdatexyzData/Update/but with the same ur when I try to get ... : { 'Accept': 'application/json', 'Content-Type': 'application/x-www-form-urlencoded ;charset=utf-8' } }) return ss; }
asked Jan 24 sasha 16.2k points
0 votes
1 answer 4 views
4 views
Problem: What are my options for resolving this problem &ldquo;Failed to load resource: the server responded with a status of 405 (method not allowed)&rdquo;?
asked Mar 30 tuhin1 48.9k points
0 votes
1 answer 8 views
8 views
Problem : why this is still happining : Failed to load resource: the server responded with a status of 500 (internal server error).
asked Mar 6 Wafa Abu Yousef 6.1k points
0 votes
1 answer 3.2K views
3.2K views
Problem : I want to send a call using ajax but in Chrome getting following error Failed to load resource: the server responded with a status of 500 (internal server error) But for firefox getting no error. I also tried to record the ajax call in firebug but there is no call request in ... function (msg) { }, error: function (xhr, status, error) { alert(error.responseTextss); } }); }); }); }); }
asked Nov 22, 2019 peterlaw 6.9k points
0 votes
1 answer 1 view
1 view
Problem: As I mentioned in my previous query, I'm having difficulties with my learning; I've tried searching the web but haven't been able to find adequate information; could you assist me in continuing my project?
asked Mar 30 tuhin1 48.9k points
0 votes
1 answer 6 views
6 views
Problem: I get a whole bunch of following error for the front-end resources:Failed to load resource: the server responded with a status of 401.The website launches just fine when using vs 2012. Does anyone know what could be going wrong?
asked 1 day ago Humaira ahmed 15.1k points
0 votes
1 answer 2K views
2K views
Problem : I am facing the below error: Failed to load resource: the server responded with a status of 401 (Unauthorized) http://localhost/App/AngularJS/angular.min.js My project works fine on the localhost. But when I try to run it on the IIS (7.5) I often face ... read/write/modify access for the "IUSR" & "IIS_ISURS" users of my whole project. But still I am facing the same exception on my IIS.
asked Dec 24, 2019 alecxe 7.5k points
0 votes
1 answer 1 view
1 view
Problem: I'll make a submission for a response to my question. Please, I have searched the internet but have not found any useful material, and I am now having trouble continuing my studies.
asked Mar 30 tuhin1 48.9k points
0 votes
1 answer 3 views
3 views
Problem: I'm trying to send a call using Ajax but in Chrome it is a rising error: The server responded with a status of 500 Thanks
asked Mar 20 ummesalma 25.2k points