Re: Horde View

Ralf Lang <[email protected]>
Newsgroups gmane.comp.horde.devel
Message-ID <[email protected]>
On 28.01.2015 11:36, Sebastian Birnbach wrote:
> Big petty that Horde_Rdo_Form is dead.
> Any ideas where to start looking for doing just what it was supposed to do?
> 
>   Sebastian
> 
> 2015-01-28 10:06 GMT+01:00 Jan Schneider <[email protected]>:
> 

Depends on how much automation you want.
If you want to omit horde_forms at all, you just generate a Horde_View,
pass it the Rdo Item as a variable $view->item = $item.

For simple fields, iterate over it

foreach ($this->item as $field) {
   /* generate a php input with item-specific id and name attributes */
}

More sophisticated: Iterate over $item->mapper->fields and/or
$item->mapper->tableDefinition to get the type of column.

But guess what, this is probably all not what you want.
You probably have a fixed set of Rdo item classes with fixed columns.

You probably want to create forms based on information not available as
table metadata: Pretty headings, input types that make sense, validation
etc.

Personally, I try to avoid Horde_Forms where possible and try to use
"handmade" dialogs instead. This works well enough for the type of apps
I develop.

But there is no feature-complete alternative to the Forms library.

-- 
Ralf Lang
Linux Consultant / Developer
Tel.: +49-170-6381563
Mail: [email protected]
B1 Systems GmbH
Osterfeldstraße 7 / 85088 Vohburg / http://www.b1-systems.de
GF: Ralph Dehner / Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537

-- 
dev mailing list
Frequently Asked Questions: http://wiki.horde.org/FAQ
To unsubscribe, mail: [email protected]
signature.asc (application/pgp-signature, 181 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iEYEARECAAYFAlTIwh8ACgkQCs1dsHJ/X7ASewCgpi6HPE8gGdk1Q4asijakjVtZ
l9YAoKFq9Tzds8F1S6qszvZBCPecrde7
=8bsg
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.