pepperstreet VIP
Total posts: 3,837
15 Mar 2012 09:26

Already posted a similar topic under Resources product. Since I had my first testdrive with Cobalt preview releases, i just wanted to make sure that my idea will make it into the final product ;-)

As far as I can see, most GUI images went into the Joomla/Media directory. And some are still in components folder.

PLEASE, could you make this more customizable and secure for updates?!

In most cases, I need to integrate the extensions appearance into a specific joomla template or corporate design. Besides templates, admin and user menus... the visual customization typically includes also:

  • filter icon

  • help tooltip icon

  • label icons

  • any other graphics i did not mention ;-)

In Resources, and the current Cobalt release it is not easy to keep this kind of modifications. A 100% make-over is overridden on any update. Auto updates are not usable... or have to be followed and tracked with a lot of manual work.

Ideas:

  • Put all needed image files in a save folder, which is not overriden by an update.

  • Put them in a logical folder structure with speakable names

  • maybe icon path parameters in configuration? So, one can re-direct to his own image sets.

Thanks for listening.

Last Modified: 11 Aug 2014


Sergey
Total posts: 13,748
15 Mar 2012 09:43

. A 100% make-over is overridden on any update.

Hmmm, not sure may be I did not understand your point, but it is very great concern for Resources and Cobalt to be able to customize and yet not to loose changes on update.

  1. You can copy template and it will not be overwritten.

  2. Add some images to image folders and use them. When you create new template set image path where you want. You can store your icons and images in any folder. And it will not be overridden.

. A 100% make-over is overridden on any update.

maybe icon path parameters in configuration? So, one can re-direct to his own image sets

If you want this approach, something like the same icon names but in different folder, it will require to rarefaction all templates. And I think it is too much for us right now. I think that possibility of customizing itself is enough for now. And I do not think it is difficult. You copy template, edit it and change all ion paths. That is it.


pepperstreet VIP
Total posts: 3,837
15 Mar 2012 10:31

Wow, quick answers ;-) Please, could you give an example...

How would i set the path to label icons or required/help tooltip icons near the fields?

Is there a difference with field loop and single field output?

PS: I did not have a deeper look into Cobalt templates and fields, yet. Maybe there are new possibilities? I hope on more and better development documentation ;-)


Sergey
Total posts: 13,748
16 Mar 2012 01:50

This is the code in line 81 of views/form/default_form_default.php

<?php if ($field->description):?>

    <span class="hasTip fright" title="<?php echo htmlspecialchars(trim($field->label, ':').'::' .($field->translateDescription ? JText::_($field->description) : $field->description), ENT_COMPAT, 'UTF-8');?>">

        <img style="cursor: help;" src="/<?php echo JURI::root()?>media/mint/icons/16/question-small-white.png" align="right">

    </span>

<?php endif;?>

You can see path to media/mint/icons/16/question-small-white.png. Just change it to any other picture in any other folder.


klox7 VIP
Total posts: 914
06 Aug 2014 07:56

Hello, how about compare icon. In template there is this code

<?php echo HTMLFormatHelper::compare($item, $this->submission_types[$item->type_id], $this->section);?>

But I guess this is controlled in com_cobalt/library/php/helpers/html.php?

How to use your custom image without copying over edit-diff.png in media folder?

NOTICE: I'm asking for Cobalt 8.


Sergey
Total posts: 13,748
06 Aug 2014 11:48

klox7 How to use your custom image without copying over edit-diff.png in media folder?

<img src="/<?php echo JURI::root(TRUE)?>/my/path/edit-diff.png" align="right">

klox7 VIP
Total posts: 914
06 Aug 2014 17:51

Sergey <img src="/<?php echo JURI::root(TRUE)?>/my/path/edit-diff.png" align="right">

This I know. So I have to combine it with

<?php echo HTMLFormatHelper::compare($item, $this->submission_types[$item->type_id], $this->section);?>

to be able to use compare function?


Sergey
Total posts: 13,748
07 Aug 2014 00:33
echo str_replace('media/mint/icons/16/edit-diff.png', 'my/path/pic.png', HTMLFormatHelper::compare($item, $this->submission_types[$item->type_id], $this->section));

klox7 VIP
Total posts: 914
11 Aug 2014 09:03

I just noticed a problem with this solution. When I add records to compare cart and the clean compare cart, old icons (default) are added to records that I added in compare.


Sergey
Total posts: 13,748
11 Aug 2014 11:06

Because it is related to AJAX also. Better just to change icon.

Powered by Cobalt