modifying the icon in multi-update page

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
keithh0427
User
Posts: 136

modifying the icon in multi-update page

Post by keithh0427 »

Hi,

I'm trying to change the edit icon in the multi-update page from the pencil to another glyph icon.

I've searched the forum and looked at the custom-action topics about changing the icon, but can't figure our how to translate that into the multi-update page.

Can somebody point me in the right direction?


mobhar
User
Posts: 11660

Post by mobhar »

Hi,

Did you see the related phrase in the .xml language files for that button caption? If so, then you may simply use "Language_Load" server event to change the phrase and its icon, too.


keithh0427
User
Posts: 136

Post by keithh0427 »

I have. But, I don't want to change the icon globally.

In the Page_Load function within the list page, I've tried:

$GLOBALS["Language"]->setPhraseClass("icon-edit", "glyphicon glyphicon-star ewIcon");
$GLOBALS["Language"]->setPhraseClass("icon-edit", "glyphicon-star ewIcon");
$GLOBALS["Language"]->setPhrase("icon-edit", "glyphicon-star ewIcon");

None of these appear to work.

I'm trying to change the edit icon only when I look at the list page for multi-update selection.

The "star" icon is appearing for the custom row action and I want to use that icon for selecting records to update as well.


mobhar
User
Posts: 11660

Post by mobhar »

As the code example shown in "Language_Load" server event, then you should use the phrase ID as the first param (not the icon name/id as you wrote above) in the first param of "setPhraseClass" method.


keithh0427
User
Posts: 136

Post by keithh0427 »

Here's how I solved it. Maybe there's a better way.

// Page Load event
function Page_Load() {
$GLOBALS["Language"]->setPhraseClass("UpdateSelectedLink", "glyphicon glyphicon-star ewIcon");
$GLOBALS["Language"]->setPhrase("UpdateSelectedLink", "Continue With Selected Records");
}


mobhar
User
Posts: 11660

Post by mobhar »

Or, you may simplify that code become:

Language()->setPhraseClass("UpdateSelectedLink", "glyphicon glyphicon-star ewIcon");
Language()->setPhrase("UpdateSelectedLink", "Continue With Selected Records");


Post Reply