Request a new block type "custum template selector"

Permalink Browser Info Environment
Hi Ramon,

I wonder if it is possible to ask you make new block type that "custum template selector".

I know the way to change a custum template, but editing blocks and changing cutsum teplate are two different actions. Some users want to change a custum teplate while they are editing.


Cheers,
Be Sharp

Type: Discussion
Status: In Progress
View Replies:
ramonleenders replied on at Permalink Reply
ramonleenders
Hi there,

This is something I had in mind myself, but no ones has asked me before - untill now. So I'm diving into this for you and will let you know when I've got more information.

As you can only have 1 template selected for the whole Block Type, it makes sense you can only have this once in your form. So it's not a field type like "Text" or "Text Area". So I'm thinking to have it inserted into a tab at the top maybe, saying "Advanced" when you check a checkbox saying "Selectable Custom Template" maybe? Same as when you click "Design & Custom Template". All your fields go into "Bascis" tab by default, so you have them separated. We may be able to add some more settings into this advanced tab, like custom ID and stuff like that (less priority for now I assume).

What do you think?

Kind regards,

Ramon
BeSharp replied on at Permalink Reply
Hi Ramon,

Thank you for your reply.

For this block, what I want to do is exactly as you say "same as when you click "Design & Custom Template"". If I can use a new block, it will helps me a lot.

-----
From here, not requests, just I want to hear your advice.

For example, I have a block with title, image, button.
Style:
Title : default, bigger
Image : left, right
Button : blue, green, red

Then total template shoud be 2 * 2 * 3 =12.

In this case, do you make 12 template or write codes for handling style,
or make 12 new blocks?

I have not found good solution for this case.


Cheers,
Be Sharp
ramonleenders replied on at Permalink Reply
ramonleenders
If you can have all combinations possible, it makes sense to make a "Select" for that and depending on what they choose in the select, add that to the button/image/title. This way you don't need to work around having multiple templates/blocks, as all the fields are still the same.

In some situations you may need a combination of left/bigger/red maybe and some others (so not all 12), and in that case you can make a "global" select and write some PHP code yourself to add the classes belonging to that combination. So maybe combinations like:

"Default combi"
"Colorful combi"
"Big letter combination"

Just an exmaple. I'd never use templates for a thing like this, only use templates if you have a complete different design/HTML for it!

Kind regards,

Ramon
BeSharp replied on at Permalink Reply
Hi Ramon,

Thank you for your advise.

I will use "select" types and set class for style.
And I will use "custum template" for different structure.

I am making a "call to action" block for several variations.
So I try to find easy way to change styles and structures.

Cheers,
Be Sharp

concrete5 Environment Information

Windows

Browser User-Agent String

Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36

Hide Post Content

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

Hide Content

Request Refund

You may not request a refund that is not currently owned by you.