PC SOFT

FORUMS PROFESSIONNELS
WINDEVWEBDEV et WINDEV Mobile

Accueil → WEBDEV 2024 → webdev - swapping data within div
webdev - swapping data within div
Débuté par BettyRNorahDeniels, 27 avr. 2022 09:15 - 1 réponse
Membre enregistré
6 messages
Posté le 27 avril 2022 - 09:15
Hi

I'm a novice in webdev.

Terminology, phrasing, and conventions are still in the works. Without the right wording, researching my problem -- with books, Google, and SO -- was unsuccessful. Maybe the goal will make sense:

I have an outer < div > acting as a tab-based display. Within, I plan to add a scroll-able list and a 'show area' consisting of various content (images, text, apps, etc). Retrospectively, the format is similar to Outlook's and iOS' mail design.

The tabs are one category of data, the list items another. This is akin to different mail folders (e.g. Junk Mail -> mail item 3 -> display contents; Inbox -> mail item 2 -> display contents).

My concern is how to display those contents, since there is a wide range of possible selections and much substance to each. I cannot imagine hiding all but the selected < div >, which would be like hiding all mail items besides the current one.

I thought of creating local files and reading them based on item selection. Even then, I am unsure what would be effective. If it were only some text, I could easily swap the innerHTML of the displaying < div >. But would that be useful for my intention?

Overall, how would I go about this design? What are particular terms or design concepts that you may recommend for thinking about this and similar problems?

Thank you for the time!
Posté le 30 avril 2022 - 09:01
first stop talking about DIVs, as nobody here will understand you :-)
In webdev, we are NOT working at the html level.

Second, -IF- I understand correctly the question, use a looper where you put all the type of fields that you may need and for each field, define two attributes... one for its content/vale, and the other to make it wisible or not, depending on your current need.