Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

RTE

Avatar

Level 2

Hi,

How to add a placeholder in RTE?

Thanks,Screenshot (201).png

Vishal Jain

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi, RTE is not a input element but a div, you can implement custom solution like

https://stackoverflow.com/questions/20726174/placeholder-for-contenteditable-div 

 

form.cq-dialog .cq-dialog-content .cq-RichText-editable[contenteditable=true]:before{
  content: attr(placeholder);
  font-size: 14px;
  color: #254e72;
  font-style: italic;
}


Arun Patidar

View solution in original post

1 Reply

Avatar

Correct answer by
Community Advisor

Hi, RTE is not a input element but a div, you can implement custom solution like

https://stackoverflow.com/questions/20726174/placeholder-for-contenteditable-div 

 

form.cq-dialog .cq-dialog-content .cq-RichText-editable[contenteditable=true]:before{
  content: attr(placeholder);
  font-size: 14px;
  color: #254e72;
  font-style: italic;
}


Arun Patidar