Jump to content

  •  

  • Tutorial info Visit support topic

    • Added on: Nov 21 2008 03:59 PM
    • Date Updated: Nov 22 2008 10:15 AM
    • Views: 730
     


    * * * * *
    0 Ratings

    Warn your users about approval of pending files

    This tutorial will create a box on top of posting files screen on IP.Downloads to tell your users 'bout approval of pending files

    Posted by Adriano Faria on Nov 21 2008 03:59 PM
    Remember: this will show the box to users that his groups hasn't the permission AUTO POST set on IP.Downloads category.

    Open sources\components_public\downloads\submit.php and find:

    		 $this->output .= $this->ipsclass->compiled_templates['skin_downloads_submit']->main_submit_form( $file, $cfield_display );
    Change to:

    		$post = in_array( $catid, $this->catlib->member_access['auto'] ) ? 1 : 0;
    			  
    		  if ( $post == 0 )
    		  {
    				$msg = "
    	<div class='borderwrap'><div class='maintitle'><{CAT_IMG}>&nbsp;Dear ".$this->ipsclass->member['members_display_name']."!</div><div class='tablepad' align='center'><b>Your file won't be available immediately!   An administrator must review your submission before it will be available publicly!</b><br />Please, upload your file and wait a few minutes.<br /><br />Thank you for using <b>".$this->ipsclass->vars['board_name']."</b>!</div></div><br />";
    		  }
    			
    		  $this->output .= $this->ipsclass->compiled_templates['skin_downloads_submit']->main_submit_form( $file, $cfield_display, $msg );
    Open skin_downloads_submit -> main_submit_form template and add {$msg} at very begin of that template.

    Now click on  Edit Data Variables of this template and add ,$msg="" after all that already exists there!

    This is what your users will see when post a file:

    Posted Image


    Powered by Tutorials 1.4.1 © 2012, by Michael McCune