@anonymous-piwik-user opened this issue on October 23rd 2009

The export as image functionality does not work, at least not for the section Visitors - Overview - Evolution over the last days. The results is shown in attached document.

@anonymous-piwik-user commented on October 23rd 2009

Attachment: Screenshots Export as image.doc

@robocoder commented on September 21st 2010

Attachment: Proxy plugin 1014.patch

@robocoder commented on October 23rd 2009

Unless this is IE8, this feature is not available on earlier versions of Internet Explorer (i.e., lack support for data: pseudo-protocol).

@robocoder commented on September 1st 2010

Just got pinged on this. An alternative might be to somehow POST the data back to the server and have the server generate a regular image in response. e.g.,

// pseudo-code
$.ajax({
  type: 'POST',
  url: 'http://URL/?module=CoreHome&action=getImage',
  data: { 'nonce' : '__secret__', 'data' : '__imagedata__',
  success: function(src) {
    // add the image to the DOM
  },
  dataType: 'image/png'
});

Care needed to avoid introducing any security vulnerabilities, e.g., arbitrary file upload & execution, XSS reflection, etc.

@robocoder commented on September 7th 2010

It looks like greg already implemented this for UserCountryMap. We should be able to refactor this and make it available to the OFC charts as well.

@robocoder commented on September 20th 2010

I'm thinking of putting all the proxy stuff into its own module, eg Piwik_Proxy - getCss, getJs, getPieHtc - getImage

Can I move the misc/redirectUrl code here too?

@robocoder commented on September 20th 2010

Better yet, move to the CoreTheme plugin.

@mattab commented on September 20th 2010

Piwik_Proxy sounds good ; not sure about CoreTheme plugin, as this code would be shared by all themes? I still have to review your proposal about theming, will do in the next few days :)

@robocoder commented on September 22nd 2010

We can either have Piwik_CoreHome_Controller extend Piwik_Proxy_Controller, or change the URLs to use module=Proxy. (Ditto for UserCountryMap.)

@mattab commented on September 22nd 2010

By changing URLs, do you mean just the 'export as image' URLs and/or the getCSS/getJS? I think it would make sense...?

@robocoder commented on September 22nd 2010

Both.

@robocoder commented on September 25th 2010

(In [3175]) refs #1014 - move getCss, getJs, getHtc, and redirect to Proxy plugin; todo: exportImage (requires a change to open-flash-chart.swf and common.js)

@robocoder commented on September 25th 2010

(In [refs #1014 - typo in 3175)

@robocoder commented on September 28th 2010

(In [3190]) refs #1014

@robocoder commented on October 29th 2010

(In [3271]) refs #1014

@robocoder commented on October 29th 2010

(In [refs #1014 - revert 3271)

@robocoder commented on November 18th 2010

(In [3323]) refs #1711, refs #1014 - move plugin-specific logic out of Url.php to Proxy module; simplify code; re-org related tests

@mattab commented on November 24th 2010

Export as image works for me in dashboard and Visitors>Overview on FF and IE8 - should this bug be closed?

@robocoder commented on November 25th 2010

(In [3349]) refs #1014 - split UserCountryMap Controller into a separate file and call proxy methods for "export as image"

@robocoder commented on November 25th 2010

Closing for now... the change to common.js is more involved.

@robocoder commented on November 25th 2010

(In [3350]) refs #1014 - rename methods

This issue was closed on November 25th 2010
Powered by GitHub Issue Mirror