Mar 8, 2018 04:35 PM
(This post was last modified: Mar 8, 2018 04:57 PM by Helltoy.)
Hy,
I want let user to customize his profile page (like background color/image, text color and so on).
I would like to know what is the best solution for this. Should I use "data attributes" or I should simply add "style" into html document.
With data attributes i should have javascript but I don't see point of using it (maybe I miss something) if I can simply add styles.
Can anyone suggest me solution for this?
or
Or should I put all profile content into one div and then style that div?
Thanks.
I want let user to customize his profile page (like background color/image, text color and so on).
I would like to know what is the best solution for this. Should I use "data attributes" or I should simply add "style" into html document.
With data attributes i should have javascript but I don't see point of using it (maybe I miss something) if I can simply add styles.
Can anyone suggest me solution for this?
Code
<div class='test' data-bg-color="red" >teste</div>
//script to change body colorCode
<div class='test' style="background-color: red; >teste</div>Thanks.


![[Image: XbaG5gl.gif]](https://i.imgur.com/XbaG5gl.gif)
aerox.design
![[Image: fpZ5a5g.png]](https://i.imgur.com/fpZ5a5g.png)