Easiest thing for you to do is to create a custom component that does
this. Something like
public class MyBookmarkableLink extends WebMarkupContainer {
private final Class pageClass;
private final PageParameters parameters;
...
protected void onComponentTag(final ComponentTag tag) {
Hi,
how to make a bookmarkable link in wicket to render as
?
I actually want to put a specific javascript in onclick(),
that should work without reloading a page.
Thanks in advance,
Alexey.
-
This SF.net email is sponsored
what do you mean by " am now injecting the root context into myWicket app by explicitly setting the root context."you call ApplicationSettings.setContextPath() ?that should work fine and that path is used for everything. (or we miss something)
that contextpath shouldn't already be in youre html fil
I thought I'd bring this up again, just in case...
> > how old is the snapshot you are using? do you have the source
> > attached? if so take a look at sourcecode for MarkupParserFactory, do
> > you see the prepender added in the constructors?
>
> I'm using 20060227-0200.
>
> Yes, I did notice
Just for the archives...
I haven't figured this out yet, but I'm going to do things differently
so will no longer look into this.
On Wed, 2006-03-01 at 16:43 +0900, David Leangen wrote:
> On Tue, 2006-02-28 at 23:32 -0800, Igor Vaynberg wrote:
> > if /context is your context path then yes.
>
On Tue, 2006-02-28 at 23:32 -0800, Igor Vaynberg wrote:
> if /context is your context path then yes.
Hmmm... Well, in that case, I'll try to get my local wicket to actually
build in Eclipse so I can set up Jetty Launcher with it and try to step
through to see why this isn't happening as I expect
if /context is your context path then yes.-IgorOn 2/28/06, David Leangen <[EMAIL PROTECTED]> wrote:
On Tue, 2006-02-28 at 22:05 -0800, Igor Vaynberg wrote:> how old is the snapshot you are using? do you have the source
> attached? if so take a look at sourcecode for MarkupParserFactory, do> you see
On Tue, 2006-02-28 at 22:05 -0800, Igor Vaynberg wrote:
> how old is the snapshot you are using? do you have the source
> attached? if so take a look at sourcecode for MarkupParserFactory, do
> you see the prepender added in the constructors?
I'm using 20060227-0200.
Yes, I did notice the Prepen
the prepending is done via PrependContextPathHandler class. this
handler was not enabled by default because it was experimental. as of a
recent 1.2 snapshot it is enabled by default.
how old is the snapshot you are using? do you have the source attached?
if so take a look at sourcecode for MarkupP
> Wait a second do you use wicket:id tags in the
>so when i see this:
>
> public Object getObject( final Component c )
>{
>if ( ContentPage.this.isLocaleJapan
> ese() )
>return "styles/main_jp.css";
>else
>retu
Wait a second do you use wicket:id tags in the and
Then you have to do it yourself!We don't touch urls generated by developer code.so when i see this:public Object getObject( final Component c ) { if ( ContentPage.this.isLocaleJapan
ese() ) return "styl
What test i do with the "/.temp/www" context path it works always.I tested in the the PrependContextPathHandlerTest we have in our unit test.And also when i do this in our FormInputApplication.init() method example:
getApplicationSettings().setContextPath("/.temp/www");Then the stylesheet is altere
On 2/27/06, David Leangen <[EMAIL PROTECTED]> wrote:
> hrm, maybe its a problem with our prepender. it does look like its> prepending the / but nothing after that, maybe the "." that is> screwing it up. try calling getApplicationSettings().setContextPath
> ("/.temp/www") in your application.init()
> hrm, maybe its a problem with our prepender. it does look like its
> prepending the / but nothing after that, maybe the "." that is
> screwing it up. try calling getApplicationSettings().setContextPath
> ("/.temp/www") in your application.init() method. if that works then i
> will assume its a p
Hello!
I just tried the latest snapshot (20060227-0200). Still the same
problem, unfortunately.
> what does youre html look like?
> If you have non absolute paths in src or href attributes of tags then
> they will be made absolute in the latest snapshots.
My (relevant) html looks like this:
hrm, maybe its a problem with our prepender. it does look like its prepending the / but nothing after that, maybe the "." that is screwing it up. try calling getApplicationSettings().setContextPath("/.temp/www") in your
application.init() method. if that works then i will assume its a problem in o
what does youre html look like?If you have non absolute paths in src or href attributes of tags then they will be made absolute in the latest snapshots.i don't have any compile errors in head so don't know why you have.
On 2/27/06, David Leangen <[EMAIL PROTECTED]> wrote:
Sorry, I deleted the last
Sorry, I deleted the last post to this thread by Johan, so the order is
messed up a bit...
Johan wrote something like:
> If you use the latest snapshot, Wicket takes care of
> resources...
I tried this, but unfortunately it does not work. My css and image files
are not prepended by the context
> > > Page(_xx).html:
> > > Take a look at this page!
> > Unfortunately, this is not acceptable. The author should
> > have no idea of context. The link must be relative to the
> > application "top" page.
> just make links like:
>
>
>
> wicket will make those links absolute.
You're right! I w
with the latest snapshots all urls that you define will be made absolute by wicketWe have to do this because of our mounting of pages.johanOn 2/26/06,
David Leangen <[EMAIL PROTECTED]> wrote:
> > > Page(_xx).html:> > > Take a look at !> > Unfortunately, this is not acceptable. The author should> >
just make links like:wicket will make those links absolute.johanOn 2/26/06, David Leangen
<[EMAIL PROTECTED]> wrote:I finally have some time to start looking into this some more...
> Why don't you just provide some bookmarkable links to your> template designer?>> MyApplication.java:> mountBookmark
I finally have some time to start looking into this some more...
> Why don't you just provide some bookmarkable links to your
> template designer?
>
> MyApplication.java:
> mountBookmarkablePage("/links/coolPage", CoolPage.class);
>
> Then its up to the web designer if he wants to include a link
22 matches
Mail list logo