DM Video approvazione

Area dedicata alle guide di phpBB 3
Rispondi
Avatar utente
Moloch
Utente
Utente
Messaggi: 1053
Iscritto il: 13/06/2012, 0:35
Link del Forum: http://twawi.altervista.org/forum/index.php

DM Video approvazione

Messaggio da Moloch »

Questa modifica permette di eliminare le approvzioni della Mods DM Video
vi arriverà solamente un PM di avviso che è stato creato un nuovo post con video
Apri
dm_video/postvideo.php

Cerca:

Codice: Seleziona tutto

             if ( $auth->acl_get('a_dm_video_auto_announce') )
             {
                $data['video_approval']   = request_var('video_approval', 1);
             }
             else
             {
                $data['video_approval']   = request_var('video_approval', 0);
             }
Sostituisci:

Codice: Seleziona tutto

                $data['video_approval']   = request_var('video_approval', 1);
Avatar utente
Dr.House
Amministratore
Amministratore
Messaggi: 2173
Iscritto il: 08/01/2012, 8:24
Link del Forum: www.phpbb-italia.it
Località: Reggio Calabria
Contatta:

Re: DM Video approvazione

Messaggio da Dr.House »

ottimo :ok:
Avatar utente
boldherri
Utente
Utente
Messaggi: 164
Iscritto il: 14/05/2012, 16:32
Link del Forum: https://nightfury.altervista.org/forum/index.php
Contatta:

Re: DM Video approvazione

Messaggio da boldherri »

Aggiungo per chi non volesse neanche i messaggi di avviso che ci riempiono la casella dei PM deve fare questa modifica nel file postvideo.php

trova:

Codice: Seleziona tutto

if ( !$auth->acl_get('a_dm_video_auto_announce') )
             {
                // Prepare data to send PM about new videos
                $sql_array = array(
                   'SELECT'    => 'config_name, config_value',
                   'FROM'      => array(
                      DM_VIDEO_CONFIG_TABLE => 'c',
                   ),
                );
                $sql = $db->sql_build_query('SELECT', $sql_array);
                $result = $db->sql_query($sql);

                while ($row = $db->sql_fetchrow($result))
                {
                   $video_config[$row['config_name']] = $row['config_value'];
                }
                $db->sql_freeresult($result);
                
                // note that multibyte support is enabled here
                $video_pm_from      = (string) $video_config['new_video_pm_from'];
                $video_pm_to      = (string) $video_config['new_video_pm_to'];
                $new_video_subject   = $user->lang['DMV_NEW_VIDEOS_PM_SUBJECT'];
                $new_video_text      = $user->lang['DMV_NEW_VIDEOS_PM'];

                // variables to hold the parameters for submit_pm
                $poll = $uid = $bitfield = $options = '';
                generate_text_for_storage($new_video_subject, $uid, $bitfield, $options, false, false, false);
                generate_text_for_storage($new_video_text, $uid, $bitfield, $options, true, true, true);

                $data = array(
                   'address_list'      => array ('u' => array((string) $video_pm_to => 'to')),
                   'from_user_id'      => (string) $video_pm_from,
                   'from_username'      => 'DM Video',
                   'icon_id'         => 0,
                   'from_user_ip'      => (int) $user->data['user_ip'],
                   
                   'enable_bbcode'      => true,
                   'enable_smilies'   => true,
                   'enable_urls'      => true,
                   'enable_sig'      => true,

                   'message'         => (string) $new_video_text,
                   'bbcode_bitfield'   => $bitfield,
                   'bbcode_uid'      => $uid,
                );

                submit_pm('post', $new_video_subject, $data, false);
             }
Sostituire con:

Codice: Seleziona tutto

/*
             if ( !$auth->acl_get('a_dm_video_auto_announce') )
             {
                // Prepare data to send PM about new videos
                $sql_array = array(
                   'SELECT'    => 'config_name, config_value',
                   'FROM'      => array(
                      DM_VIDEO_CONFIG_TABLE => 'c',
                   ),
                );
                $sql = $db->sql_build_query('SELECT', $sql_array);
                $result = $db->sql_query($sql);

                while ($row = $db->sql_fetchrow($result))
                {
                   $video_config[$row['config_name']] = $row['config_value'];
                }
                $db->sql_freeresult($result);
                
                // note that multibyte support is enabled here
                $video_pm_from      = (string) $video_config['new_video_pm_from'];
                $video_pm_to      = (string) $video_config['new_video_pm_to'];
                $new_video_subject   = $user->lang['DMV_NEW_VIDEOS_PM_SUBJECT'];
                $new_video_text      = $user->lang['DMV_NEW_VIDEOS_PM'];

                // variables to hold the parameters for submit_pm
                $poll = $uid = $bitfield = $options = '';
                generate_text_for_storage($new_video_subject, $uid, $bitfield, $options, false, false, false);
                generate_text_for_storage($new_video_text, $uid, $bitfield, $options, true, true, true);

                $data = array(
                   'address_list'      => array ('u' => array((string) $video_pm_to => 'to')),
                   'from_user_id'      => (string) $video_pm_from,
                   'from_username'      => 'DM Video',
                   'icon_id'         => 0,
                   'from_user_ip'      => (int) $user->data['user_ip'],
                   
                   'enable_bbcode'      => true,
                   'enable_smilies'   => true,
                   'enable_urls'      => true,
                   'enable_sig'      => true,

                   'message'         => (string) $new_video_text,
                   'bbcode_bitfield'   => $bitfield,
                   'bbcode_uid'      => $uid,
                );

                submit_pm('post', $new_video_subject, $data, false);
             }
    */
PS:Questa modifica non è stata fatta da me ma dal creatore della mod dm video,il grande felix

enjoy
SENZA DIO MAI UN MONDO MIGLIORE!!!
Rispondi