|
Posted by IchBin on 08/09/06 16:31
Markus Ernst wrote:
> IchBin schrieb:
>>
>> I am new to PHP. I am trying to create a QuickForm Select element and
>> load it from a database with 'HTML_QuickForm::LoadQuery'.
>>
>> I figured it would be a lot easier than build all of that code by
>> hand. The only thing is I can not find much info on using these
>> objects. I can not read the manual for this as I can for Java API's. I
>> am able to display the Select object with label but no data.
>>
>> Can some one point me in the right direction? I am missing something
>> stupid..
>>
>> This is the code sniplet:
>>
>> $form = new HTML_QuickForm();
>> $s =& $form->createElement('select','name','Catagory:' );
>> $s->loadQuery($conn, 'select id, name from catagory order by name',
>
> You are sure it is 'catagory', not 'category'?
> ^ ^
>
> Markus
Nice catch but unfortunately my misspelling is consistent in the column
name. I wish their were examples across the internet so I can understand
this function. I have only found one reference to
'HTML_QuickForm::LoadQuery'. I guess I could try
'HTML_QuickForm::loadDbResult' but I am not using the DB abstraction
currently in my program.
Is there a place where the author answers questions about their PEAR
classes. Again I am new to PHP and I am a Java programmer learning PHP.
Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
__________________________________________________________________________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Navigation:
[Reply to this message]
|