Quantcast
Channel: Zenphoto forum
Viewing all articles
Browse latest Browse all 2917

thommy on "Custom Fields in Album"

$
0
0

I'm trying to add custom Fields in Album.
Event_title
Event_parent_id
Event_id

I took the Example from https://github.com/zenphoto/Unsupported/blob/master/plugins/filter-custom_data/filter-custom_data.php


function custom_data_save_album($discard, $prefix) {
return sanitize($_POST[$prefix.'x_album_custom_data'], 1);
}

function custom_data_edit_album($discard, $album, $prefix) {
return
'<tr>
<td align="left" valign="top">'.gettext("Special data:").'</td>
<td><textarea name="'.$prefix.'x_album_custom_data" cols="'.TEXTAREA_COLUMNS.'" rows="6">'.htmlentities($album->get('custom_data'),ENT_COMPAT,getOption("charset")).'</textarea></td>
</tr>';
}

It seems, that's only possible to add one custom field. How is it to realize to use more fields?
Any suggestions? Does somebody has an example?


Viewing all articles
Browse latest Browse all 2917

Trending Articles