NotionCommotion Posted August 18, 2019 Share Posted August 18, 2019 I am creating an add on to a 3rd party CMS called Concrete5. Normally, when I have client issues, I can trace them to the server and fix them, however, this not doing so well on these issues. The following errors are being displayed in Chrome console: Checking the server’s folder directory, it is true there is no concrete/fonts directory but there is a concrete/css/fonts directory with a couple of the missing files (but not glyphiconshalflings-regular.woff2). Back to the errors, clicking the line number (i.e. 927, 3115, and 1), chrome blames apparently innocent line numbers. What steps would you recommend taking to identify the cause and fix these errors? Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/ Share on other sites More sharing options...
requinix Posted August 18, 2019 Share Posted August 18, 2019 The line numbers are irrelevant. The problem is whatever CSS is referencing those fonts, and a simple search for "glyphicons" should find it quickly. Spoiler: concrete5 screwed up the path and filenames. Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569062 Share on other sites More sharing options...
NotionCommotion Posted August 18, 2019 Author Share Posted August 18, 2019 22 minutes ago, requinix said: The line numbers are irrelevant. The problem is whatever CSS is referencing those fonts, and a simple search for "glyphicons" should find it quickly. Spoiler: concrete5 screwed up the path and filenames. Simple search results in 32,774 matches! That being said, won't need to look at each and should be able to track down. Could you elaborate on concrete5 screwing up the path and filenames? Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569063 Share on other sites More sharing options...
requinix Posted August 18, 2019 Share Posted August 18, 2019 38 minutes ago, NotionCommotion said: Could you elaborate on concrete5 screwing up the path and filenames? Having already deleted the download, I remember seeing them in app.css. If you want to be more precise, search for "glyphicons-halflings-regular". Basically any instance of that will be wrong. Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569064 Share on other sites More sharing options...
NotionCommotion Posted August 18, 2019 Author Share Posted August 18, 2019 Yes, I too found them in app.css who's first half seems to be a modified version of Bootstrap v3.4.0. Modified being the addition of the .ccm-ui namespace and also some margins, colors, etc are slightly changed (maybe LESS or Sass related?). Both versions have the ../ before fonts so it looks for them at /concrete/css/../fonts/* instead of where they are located at /concrete/css/fonts/*. So, the cause of the error is identified which is great, but without just editing the file, not the cure. I expect there is some "concrete5" thing I need to do when creating a package (concrete5 speak for add-on) which surely is out of scope here. Thanks for getting me half way there. <link href="/concrete/css/app.css?ccm_nocache=ca17add95b11d1baf3d74fcd3fa4637fb02c14ba" rel="stylesheet" type="text/css" media="all"> @font-face { font-family:"Glyphicons Halflings";src:url("../fonts/glyphicons-halflings-regular.eot");src:url("../fonts/glyphicons-halflings-regular.eot?#iefix") format("embedded-opentype"),url("../fonts/glyphicons-halflings-regular.woff2") format("woff2"),url("../fonts/glyphicons-halflings-regular.woff") format("woff"),url("../fonts/glyphicons-halflings-regular.ttf") format("truetype"),url("../fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular") format("svg"); } .ccm-ui .glyphicon { position: relative; top: 1px; display: inline-block; font-family: "Glyphicons Halflings"; font-style: normal; font-weight: 400; line-height: 1; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569065 Share on other sites More sharing options...
requinix Posted August 18, 2019 Share Posted August 18, 2019 4 minutes ago, NotionCommotion said: So, the cause of the error is identified which is great, but without just editing the file, not the cure. I expect there is some "concrete5" thing I need to do when creating a package (concrete5 speak for add-on) which surely is out of scope here. I saw nothing in the documentation to explain this, and I'm confident that this is both concrete5's fault and something that they should fix. For you, a) Create a CSS file for overriding this kind of stuff, define a new font-family like "Glyphicons Halflings 2" with correct srcs, and override .ccm-ui .glyphicon and whatever else to use the corrected font-family b) Fix the concrete5 files directly 1 Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569066 Share on other sites More sharing options...
NotionCommotion Posted August 18, 2019 Author Share Posted August 18, 2019 Thanks requinix, Regarding documentation, much is no longer valid and applies to earlier versions. Ah, the joys of extending large 3rd party cms systems. Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569067 Share on other sites More sharing options...
kicken Posted August 18, 2019 Share Posted August 18, 2019 https://github.com/concrete5/concrete5/issues/7671 Apparently it was attempted to be fixed but is still goofed up. Could file another bug report on it if you wanted. Quote Link to comment https://forums.phpfreaks.com/topic/309105-steps-for-troubleshooting-script/#findComment-1569069 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.