This is a migrated thread and some comments may be shown as answers.

ImageBrowser: Make transport.thumbnailUrl and transport.imageUrl consistant.

1 Answer 63 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Sean McLellan
Top achievements
Rank 1
Sean McLellan asked on 06 Feb 2013, 07:45 PM
I want to use the ImageBrowser with services that perform the requested operations.. I've got my transport.read, transport.create, transport.destroy services created just fine and everything works.

However, the imageUrl and thumbnailUrl properties leave me baffled.


So transport.thumbnailUrl hard-codes a ?path={url} to whatever url you give it ... this seems like a major hack. I WANT to have a REST service and I need to supply additional query string parameters, but this implementation precludes doing so.

At least imageUrl lets me pass in a function or a parameterized string, but imageUrl ALWAYS tacks on the current relative path. I have the images stored in a DB, so doing so just adds needless weight.

Regardless, both these properties should have the same abilities as the create,read, and destroy -- let me control what is passed in explicitly.

1 Answer, 1 is accepted

Sort by
0
Rosen
Telerik team
answered on 07 Feb 2013, 09:53 AM
Hi Sean,

Indeed, your suggestion about the thumbnailUrl, seems reasonable improvement. We have added support for setting the thumbnailUrl option as function which will receive the current path and the image name. This will be available with the next internal build.

Regarding your question about imageUrl and thumbnailUrl, been different from create/read/destroy. This is due to the fact that create/read/destroy are executed via ajax, as opposite to the  imageUrl/thumbnailUrl which are set as src attribute of the img elements, thus served directly by the browser.

Greetings,
Rosen
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
General Discussions
Asked by
Sean McLellan
Top achievements
Rank 1
Answers by
Rosen
Telerik team
Share this question
or