-
Notifications
You must be signed in to change notification settings - Fork 102
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
HighCharts configuration missing. #1012
Comments
Forgetting something: I've tried using CDNs for Jquery, creating a fake meta name with attribute jQuery.js and repositioning title tag to bottom with no success. Thank you. |
Oops - you're right, the text is truncated. Weird - it looks as if adding the library should do the trick, so why did I (if I was the author) add the "and" fragment? As for the name-of-the-library bit: oops, again. You're right. It doesn't make sense to add jQuery twice. So that's clearly an issue to address. |
I've contacted the author of HighFaces, hoping to find a way to solve the issue together. |
Hi, I think there are multiple issues. First of all, please make sure you are using highfaces version 1.2. Then please paste the complete content of your head tag; it seems like you added a jsf tag (not html tag) which does not provide/contain a name attribute. (Which should be invalid). The detection checks the child components of the head tag to identify if one of them is loading jquery. Meta tags or other HTML Tags get handled differently in JSF, so they are not required to have a name tag. (You can validate this in the highfaces-showcase where also html tags are contained within h:head without name tag) Having that said, version 1.3 is already in progress and will contain an improved version of jquery detection plus context-parameter based deactivation method. Cheers |
I just looked up how BootsFaces detects jQuery. By default, it uses its own copy. Luckily, it matches the name pattern required by HighFaces, so it works fine. In your case, you'd have to rename your copy of jQuery. BTW, starting with BootsFaces 1.4.0, the bundled version of jQuery is jQuery-3.3.1. |
@bauerlive I'm using Highcharts v1.2. Below is my complete HEAD tag. Yes, I'm using jsf tags, but as I mentioned in my second comment above, I tested several configurations, one of which was to use plain HTML <script></script>, but it didn't work either (I don't see SCRIPT tag using name attribute, by the way); I even used this fake tag:
Thank for you interest in this issue. @stephanrauh I renamed jQuery as you suggest but it doesn't work. Thank you. |
@bytecode-seller As highfaces version 1.3 is not yet out, please do the following:
|
As side information: jQuery needs to be loaded before highfaces.js gets pulled in. This can only be assured, if you rely on JSF to sort and put the script tags by its internal logic. The more JavaScript libraries you load manually, the more likely it gets, that on the frontend side something gets messed up. So if you don't need specifically a newer version of jQuery, you should not even load this one manually, because most JSF libraries already bring a bundled one with them. |
I've done according to your recommendations: dropped comments, dropped my own jquery, dropped my own highcharts.js, dropped my own datatables.js, modified web.xml net.bootsfaces.get_jquery_from_cdn to false, and it does not work yet. java.lang.NullPointerException I've decided to step back from HighFaces wrapper library and use plain highcharts.js. It really needs more coding, but at least that's not like a NullPointerException out of my reach. I'll give HighFaces a try in next versions. Thank you all. HEAD TAG
WEB.XML
MY PROJECT LIBRARIES (JARS) ERROR
|
I suppose we can close this ticket now. |
What exactly is needed to integrate HighCharts into BootFaces?
I can't make it work.
Your documentation page about configuring Highcharts is truncated. It reads:
Add the what? When I try to replicate the example about boys and girls births, I receive an error:
I've analyzed a little the class org.highfaces.component.chart.ChartRenderer and the error is due to wrapper can't find Jquery because there's no 'name' attributes in HEAD or the attribute doesn't endsWith 'jquery.js' but with 'jquery-3.2.1.min.js'.
This is my HEAD tag:
Thank you so much.
The text was updated successfully, but these errors were encountered: