How to set HTML attribute

Hi
how can i set HTML attribute like <body dir="rtl">

Are you talking about doing it in UI Builder?

yes the frontend

Please see the following post, it describes a few solutions:

Yes this is for css
so we cant set html attribute currently in the UI

I believe you can do it with codeless by manipulating the DOM elements/attributes.

aha thanks Mark
i will give it a try!

1 Like

Hey Mark,

I know that this original post is a little old, but do you happen to have any examples for reading/setting various HTML Attributes using Codeless?

I need access to the contenteditable attribute and custom data- attributes.

Thanks!

Mike

Hi @Michael_Kadron

It is possible to set attributes by using a block with custom code.



Regards,
Viktor

Great!

Thank you Viktor! :slight_smile:

Mike