203 Posts
louispapera
10 years ago
11
Topic

Hellò Sebloders, I use with huge success "Select Dynamic Cascade" but now I want to copy the fields that I have selected in other fields on the form. 

Does anyone know how to do? Regards, Louis

Get a VIP membership
4229 Posts
Kadministrator
10 years ago
1
Level 1

Not sure I exactly uderstand this question, but you can use conditionals (button 5) to copy values from fields on same form

203 Posts
louispapera
10 years ago
0
Level 2

Hi Klas, may thanks for your reply. 

About my questions I will be more clear. When I select a field in select dinamic cascade I need to put this field in another field of the form.

Unfortunately I note that seblod when I use conditionals (button 5) copy his code (not value field) in destination field instead that his original value.

(i.e. : I select a state "Italy" and it copy his code (a number) in the field )

How I do for copy original value that I select ?

Awaiting your reply, best regards, Louis

4229 Posts
Kadministrator
10 years ago
5
Level 1

Hi,

selects have texts (what you see) and values (what is written to the database, usually some kind of id).

As far as I know you can only copy value (which is number in your case), if you need text you can duplicate dynamic cascade field and use it instead of text or whatever kind of field you have there now, this way you will see text when conditional copies value. Alternatively, if you just need this text when you display item, you could use SD databaser plugin to run the same query as in dynamic select and WHERE id = *value*; (replace id with actual column name )

203 Posts
louispapera
10 years ago
0
Level 2

Dear Klas, thanks for your suggestions, I will try and I inform you ASAP.

Regards, Louis

203 Posts
louispapera
10 years ago
3
Level 2

Hello Klas, I installed the plugin SD Databaser and I tried entering a free query for a field "select dinamic cascade" as under: 

"SELECT * FROM # __cck_store_form_dipartimenti WHERE denom_dipartimento = * value *;" but it does not work. Maybe I'm wrong something? 

Another way that you have suggested to me is to duplicate the field about "select dinamic cascade" but I do not know how to do. 

Please, in one way or another you can help me. Thank you, Louis

4229 Posts
Kadministrator
10 years ago
2
Level 3

Hi,

first - you need to use SD databaser on the text field with conditionals, not on dynamic cascade. When you say "it does not work" -  do you get any errors? If your query is copy/paste then you need to remove space after #   (# __cck).

For second option I was a bit wrong, you need to use "Select dynamic" with the same query as you last select in cascade, plus the same conditional as you have on text field (conditional will copy value, select dynamic will give you text from this value).

203 Posts
louispapera
10 years ago
1
Level 4

Dear Klas, I see that I can handle SD Databaser only view content. 

Now my query is: SELECT * FROM #__cck_store_form_dipartimenti WHERE denom_dipartimento = * value * 

I tried but I do not find value, I find code only.  Why ? Now what I wrong.

Awaiting your help, best regards, Louis

4229 Posts
Kadministrator
10 years ago
0
Level 5

Should be *value* , not * value *, spaces matter

4229 Posts
Kadministrator
10 years ago
2
Level 1

and ofcourse you already need value in that field, to get it you need to set conditionals as mentioned.

203 Posts
louispapera
10 years ago
1
Level 2

Dear Klas, thanks for your reply, in site form I put in conditional state just values about select dinamic cascade field, in fact I find in my field just code.

Is there was a misunderstanding. I need to record the value of selected text in the field and not its code. Is it possible, please?

Example: I choose from select dinamic cascade a field, it is a city: Paris

When I create a new test field and I put a conditionals I find Paris Code, not "Paris" as text. While I need to find "Paris" in new test field.

I hope to be clear for you. Then I can use this new field for further my need.

I hope the success of this very problem as I will be able to use this field for doing several searches with search and type.

Best regards, Louis

203 Posts
louispapera
10 years ago
0
Level 3

Hi, have you any suggestions, please ?   Thanks in advance, best regards, Louis 

Get a Book for SEBLOD