Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 7863 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

In some HTML Selects inputs, the associated value is different from the one shown to the user in the list.

i.e. <select name="test" size="1">

<option select value="somevalue1">Test1

<option select value="somevalue2">Test2

<option select value="somevalue3">Test3

</select>

How can I use the value that is different from the list that is shown to the user.

What I have is a FMP-Option showing the filenames and I want the value of the select to be the filename uniquie id number.

Is this possible since FMP-Option already creates the <option tag>

Posted

I have in my HMTL code:

<select name="fileID">

<option value="">Choose File:</option>

[FMP-ValueList: fileID, List=VersionFileName ]

<option value="[FMP-ValueListItem]">[FMP-ValueListItem]</option>

[/FMP-ValueList]

</select>

For some reason, the value of each option are the files names in the value list versionfilename.

How do I get it such that the value is the fileID and the list actually shown are the filenames

fileID is a field that has a corresponding valuelist of file IDs.

Thanks.

Posted

If I unerstand correctly:

you would like to have eg.:

John -(value 1)

Smith - (value 2)

Jack - (value 33)

Mr.Z - (value 77)

where values 1,2,33,77 come from eg. "UserID" field and John,Smith,Jack,Mr.Z come from field "UserName"

right?

I have not done this so I do not know if it will work but what you could try is in FM make your list "VersionFIleName" set as = to filed UserID

and then in CMDL/HTML

....<option value="[FMP-ValueListItem]">[FMP-field:UserName]</option>...

so when a user click on drop-down they will see User Names but submit the UserID....

as I said I don't know if this works in practice...but it "sounds good to me" in theory! wink.gif

now go get lucky smile.gif

Posted

well I tryed.. smile.gif

but macaroni

you "probably" *should follow Garry's link...

I am a "sheep" when it comes to CDML and I just "graze"....barely got my "sheep skin" smile.gif LOL

This topic is 7863 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.