Support Forums

Support Offline : Mon - Fri / 10am - 6pm (GMT +6)

Your Time: Our Time:

SpType Icon

Featured Lock Resolved Issue
Hey. Before SPPB 2, you could use your custom field type for example the administrator \ components \ com_sppagebuilder \ builder \ types \ select.php
Now SPPB 3, there is no such possibility how to write the custom type of a field?
What's wrong with the code?

<?php
class SpTypeMenuitems{

static function getInput($key, $attr)
{
if(!isset($attr['std'])){
$attr['std'] = '';
}
//print_r($attr['std']);

// Depends
$depend_data = '';
if(isset($attr['depends'])) {
$array = array();
foreach ($attr['depends'] as $operand => $value) {
if(!is_array($value)) {
$array[] = array(
$operand,
'=',
$value
);
} else {
$array = $attr['depends'];
}
}

$depend_data = " data-depends='". json_encode($array) ."'";
}

// multiple
$multiple = false;
if(isset($attr['multiple'])) {
$multiple = 'multiple';
}

$output = '';
$output .= ''.$attr['title'].'';

$output .= '';
$menuitem = MenusHelper::getMenuLinks();

$items = array();
$selected = '';
if(!$multiple)$output .= 'Select Menu';

foreach ($menuitem as $key => $item) {
//print_r($item);
$items[$key] = new stdClass();
$items[$key]->title = $item->title;
$items[$key]->menutype = $item->menutype;
$items[$key]->id = $item->id;
$output .= '';
$kitems = array();
foreach ($item->links as $k => $kitem) {
//print_r($kitem);
$kitems[$k] = new stdClass();
$kitems[$k]->value = $kitem->value;
$kitems[$k]->level = $kitem->level;
$kitems[$k]->text = $kitem->text;
$output .= ''.$kitems[$k]->text.'';
}
$output .= '';
}

$output .= '';

if( ( isset($attr['desc']) ) && ( isset($attr['desc']) != '' ) )
{
$output .= '<p class="sp-pagebuilder-help-block">' . $attr['desc'] . '
';
}

$output .= '';

return $output;
}

} ?>

3 Answers

Toufiq - Staff

More than a month ago #Permalink
Hi there,

Good morning. Sorry to say that, No more custom input or override, It has been stoped this feature in this version.

-Thanks

Richard Ross

More than a month ago #Permalink
The counter question, how then to use for example the custom font of icons and what would it be displayed in the admin panel, do not all use the fonthouse?
Hmm, how oddly it turned out, abandon version 3.0, which in everything seemed better, but then such a jamb

Toufiq - Staff

More than a month ago #Permalink
Hi, You can achieve this way.

https://prnt.sc/hj8wv8

Output will be as like
https://prnt.sc/hj8x8m

-Thanks


There are no replies made for this post yet.
However, you are not allowed to reply to this post.

Leaderboard (30 days)

Paul Frankowski

Paul Frankowski

Total Accepted Answers: 137
Sifat

Sifat

Total Accepted Answers: 129
Toufiq

Toufiq

Total Accepted Answers: 40
Rifat Wahid Alif

Rifat Wahid Alif

Total Accepted Answers: 7
pepperstreet

pepperstreet

Total Accepted Answers: 3

100+

Templates

200,000+

Community Users

Newsletter

Don’t miss any updates of our new templates and extensions and all the astonishing offers we bring for you.
We never spam

Joomla! ® name is used under a limited license from Open Source Matters in the United States and other countries. JoomShaper.com is not affiliated with or endorsed by Open Source Matters or the Joomla! Project.

Connect Us