Version 4.5.0

This commit is contained in:
Neo committed 2025-12-19 05:51:58 -08:00
1 parent 1a0c7fd3c2
commit f79dcf067a
3791 files changed
+248032 -76372

No files matched your search

+5 -9
View File
@@ -12,7 +12,7 @@
namespace IPS\cms\widgets;
/* To prevent PHP errors (extending class does not exist) revealing path */
if ( !defined( '\IPS\SUITE_UNIQUE_KEY' ) )
if ( !\defined( '\IPS\SUITE_UNIQUE_KEY' ) )
{
header( ( isset( $_SERVER['SERVER_PROTOCOL'] ) ? $_SERVER['SERVER_PROTOCOL'] : 'HTTP/1.0' ) . ' 403 Forbidden' );
exit;
@@ -41,12 +41,10 @@ class _Blocks extends \IPS\Widget\PermissionCache
/**
* Constructor
*
* @param String $uniqueKey Unique key for this specific instance
* @param string $uniqueKey Unique key for this specific instance
* @param array $configuration Widget custom configuration
* @param null|string|array $access Array/JSON string of executable apps (core=sidebar only, content=IP.Content only, etc)
* @param null|string $orientation Orientation (top, bottom, right, left)
* @param boolean $allowReuse If true, when the block is used, it will remain in the sidebar so it can be used again.
* @param string $menuStyle Menu is a drop down menu, modal is a bigger modal panel.
* @return void
*/
public function __construct( $uniqueKey, array $configuration, $access=null, $orientation=null )
@@ -85,10 +83,7 @@ class _Blocks extends \IPS\Widget\PermissionCache
*/
public function configuration( &$form=null )
{
if ( $form === null )
{
$form = new \IPS\Helpers\Form;
}
$form = parent::configuration( $form );
/* A block may be deleted on the back end */
$block = NULL;
@@ -103,6 +98,7 @@ class _Blocks extends \IPS\Widget\PermissionCache
$form->add( new \IPS\Helpers\Form\Node( 'cms_widget_custom_block', $block, FALSE, array(
'class' => '\IPS\cms\Blocks\Container',
'showAllNodes' => TRUE,
'permissionCheck' => function( $node )
{
if ( $node instanceof \IPS\cms\Blocks\Container )
@@ -125,7 +121,7 @@ class _Blocks extends \IPS\Widget\PermissionCache
*/
public function preConfig( $values )
{
$newValues = array();
$newValues = $values;
if ( isset( $values['cms_widget_custom_block'] ) )
{