Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

CFinput and autosuggest difficulty

Guest
Apr 24, 2008 Apr 24, 2008
Hello all,
The CFinput and Autosuggest seemed like they were going to work great. I was trying to use this format:
<cfinput type="text" name="OP12" autosuggest="#valuelist(get_drivers.DRIVER_NAME)#">
get_drivers is a CFquery in the same .cfm file, and DRIVER_NAME is a column the query returns. But the DRIVER_NAME is last name COMMA first name: ie Emery, Scott. The valuelist takes a comma seperated list for the autosuggest. When I run it like this, I expect to see Emery, Scott as one of the choices, but instead I see Emery on one line and Scott on another line. Is there a way I can escape the comma that is between the names?
Maybe there is a better way of getting the list, or maybe I can use a replace function to change the comma to a different character that looks like a comma.
Thanks in advance
Scott

TOPICS
Advanced techniques
576
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 24, 2008 Apr 24, 2008
use:
<cfinput type="text" name="OP12"
autosuggest="#valuelist(get_drivers.DRIVER_NAME, '|')#" delimiter="|">

Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guest
Apr 24, 2008 Apr 24, 2008
Azadi,
That didn't quite work. The result was I ended up with only the first letter of all the last names. The documentation looks like the dilimiter applys only to a static list, or a control where you can set what the dilimiter is in the return set. I don't know that you can set what the dilimiter is when the CFquery returns the data set to the Autosuggest.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 24, 2008 Apr 24, 2008
LATEST
you are right - you can't. the delimiter is only for static lists.


Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources