Recent Topics

1 Nov 12, 2006 09:52    

I'm working with a group of people who are using a B2 I set up for them (latest version) www.tvcm.co.uk/cmc

Last week most of them uploaded an MP3 using the new file upload feature. I need to write some session notes on doing this which would be roughly like this:

Start a new post
Go to files and browse to your file click upload
Select the file you want to add to your post and under "actions" select the edit icon
In the "Long Title" box type the words click here and click on the "Update" button.
Now click on the [IMG] button

Now I know there are slightly different ways of doing this such as adding the "click here" as you upload.

I'd be interested in any comments. Is this the best way to do it. IS this is how it's intended to be used for adding files.

I think it may be confusing for my participants because the terms "Long Title" and the "IMG" button are the wrong names for the purpose we are putting them to. Where would I go to hack those bits?

2 Nov 13, 2006 08:36

The "img" is set in inc/view/files/_files_browse.inc.php (approx line 625 ) :

		<?php
		if( $mode == 'upload' )
		{	// We are uploading in a popup opened by an edit screen
			?>
			<input class="ActionButton"
				title="<?php echo T_('Insert IMG tags for selected files'); ?>"
				name="actionArray[img_tag]"
				value="img"
				type="submit"
				onclick="insert_tag_for_selected_files(); return false;" />
			<?php
		}

The "long title" is in (same folder)#/_file_properties.inc.php (approx line 53 ) :

	$Form->begin_fieldset( T_('Meta data') );
		if( $current_User->check_perm( 'files', 'edit' ) )
		{ // User can edit:
			$Form->text( 'title', $edit_File->title, 50, T_('Long title'), T_('This is a longer descriptive title'), 255 );
			$Form->text( 'alt', $edit_File->alt, 50, T_('Alternative text'), T_('This is useful for images'), 255 );
			$Form->textarea( 'desc', $edit_File->desc, 10, T_('Caption/Description') );
		}
		else
		{ // User can view only:
			$Form->info( T_('Long title'), $edit_File->dget('title'), T_('This is a longer descriptive title') );
			$Form->info( T_('Alternative text'), $edit_File->dget('alt'), T_('This is useful for images') );
			$Form->info( T_('Caption/Description'), $edit_File->dget('desc') );
		}
	$Form->end_fieldset();

¥

3 Nov 13, 2006 08:42

Thanks Yabba. So is the fact that this works in a different way for files when it's obviously intended for images intentional or a fluke. I mean - will it dissapear or change in a later version

4 Nov 13, 2006 08:43

I'd need a crystal ball to answer that one :p

¥


Form is loading...