Hello,
Say I have a category field called "Custom_Name" and the Custom_Name have the same prefix for each category say "prefix1_" for each subcategories.
I have different prefixes for different top categories.
How to declare a variable where I can define the prafix and then remove it form Custom_Name field.
I have a global called "substitute" which replaces space with underscore:
sub {
my $action = $_[0];
if ($action eq "underscore") {$_[1] =~ tr/ /_/; return $_[1]; }
else { return "Invalid action passed..."; }
}then i call the global like this
how to modify this to achieve what in I need?
Thanks in advance.
Say I have a category field called "Custom_Name" and the Custom_Name have the same prefix for each category say "prefix1_" for each subcategories.
I have different prefixes for different top categories.
How to declare a variable where I can define the prafix and then remove it form Custom_Name field.
I have a global called "substitute" which replaces space with underscore:
Code:
sub {
my $action = $_[0];
if ($action eq "underscore") {$_[1] =~ tr/ /_/; return $_[1]; }
else { return "Invalid action passed..."; }
}
Code:
<%substitute('underscore',$Custom_Name)%>how to modify this to achieve what in I need?
Thanks in advance.