forum.coppermine-gallery.net

Support => Older/other versions => cpg1.3.x Support => Topic started by: recman on October 10, 2004, 09:33:45 am

Title: Have a value in upload form
Post by: recman on October 10, 2004, 09:33:45 am
Hi!
When I have uploaded a file and should place it in a album I come to the file upload.php, there is a form called "File Title". I wonder how I can do to always have a value in this form, a text that is typed there automaticlly so the user dont have to write it. Anyone understand how I mean? Sorry for the bad english.
Title: Re: Have a value in upload form
Post by: Nibbler on October 10, 2004, 02:59:10 pm
Upload.php, find:

Code: [Select]
// Create a text box.
add

Code: [Select]
$value = ($name == 'title') ? 'Text that appears here automatically' : '';

just below it

find

Code: [Select]
<input type="text" style="width: 100%" name="$name" id="$name" maxlength="$max_length" value="" class="textinput">
change to

Code: [Select]
<input type="text" style="width: 100%" name="$name" id="$name" maxlength="$max_length" value="$value" class="textinput">