[Bese-devel] Probably I have to be more specific
Friedrich Dominicus
frido at q-software-solutions.de
Wed Jul 13 06:28:57 UTC 2005
Luigi Panzeri <matley at muppetslab.org> writes:
> Friedrich Dominicus <frido at q-software-solutions.de> writes:
>
>> Ok, I got a bit further. And am now quite sure that there is no
>> special component for Radio Buttons. Now it seems to me that having
>> this would be a good thing. I found out that I can help myself while
>> using this ugly piece of code:
>> (ucw::get-parameter (ucw::context.request *context*) 'download)))
>>
>
> Mmmm, but for radio buttons, dont you have to use <ucw:input :type
> "radio" as in html?
Yes that's what one has to use. However I used:
(<:input :type "radio" :name 'download :value "Download"
"Download")
>
> For further documentation on using custom field, see
> src/yaclml/ucw-tags.lisp
Well I better check this file I guess.
> But maybe i dont understand well your question, because perhaps you
> want a library component for radio buttons, as for select-field and
> option-dialog. That is a nice idea.
Yes that was my idea.
>
> (defclass radio-button-select (form-element)
> ...
> ...
> )
>
> (defmethod render-on ((res response) (r radio-button-select))
> (iterate
> (for o in (options r))
> (for index upfrom 0)
> (vector-push-extend o option-map)
> (<ucw:input :type "radio" :value index
> :name (make-new-callback (context.current-frame *context*)
> (lambda (v) (setf (client-value r) v))))
> (funcall (option-writer o) o)))
>
> (defmethod read-client-value ((r radio-button-select))
> ...
> (setf lisp-value (aref option-map (parse-integer (client-value r)))))
>
>
> </untested>
>
>
>
> I hope to had given you an help. Sorry for my terrible english, but
>i am tired now.
Thanks for taking the time, will see if and how I can make use of it.
Regards
Friedrich
More information about the bese-devel
mailing list