HI,

I am using highchart, and do all the settings as readme.txt file , but it showing me some black square (no chart displaying).

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

mail2jatingarg created an issue. See original summary.

jatinkumar1989’s picture

Category: Bug report » Support request
bmango’s picture

I started using the Charts module quite recently and had the same problem. In my case the problem was solved by adding a label to the field that was being used for the "Provides Data" setting in the chart settings. See if this works.

Otherwise I would recommend changing your view format to display as a table first and see if that works and then switching back to using the chart format.

jtoomer’s picture

I'm having the same issue. Anyone have any ideas?

ufku’s picture

Category: Support request » Bug report

It seems highchart.css is required:
The library definition in charts_highcharts.module must be like this:

/**
 * Implements hook_library().
 */
function charts_highcharts_library() {
  if ($highcharts_info = libraries_detect('highcharts')) {
    $library['highcharts'] = array(
      'title' => t('Highcharts library'),
      'website' => $highcharts_info['vendor url'],
      'version' => $highcharts_info['version'],
      'js' => array(
        array('data' => $highcharts_info['library path'] . '/js/highcharts.js', 'type' => 'file'),
      ),
      'css' => array(
        array('data' => $highcharts_info['library path'] . '/css/highcharts.css', 'type' => 'file'),
      ),
    );
  }
  $library['charts_highcharts'] = array(
    'title' => t('Highcharts integration'),
    'version' => '1.0',
    'js' => array(
      array('data' => drupal_get_path('module', 'charts_highcharts') . '/charts_highcharts.js', 'type' => 'file'),
    ),
    'dependencies' => array(
      array('charts_highcharts', 'highcharts'),
    ),
  );

  return $library;
}

No patch at this time, sorry.

elvisronn’s picture

Your copy of highcharts.js might be different from the cdn https://code.highcharts.com/highcharts.js. Replace the codes in your copy with that of the cdn. This should work fine.

tobiasb’s picture

Status: Active » Needs review
Related issues: +#2983227: Highcharts 6 showing black object instead
FileSize
640 bytes

Here is the patch for the changes.

borisson_’s picture

Version: 7.x-2.0-rc1 » 7.x-2.x-dev
Status: Needs review » Reviewed & tested by the community
Issue tags: -highcharts

Had the same issue with Highcharts JS v6.1.1 (2018-06-27). This patch resolved the issue.

  • andileco committed 9e7483d on 7.x-2.x authored by tobiasb
    Issue #2852754 by tobiasb, mail2jatingarg: Charts not showing
    
andileco’s picture

Status: Reviewed & tested by the community » Fixed
andileco’s picture

Status: Fixed » Closed (fixed)
borisson_’s picture

@andileco, there's no need to close these issues yourself. Drupal.org will close issues that are on fixed automatically after 2 weeks :)

kellyimagined’s picture

This issue is not fixed, even with the patch from #7 applied.
Latest CSS and JS grabbed from here https://code.highcharts.com/

Is this something that is being addressed?

The view has not changed, just charts using the highcharts library are now not showing, Google is.

andileco’s picture

Hi @kellyimagined, did you try the solution in #3? If that fixes it, please start a new issue.

kellyimagined’s picture

All set @andileco, thanks for the mention to go back to #3. I did end up needing to rebuild, but I am happy it worked.