close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Update multiple select list

Thread began 10/10/2011 10:53 am by Joe Lowery | Last modified 10/12/2011 10:29 am by Jason Byrnes | 1343 views | 5 replies |

Joe Lowery

Update multiple select list

I'm able to insert multiple values from a select list, but I can't get the select list to show the stored values on an update record page. I have a set of square brackets added to the name of my field to indicate an array, but it doesn't seem to help. What am I doing wrong?

- Joe

Sign in to reply to this post

Jason ByrnesWebAssist

on the insert page, is it inserting the multiple values as a comma separated list to the database?


can you send a copy of the insert and update pages so i can examine the code

Sign in to reply to this post

Joe Lowery

Re: Update multiple select list

Actually, I'm using DataAssist's Manage Relational Table server behavior to write to a related table. You'll also notice that I'm using a jQuery plug-in (bsmSelect) to display the multiple select lists better. Even if I expand the select list to a height of 10 or so, my update list shows all entries selected.

I've attached the basic files - let me know if you want to see the files work online or anything else.

Thanks - Joe

Attached Files
lowery_insert_update.zip
Sign in to reply to this post

Jason ByrnesWebAssist

Go to the bindings panel, and click the plus button, select URL Variable and name it id.

in the manage relational table behavior on the update page, set the master key value to use the id URL Variable.

Sign in to reply to this post

Joe Lowery

Tried that, Jason, but I'm still getting all the entries in the multi-select list chosen. Any other thoughts?

Sign in to reply to this post

Jason ByrnesWebAssist

change the code for the options:

php:
<option value="<?php echo $row_rsFaculty['id']?>"<?php if (!(strcmp($row_rsFaculty['id'], $row_rsFaculty['id']))) {echo "selected=\"selected\"";} ?> <?php if (!(strcmp($row_rsFaculty['id'], WA_AB_returnPreSelectValue($WA_PreSelect_RelationalTable_1$row_rsFaculty['id'])))) {echo "selected=\"selected\"";} ?> ><?php echo $row_rsFaculty['theName']?></option>





to:

php:
<option value="<?php echo $row_rsFaculty['id']?><?php if (!(strcmp($row_rsFaculty['id'], WA_AB_returnPreSelectValue($WA_PreSelect_RelationalTable_1$row_rsFaculty['id'])))) {echo "selected=\"selected\"";} ?> ><?php echo $row_rsFaculty['theName']?></option>
Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...