I have CodeIgniter configured to store errors. Every time I refresh a page I get a new message in my logs ERROR on 2017-08-04 00:07:59 with message: 404 Page Not Found: Framework_assets/css. The page loads correctly with no errors (visible).
Both folders are valid, I'm not receiving any 404 errors in dev console (all css files are loading correctly).
I access all my scripts in my view like so:
<link href="<?php echo ASSETS_DIR; ?>/css/fileupload.css" rel="stylesheet">
where define('ASSETS_DIR', '/framework_assets');
I found this: https://forum.codeigniter.com/thread-65040.html but it really doesn't answer my question. For example, why am I only getting a not found for the css when I do the same to get my js files? <script type="text/javascript" src="<?php echo ASSETS_DIR; ?>/js/messaging.js"></script>
After hours I found this line at the end of my css:
/*# sourceMappingURL=toolkit-inverse.css.map */
Deleted it (the file didn't exist) and no more logs.
Related
One module in our Prestashop platform inserts the google link below:
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Poppins:300,regular,500,600,700,100,200,800,900%7CDM+Serif+Display:regular,italic&subset=latin%2Clatin-ext?ver=8739" type="text/css" media="all">
But the browser reports ERROR 404: But when I insert and check the URL into the browser manually - it works?
Does this kind of google link needs to be ref. to in a special way or does any other tags need to be added to it before it will work?
To be honest I'm not 100% sure how I got this right by click around in the dev. console. But this URL here works:
https://fonts.googleapis.com/css?family=Poppins:300,regular,500,600,700,100,200,800,900%7CDM+Serif+Display:regular,italic&subset=latin%2Clatin-ext?ver=7489
Good Evening.... I am getting error for CSS and JS file and showing in console.
Few are as below - Getting this error for 1 page only and for other pages all CSS and JS files are working fine.
While checking the error, i point out the url of 8000/mypagename/....plugin/
is that ok or did i done something wroung. ?
GET http://127.0.0.1:8000/viewBuffalo/plugins/datatables-bs4/css/dataTables.bootstrap4.min.css
net::ERR_ABORTED 404 (Not Found)
GET http://127.0.0.1:8000/viewBuffalo/plugins/datatablesbuttons/css/buttons.bootstrap4.min.css
net::ERR_ABORTED 404 (Not Found)
I tried to check the file location but they are ok and as mentioned other pages are working fine...
Thanks in Advance...
As per your Your explanation If you have added your css and js inside head tag, you should use asset() provided by laravel like below example.
<link rel="stylesheet" href="{{ asset('plugins/datatables-bs4/css/dataTables.bootstrap4.min.css') }}">
I consider your plugins folder is inside of public folder.
I've a problem with my website, the layout load properly (and CSS) but no JS and page in yield.
I've copy paste the layout of my other website, inclued tje JS and CSS file, I do not understand why it does not work while on other sites it's good..
Code for include the JS and CSS file: <script src="{{url('js/jquery.min.js')}}"></script>
As you can see, the page is empty, and this is not normal.
Image of error:
Ahh... ok.
I've forget to DL From:: into my project. Sorry
I had the same problem when I was creating a recent Laravel project however mine was narrowed down too 2 problems. 1 being the JS had an error and 2nd was the way I called it.
I fixed it by doing the following:
<script type="text/javascript" src="{!! asset('js/jquery.min.js') !!}"></script>
is there any reason for something to work in page inspector and not in real debug mode?
In particular I'm using fullcalendar.min.js (JQuery plugin) in some tab content and I see it very well in page inspector but when debug the calander is not shown..
in header:
<link rel="stylesheet" href="./../../Content/fullcalendar.css" type="text/css" media="all" />
<script src="./../../Scripts/js/fullcalendar.min.js"></script>
in body:
<section class="tab events-tab">
<section class="events-tab-inner">
<div id="calendar"></div>
</section>
</section>
in console of the web page loading I have the below errors (I'm not sure they are directly related to my calendar thing):
GET http://localhost:3516/SITE/css/images/star-off.png 404 (Not Found) jquery.min.js:2
Invalid App Id: Must be a number or numeric string representing the application id. all.js:56
event.returnValue is deprecated. Please use the standard event.preventDefault() instead. jquery.min.js:3
FB.getLoginStatus() called before calling FB.init(). all.js:56
GET http://localhost:3516/SITE/css/images/star-off.png 404 (Not Found) jquery.min.js:2
Based on your console output that you've included above, it seems that there are a few errors. Not sure why they would work in page inspector and not debug though. It seems like it should be breaking everywhere. Let's approach each error one by one:
1. Invalid Image Paths
It appears that you may be using jQuery UI for some features within your code. The jQuery UI suite contains images located in the /images directory when you download the .zip file that the CSS references as background-images. These images are expected to be nested on directory in from the location of the CSS file. For example,
[CSS Directory]
-> jquery-ui.min.css
[images]
-> star-off.png
-> ...
-> etc.
The only way to change this structure is to modify the relative urls within the minified jQuery UI CSS file.
2. Facebook JavaScript SDK error
I have never personally used the Facebook JavaScript SDK. However, that is what it appears you are using. From the error it sounds like you never initialize the Facebook object via FB.init() before you call FB.getLoginStatus(). Try this:
<script type="text/javascript">
/* Locate your FB.getLoginStatus() call and place FB.init() before it */
FB.init();
FB.getLoginStatus();
</script>
Other than that, you may need to refer to their documentation for how to properly initialize the FB object for use.
Hope this helps. Good luck and happy coding! :)
I'm trying to embed a pde made with processing into a vanilla html page:
Here is my code:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="application/javascript" src="processing-1.4.1.min.js"></script>
</head>
<body>
<canvas width="700" height="821" data-processing-sources="jailmap2012capacity.pde"></canvas>
</body>
</html>
When the page is loaded, nothing appears.
I'm not getting any errors showing in the console for Firefox, but I am getting an error in Chrome that says, "Uncaught TypeError: Cannot call method 'addListener' of undefined" for client.js on line 6, but I don't think this is related to the problem.
The processing pde renders correctly within the Processing IDE.
Ideas? Suggestions? Thoughts? Thanks!
EDIT: Changed "source" to "src" in script link.
SOLUTION:
It appears that the default .pde produced in the Processing IDE does not include preloading tags necessary for use on the web.
For reference: http://processingjs.org/reference/preload/
Image and fonts will need to be preloaded on the very first line of the .pde, like so:
/* #pjs preload="path/image_1.gif, path/image_2.gif"; font="path/font_1.eof, path/font_2.eof"; */
javascript is not "application/javascript", it's "text/javascript", and if you're using , leave off the type. It's not necessary. On which note: add at the top. With that covered, if running that using localhost or online and that doesn't fix things (you cannot reliably run from file:/// unless you tell your browser to allow file XHR from file), check your console log, and report back what the errors are.