Thanks Andrea, 

Your small observation was important. After moving the code into the 
onInitialize method everything started working. The url produced is 
./resource/org.apache.wicket.Application/pdfProducer and not  . 
./resource/org.apache.wicket.Application/pdfProducer. 

I also test the wicket-bootstrap theory, but that does not seem to be involved.

I will use this fix.  Since this works should I still open a JIRA issue?

Thanks again,

Bruce

-----Original Message-----
From: Andrea Del Bene [mailto:an.delb...@gmail.com] 
Sent: Sunday, March 15, 2015 10:00 AM
To: users@wicket.apache.org
Subject: Re: PDF viewed in panel via ResourceReference works in 6.12 but not in 
6.13

Just a small observation that might help. Move code from PdfViewer contructor 
to onInitialize. This makes URL generation safer although it doesn't explain 
why your code worked until 6.12.0.
> I guess it depends on the mount path of your page.
> Most probably it is /wicket/bookmarkable/...
> On Mar 14, 2015 7:37 PM, "Bruce Lombardi" <brlom...@gmail.com> wrote:
>
>> Interesting,
>>
>> When I run your code I see that the url is as you say:
>>
>> ./wicket/resource/org.apache.wicket.Application/pdfProducer
>>
>> Whereas in my working code (wicket version 6.12) it is:
>>
>> ./resource/org.apache.wicket.Application/pdfProducer
>>
>> And  in my non-working code (wicket versions 6.13 - 6.19) it is:
>>
>> ../resource/org.apache.wicket.Application/pdfProducer
>>
>> If I remove the first dot from the url with the debuggerthen run from 
>> there the pdf appears as it should.
>>
>> I wonder why they are different in the two projects and why I'm getting ..
>> with later versions.
>>
>> I'm also wondering if there is another library that is somehow 
>> incompatible with later versions of Wicket.
>>
>> I think the only library we use that interacts with Wicket is wicket 
>> bootstrap  - currently as below (but I've tried other version):
>>                  <dependency>
>>                          <groupId>de.agilecoders.wicket</groupId>
>>                          <artifactId>wicket-bootstrap-core</artifactId>
>>                          <version>0.9.8</version>
>>                  </dependency>
>>
>>                  <dependency>
>>                          <groupId>de.agilecoders.wicket</groupId>
>>
>> <artifactId>wicket-bootstrap-extensions</artifactId>
>>                          <version>0.9.8</version>
>>                  </dependency>
>>
>> I will add these dependencies to your quickstart and see if it makes 
>> a difference.
>>
>> Bruce
>>
>>



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org

Reply via email to