dinamic dropdown option image

How to display a dynamic logo image based on dropdown selection in a form and PDF.

Overview

The issue is needing to show a specific logo image when a user selects an option from a dropdown menu, both in the form and in the generated TCPDF file.
Use custom JavaScript to change the image source on dropdown selection and configure a virtual field to pass the selected image data to the PDF template.

Answered
ChronoForms v8
re renaultmeganegt 24 Oct, 2024

buongiorno, sono italiano

ho necessita di creare un form per una gestione di vendita.

avrei la necessita di creare un modulo con un menu dinamico e vorrei che nel menu selezionando un determinato valore esca un logo diverso. mi spiego meglio.

vorrei creare un modulo dove nel menu a tendina scegliendo un marchio mi metta un logo oppure scegliendone un altro me ne mette un altro. esempio.

se scelgo moto mi metta un logo moto.jpeg,

se scelgo auto mi metta un logo auto.jpeg,

come posso fare?

provengo da chronoform v3 e sto passando alla v8 ma conosco poco di questo mondo, spero che qualcuno mi puo aiutare, grazie

Max_admin Max_admin 24 Oct, 2024

Hi

Where should the logo image appear ? you mean in an image beside the dropdown ?

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
re renaultmeganegt 24 Oct, 2024

ciao, si vorrei farla apparire nel menu a discesa quando si compila il form

e anche quando si compila il file in tcpdf

Max_admin Max_admin 26 Oct, 2024

can you post a screenshot of how this should be working ?

if you need to modify an img src on dropdown change then this can be done with little javascript code

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
re renaultmeganegt 28 Oct, 2024

SPERO CHE HO CAPITO COSA CHIEDI,

IO SONO ALLE BASI E STO CERCANDO DI FARE UN BEL SITO 

QUANDO SCELGO IL MODELLO VORREI CHE NEL FOGLIO CHE STAMPO IN TCPDF VENGA FUORI IL LOGO SCELTO DA ME E ASSOCIATO A QUAL NOME DEL DROPDOWN

QUESTO INVECE E UN ALTRA COSA

MENTRE QUA INVECE VORREI CHE QUANDO SI SELEZIONA RITIRO USATO APPAIA E SCOMPAIA LA SEZIONE SOTTO DOVE C'E MARCA MODELLO TARGA ECC ECC

Max_admin Max_admin 01 Nov, 2024
  1. if you need to show/hide a section then this is done using events triggers/listeners
  2. for changing the image you need some javascript code
  3. for setting the image in the PDF you need a virtual field
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
re renaultmeganegt 01 Nov, 2024

Ok. E come faccio a fare questo?

Ripeto non sono molto bravo e non conosco il linguaggio java

Come posso fare?

Max_admin Max_admin 04 Nov, 2024
Answer
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.