Re: extra 'onclick' is generated for an image wrapped by a link
This behavior is in 1.4-m3 and is new. I was running 1.4-m2 and a wicket:link around an a/img combo did the expected thing (see the current http://online.ddpoker.com/ for an example - the rss image links). I agree that this is wrong. -Doug Trent Larson wrote: I have the following plain HTML where I want an image to be a link to another Wicket-managed page: wicket:link ProductPage.html ../images/products_welcome.jpg /wicket:link The link for that page is generated fine, but then Wicket adds an 'onclick' event to the 'img' tag that takes the user directly to the image: wicket:link ?wicket:bookmarkablePage=:com.max.web.page.ProductPage ../images/products_welcome.jpg /wicket:link This seems absolutely wrong. The result is that a click on the image will take users to directly to that image; sometimes it will then continue on to the right (ProductPage) page, so users see the image by itself before going to the right page, but often it just stops at the image. There is no Java code associated with this. I get it in 1.4-rc1 (as well as 1.4-m3). What is happening, and how can I stop it from generating the 'onclick' javascript? Thanks! Trent -- View this message in context: http://www.nabble.com/extra-%27onclick%27-is-generated-for-an-image-wrapped-by-a-link-tp20980894p21195414.html Sent from the Wicket - User mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: extra 'onclick' is generated for an image wrapped by a link
This is not a real great idea for refactoring, etc, but it's your call. On Fri, Dec 12, 2008 at 5:12 PM, Trent Larson tr...@trentlarson.com wrote: BTW, I don't want our UI team to have to add a component every time they add a link, so I'll try to avoid Wicket links altogether and have them use raw links like ?wicket:bookmarkablePage=:Page (or maybe play with URL mounting). On Fri, Dec 12, 2008 at 11:23 AM, Igor Vaynberg igor.vaynb...@gmail.com wrote: dont use wicket:link, use bookmarkablepagelink component instead. -igor On Fri, Dec 12, 2008 at 10:19 AM, Trent Larson larsontr...@gmail.com wrote: I have the following plain HTML where I want an image to be a link to another Wicket-managed page: wicket:linka href=ProductPage.htmlimg src=../images/products_welcome.jpg border=0/a/wicket:link The link for that page is generated fine, but then Wicket adds an 'onclick' event to the 'img' tag that takes the user directly to the image: wicket:linka href=?wicket:bookmarkablePage=:com.max.web.page.ProductPageimg src=../images/products_welcome.jpg border=0 onclick=window.location.href='../images/products_welcome.jpg';return false;/a/wicket:link This seems absolutely wrong. The result is that a click on the image will take users to directly to that image; sometimes it will then continue on to the right (ProductPage) page, so users see the image by itself before going to the right page, but often it just stops at the image. There is no Java code associated with this. I get it in 1.4-rc1 (as well as 1.4-m3). What is happening, and how can I stop it from generating the 'onclick' javascript? Thanks! Trent - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org -- Jeremy Thomerson http://www.wickettraining.com
Re: extra 'onclick' is generated for an image wrapped by a link
OK. Thanks. And thanks for the quick response! I appreciate how responsive this mailing list has been. On Fri, Dec 12, 2008 at 11:23 AM, Igor Vaynberg igor.vaynb...@gmail.comwrote: dont use wicket:link, use bookmarkablepagelink component instead. -igor On Fri, Dec 12, 2008 at 10:19 AM, Trent Larson larsontr...@gmail.com wrote: I have the following plain HTML where I want an image to be a link to another Wicket-managed page: wicket:linka href=ProductPage.htmlimg src=../images/products_welcome.jpg border=0/a/wicket:link The link for that page is generated fine, but then Wicket adds an 'onclick' event to the 'img' tag that takes the user directly to the image: wicket:linka href=?wicket:bookmarkablePage=:com.max.web.page.ProductPageimg src=../images/products_welcome.jpg border=0 onclick=window.location.href='../images/products_welcome.jpg';return false;/a/wicket:link This seems absolutely wrong. The result is that a click on the image will take users to directly to that image; sometimes it will then continue on to the right (ProductPage) page, so users see the image by itself before going to the right page, but often it just stops at the image. There is no Java code associated with this. I get it in 1.4-rc1 (as well as 1.4-m3). What is happening, and how can I stop it from generating the 'onclick' javascript? Thanks! Trent - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: extra 'onclick' is generated for an image wrapped by a link
BTW, I don't want our UI team to have to add a component every time they add a link, so I'll try to avoid Wicket links altogether and have them use raw links like ?wicket:bookmarkablePage=:Page (or maybe play with URL mounting). On Fri, Dec 12, 2008 at 11:23 AM, Igor Vaynberg igor.vaynb...@gmail.comwrote: dont use wicket:link, use bookmarkablepagelink component instead. -igor On Fri, Dec 12, 2008 at 10:19 AM, Trent Larson larsontr...@gmail.com wrote: I have the following plain HTML where I want an image to be a link to another Wicket-managed page: wicket:linka href=ProductPage.htmlimg src=../images/products_welcome.jpg border=0/a/wicket:link The link for that page is generated fine, but then Wicket adds an 'onclick' event to the 'img' tag that takes the user directly to the image: wicket:linka href=?wicket:bookmarkablePage=:com.max.web.page.ProductPageimg src=../images/products_welcome.jpg border=0 onclick=window.location.href='../images/products_welcome.jpg';return false;/a/wicket:link This seems absolutely wrong. The result is that a click on the image will take users to directly to that image; sometimes it will then continue on to the right (ProductPage) page, so users see the image by itself before going to the right page, but often it just stops at the image. There is no Java code associated with this. I get it in 1.4-rc1 (as well as 1.4-m3). What is happening, and how can I stop it from generating the 'onclick' javascript? Thanks! Trent - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org
Re: extra 'onclick' is generated for an image wrapped by a link
see page mounting -igor On Fri, Dec 12, 2008 at 3:12 PM, Trent Larson tr...@trentlarson.com wrote: BTW, I don't want our UI team to have to add a component every time they add a link, so I'll try to avoid Wicket links altogether and have them use raw links like ?wicket:bookmarkablePage=:Page (or maybe play with URL mounting). On Fri, Dec 12, 2008 at 11:23 AM, Igor Vaynberg igor.vaynb...@gmail.comwrote: dont use wicket:link, use bookmarkablepagelink component instead. -igor On Fri, Dec 12, 2008 at 10:19 AM, Trent Larson larsontr...@gmail.com wrote: I have the following plain HTML where I want an image to be a link to another Wicket-managed page: wicket:linka href=ProductPage.htmlimg src=../images/products_welcome.jpg border=0/a/wicket:link The link for that page is generated fine, but then Wicket adds an 'onclick' event to the 'img' tag that takes the user directly to the image: wicket:linka href=?wicket:bookmarkablePage=:com.max.web.page.ProductPageimg src=../images/products_welcome.jpg border=0 onclick=window.location.href='../images/products_welcome.jpg';return false;/a/wicket:link This seems absolutely wrong. The result is that a click on the image will take users to directly to that image; sometimes it will then continue on to the right (ProductPage) page, so users see the image by itself before going to the right page, but often it just stops at the image. There is no Java code associated with this. I get it in 1.4-rc1 (as well as 1.4-m3). What is happening, and how can I stop it from generating the 'onclick' javascript? Thanks! Trent - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org - To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org