خرید بک لینک
I have already made a simple working example by having lots of duplicate functions (one function for each button) and using onclick but I was wondering if there is a simpler way to have this where I don't have to duplicate lots of code over and over but each button passes the 3 things to the same function or directly to the 3 html elements. I want to have lots of buttons to change the html like this.

button 1 - src='image1.jpg' span1 = "some text" span2 = "different text"
button 2 - src='image2.jpg' span1 = "other text" span2 = "some different text"


html has

img
span
span

برچسب: نویسنده: آیلین رضوانی تاريخ: يکشنبه 17 دی 1396 ساعت: 2:24

صفحه بندی