Post by Hoogun » Wed Sep 20, 2017 1:51 pm

Hi folks. I've had a problem with my image manager. Basically it works fine, but if I add other module like a blog, it works not properly. When I tried to add any image to article, then image manager doesn't appeared. Instead of it showing up this window. (see screenshot) Please help me replace it to my image manager window. Opencart 2.2
Image

Newbie

Posts

Joined
Wed Sep 06, 2017 8:42 pm

Post by paulfeakins » Wed Sep 20, 2017 6:29 pm

I expect it will only be the blog extension that breaks this and I expect it is a bug with that extension.

I suggest you contact the module developer.

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by Hoogun » Thu Sep 21, 2017 6:37 pm

I suppose that problem not in the particular module. Because all installed extensions have the same behavior. I think its a summernote issue. Why the same image button doesn't work properly in all other modules? Maybe somebody already solved this issue?

Newbie

Posts

Joined
Wed Sep 06, 2017 8:42 pm

Post by yodapt » Thu Sep 21, 2017 9:15 pm

Summernote image dialog can be extended with a custom plugin, so it seems possible to integrate both. I might work on something like that.

Opencart Developer - My Extension Showcase
Contact me at aeon.yoda@gmail.com


User avatar
Active Member

Posts

Joined
Fri Jun 17, 2011 6:39 pm


Post by Hoogun » Sun Sep 24, 2017 3:48 am

I solved this issue. It was easy than I thought.
For first you need to remove summernote code for requed module in .tpl files here: \admin\view\template\[module folder]. Remove code something like this:

Code: Select all

  <script type="text/javascript"><!--
<?php foreach ($languages as $language) { ?>
$('#description<?php echo $language['language_id']; ?>').summernote({
	height: 250,
	  toolbar: [
    ['style', ['style']], // no style button
    ['style', ['bold', 'italic', 'underline', 'strikethrough', 'superscript', 'subscript', 'clear']],
    ['fontsize', ['fontsize']],
	['fontname', ['fontname']],
    ['color', ['color']],
    ['para', ['ul', 'ol', 'paragraph']],
    ['height', ['height']], 
	['table', ['table']], // no table button
    ['insert', ['picture', 'link', 'video', 'hr']], // no insert buttons
	['codeview', ['fullscreen', 'codeview']] //no help button
  ]
});
<?php } ?>
//--></script> 
Then search code between tags <textarea>...</textarea>. Then change this

Code: Select all

<?php echo $language['language_id']; ?>" class="form-control">
to

Code: Select all

<?php echo $language['language_id']; ?>" class="form-control summernote">
Its all. After this image button can to open image manager window for any new installed extension.

Newbie

Posts

Joined
Wed Sep 06, 2017 8:42 pm
Who is online

Users browsing this forum: dparakhiya and 341 guests