[Users] "TypeError: scale is undefined" from PrintPage

Luís de Sousa luis.a.de.sousa at gmail.com
Mon Jul 1 11:39:05 CEST 2013


Hello again, another developer told me that the PrintProvider project has
issues with the GET method. I changed it to POST but I'm still the error at
the same place in PrintPage.js.

Any insights are welcome. Thank you,

Luís


On 25 June 2013 11:23, Luís de Sousa <luis.a.de.sousa at gmail.com> wrote:

> Hello everyone,
>
> I'm trying to create some basic print functionality with the code below.
> Whenever the printView is called the fit function is returning back the
> error in the subject. This is what I get with Firebug:
>
> TypeError: scale is undefined
>
> var s = scale.get("value");
>
> PrintPage.js (line 298)
>
>
> Is this a bug or a misconfiguration of some sorts? Thank you,
>
> Luís
>
>
> ////////////////////////////////////////////////////////////////////////////////////////////////////////
>
> printProvider = new GeoExt.data.PrintProvider({
> url: "http://localhost:8080/print2.0",
>     method: "GET",
>     customParams: {
>         mapTitle: "Printing Demo",
>         comment: "This is a simple map printed from GeoExt."
>     }
> });
>
> printPage = new GeoExt.data.PrintPage({
>     printProvider: printProvider
> });
>
> printView = function() {
> printPage.fit(mapPanel, true);
>  printProvider.print(mapPanel, printPage, mainView.items[2]);
> };
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20130701/511fa0dd/attachment.htm 


More information about the Users mailing list