make sure whatever ide/tools you use copies non java resources into
the compiled classpath.
-igor
On Mon, Apr 13, 2009 at 9:38 AM, Ryan LaHue <ryanlahue...@gmail.com> wrote:
> I'm having trouble getting ResourceReferences to work for some reason, and
> was hoping somebody could give me some pointers. I'm using wicket 1.4.
>
> As a simple test I added a new page and put a "test.png" image in the same
> directory in my project. My structure is like so:
> project
> |--src
> |----mypkg
> |------test
> |--------TestResource.java
> |--------test.png
> |--public_html
> |----images
> |------test.png
>
> Java class: mypkg.test.TestResource.java
> ...
> ResourceReference ref = new ResourceReference(TestResource.class,
> "test.png");
> System.out.println("Valid resource: " + (ref.getResource() != null));
> ...
>
> This always returns false. I also tried putting the "test.png" in my
> public_html/images directory but no luck. I don't seem to have any luck
> getting these Resources to load correctly, so I've had to resort to
> hardcoding my javascript references into my html files. Anybody have any
> suggestions? I've verified that all the files are being copied to my output
> classes folder.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org