Jump to content

Steps for troubleshooting script


NotionCommotion

Recommended Posts

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:

error_list.thumb.PNG.3315252771f2df9d50a5e8ecf75cf306.PNG

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).

directory_structure.PNG.7d292b2680471271cff578fdf60b67dd.PNG

Back to the errors, clicking the line number (i.e. 927, 3115, and 1), chrome blames apparently innocent line numbers.

error_927.PNG.1f9b05d87fbc1b4d9b496888a2215546.PNG

error_3115.thumb.PNG.19554844634b44862ed7ec80c6bd3df4.PNG

error_1.PNG.d89637033b16d78f557abd5ee833aa2e.PNG

What steps would you recommend taking to identify the cause and fix these errors?
 

Link to comment
Share on other sites

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?

Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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;
}

 

Link to comment
Share on other sites

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

  • Great Answer 1
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.