I have a problem: that add-on is almost too good... [Solved]

Permalink Browser Info Environment
First of all: i love that add-on! However, i'm beginning to ask myself if it isn't a bit risky to make intense sitewide use of it, as regards guaranteed future... The problem i see is: the functionality that this add-on provides is extremely useful, so maybe it won't remain just as an add-on. What i mean is, maybe it won't live too long just as an add-on, but will be integrated into the core of C5 one day, and consequently become obsolete.
Will we then have to rewrite all the content of all websites where we have previously used the designer content add-on...?

What's your opinion?

Michael

Type: Discussion
Status: New
okapi
View Replies: View Best Answer
jordanlev replied on at Permalink Best Answer Reply
jordanlev
Hi Michael,
Thank you for your kind words. I am not on the core team, so this is all just best guesses here, but basically I would not worry about this scenario.

The only reason that the addon needs to stay installed is because it contains code that fixes some c5 bugs related to block editing. The blocks that Designer Content creates are completely standalone, but they do utilize some of these patches to make the add/edit windows work better.

So even if Designer Content was added to the core (which as of now I haven't heard anything from the core team about so this is just a hypothetical situation), the bugs it fixes would *also* be addressed in the core -- at which time you'd be able to uninstall the Designer Content addon and the blocks you've made with it would continue to function as they were. There is one small change you would need to make to the edit.php file of any blocks that have "page link" fields in them -- changing this (line #4):
$ps = Loader::helper('form/page_selector', 'designer_content');

to this:
$ps = Loader::helper('form/page_selector');

...but even if you forgot to do that the blocks would still display just fine on your site (you would just get an error or experience wonky behavior when you edit the block).

But you definitely would not need to change any content you've already entered into the site!

Hope that clears things up.

-Jordan
okapi replied on at Permalink Reply
okapi
Jordan, thank you so much for that explanation. This is precious information for me - and i think for everyone else using your great add-on. Thank you!

Greeting from Vienna,
Michael
okapi replied on at Permalink Reply
okapi
I just tried this out now... and wow, it's amazing! I created a custom block with the designer content add-on, then i applied your little hack to the edit.php and copied the block to the "blocks" directory (at the root) of another C5 installation, where the designer content addon was NOT installed. I installed the block as usual and was able to use it without any problem...
That's really cool!

Just one question: why does the designer content add-on not create such "standalone" blocks by default? What's the purpose of 'designer_content' in
$ps = Loader::helper('form/page_selector', 'designer_content');

if editing also works nicely without it?

Michael
jordanlev replied on at Permalink Reply
jordanlev
You will run into problems if you have a WYSIWYG editor and an image or page link field in the same block -- as soon as you insert an image or link into the WYSIWYG editor, the other image and link controls won't function properly. This is the C5 bug.
jordanlev replied on at Permalink Reply
jordanlev
Also the concrete5 built-in page selector doesn't let you un-select a page once one is selected, so if your Page Link field isn't required, your users will have no way to remove the link once it has been saved the first time.
okapi replied on at Permalink Reply
okapi
Thank you for being so kind to explain these details, Jordan! This is very helpful for me.

Michael

concrete5 Environment Information

Browser User-Agent String

Hide Post Content

This will replace the post content with the message: "Content has been removed by an Administrator"

Hide Content

Request Refund

You have not specified a license for this support ticket. You must have a valid license assigned to a support ticket to request a refund.