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

Image Manager Thumbnail not showing.

3 Answers 288 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Mohammed Nazrul
Top achievements
Rank 1
Mohammed Nazrul asked on 26 Jun 2014, 07:09 PM
Hello , 

When i load image image loader of your Text Editor my existing image is not showing up.  I am sure that my file path is correct but the image Thumbnail is not showing properly.  

I used used  thumbnail  but is now showing our current images.  Please check my code and screenshot attache herewith. 

01.settingOptions: {
02.                                                    tools: [
03.                                                            "bold",
04.                                                            "italic",
05.                                                            "underline",
06.                                                            "strikethrough",
07.                                                            "justifyLeft",
08.                                                            "justifyCenter",
09.                                                            "justifyRight",
10.                                                            "justifyFull",
11.                                                            "insertUnorderedList",
12.                                                            "insertOrderedList",
13.                                                            "indent",
14.                                                            "outdent",
15.                                                            "createLink",
16.                                                            "unlink",
17.                                                            "insertImage",
18.                                                            "subscript",
19.                                                            "superscript",
20.                                                            "createTable",
21.                                                            "addRowAbove",
22.                                                            "addRowBelow",
23.                                                            "addColumnLeft",
24.                                                            "addColumnRight",
25.                                                            "deleteRow",
26.                                                            "deleteColumn",
27.                                                            "viewHtml",
28.                                                            "formatting",
29.                                                            "fontName",
30.                                                            "fontSize",
31.                                                            "foreColor",
32.                                                            "backColor"
33.                                                            ],
34.                                                    imageBrowser: {
35.                                                       messages: {
36.                                                        dropFilesHere: "Drop files here"
37.                                                       },
38.                                                       schema: {
39.                                                          data: function(response){
40.                                                              //alert(response.toSource());
41.                                                              return response.data;
42.                                                          },
43.                                                          total: 'total',
44.                                                         //model: settingObj.model
45.                                                      },
46.                                                      //path: "<?php echo $this->preferences_data['file_path_articles_image']; ?>",
47.                                                      transport: {
48.                                                            read: {
49.                                                                type: "POST",
50.                                                                dataType: "json",
51.                                                                url: "<?php echo $this->url( array('module' => 'Portfolio','controller' => 'frontend', 'action' => 'grid' ), 'adminrout',    true) ?>",
52.                                                                data: {
53.                                                                            preferences_table           :   true,
54.                                                                            table_name                  :   "articles_preferences",
55.                                                                            primary_id_field            :   "id",
56.                                                                            primary_id_field_value      :   "1",
57.                                                                            primary_file_field          :   "",
58.                                                                            file_content                :   "",
59.                                                                            file_path_field             :   "file_path_articles_image",
60.                                                                            file_path_articles_image    :   "<?php echo $this->preferences_data['file_path_articles_image']; ?>",
61.                                                                            file_extension_field        :   "file_type",
62.                                                                            file_max_size_field         :   "file_size_max"
63.                                                                        }
64.                                                            },
65.                                                            destroy: {
66.                                                                url: "/kendo-ui/service/ImageBrowser/Destroy",
67.                                                                type: "POST"
68.                                                            },
69.                                                            create: {
70.                                                                url: "/kendo-ui/service/ImageBrowser/Create",
71.                                                                type: "POST"
72.                                                            },
73.                                                             
74.thumbnailUrl: "<?php echo $this->serverUrl().$this->baseUrl().'/'.$this->preferences_data['file_path_articles_image']; ?>",


Now , please check the screenshot and I need your help how can we load the existing image to thumbnail ? 

3 Answers, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 30 Jun 2014, 02:35 PM
Hello Mohammed,

The provided code does not reveal the cause of the problem. Have you checked what is the generated thumbnailUrl? Is it correct? Are there thumbnail image requests generated? What is the server response? Have you tested opening a sample thumbnailUrl directly in the browser?

You can compare your implementation and server responses with the following demo:

http://demos.telerik.com/kendo-ui/editor/imagebrowser

And here is a single thumbnail request:

http://demos.telerik.com/kendo-ui/service/ImageBrowser/Thumbnail?path=aeroviewr.png

Regards,
Dimo
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Mohammed Nazrul
Top achievements
Rank 1
answered on 02 Jul 2014, 05:08 PM
Here is how our thumbnailUrl  is rendered grammatically:

thumbnailUrl: "<?php echo $this->serverUrl().$this->baseUrl().'/'.$this->preferences_data['file_path_articles_image']; ?>",


Output is  :   thumbnailUrl: "http://localhost/data/frontImages/articleImages/web.jpg"

Please advice where we are doing wrong ? 


0
Dimo
Telerik team
answered on 04 Jul 2014, 09:01 AM
Hi Mohammed,

Well, is the generated thumbnail URL correct or not? What happens when you try to open this URL directly in the browser?

http://localhost/data/frontImages/articleImages/web.jpg

Regards,
Dimo
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Editor
Asked by
Mohammed Nazrul
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Mohammed Nazrul
Top achievements
Rank 1
Share this question
or