You need to be logged in to post in the forum - Log In

An active JCE Pro Subscription is required to post in the forum - Buy a Subscription

Support is currently Online

Official support hours
Monday to Friday
09:00 - 17:00 Europe/London (BST)

#114185 Create a button

Posted in ‘Editor’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Latest post by channingb on Monday, 17 July 2023 16:33 BST

channingb
Hello JCE Team:

I am trying to make it easy for our clients to simply create a link and style it as a button. I have been able to create the styles for a button and they can use the editor to create the button using "styles" then add a link. It works.

However, if they do not do it in the correct order, the span and a href, the styling does not keep the original button style we utilize with a Yootheme template e.g. the text is dark when it should be white and the link is underlined.

I was wondering if I am missing how to find a "button icon/builder" in JCE, that allow the user to simply click on it, perhaps choose an option of a style e.g. red or green, then simply add link.

I know that the current process I have created works, but I know clients will not always follow the rule.

Thank you.

Channing

Ryan
You don't need to create a span to apply the button class to, it can be applied directly to the link tag.

You can create a custom style for this that the user can select from the Styles list after creating the link:

In Editor Profiles -> Plugin Parameters -> Style Select, create a Custom Style with the following values:

Title: Link Button (or whatever yor prefer)
Tag: None (Apply to selected Tag)
Element Selector: a
Classes: uk-button uk-button-primary (or your preferred Yootheme button classes)

https://cdn.joomlacontenteditor.net/tmp/114185-create-a-button.jpg

Ryan Demmer

Lead Developer / CEO / CTO

Just because you're not paranoid doesn't mean everybody isn't out to get you.

channingb
Thank you Ryan. That make sense. Appreciate your help.