Version stable

Qui est en ligne

30 utilisateur(s) en ligne (12 membre(s) connecté(s) sur Forum)

Membre(s): 1
Invité(s): 29

TRAC, Plus ...

Rejoignez-nous




(1) 2 3 4 ... 10 »


Captcha pour differents modules
Développeur
Inscrit:
22/02/2004 20:41
Messages: 961
Pour Weblinks 0,96

Bonjour,

j'avais besoin du captcha pour le module weblinks (à cause du spam). Vu que je n'ai trouvé nul part de hack pour ce module, je mets la modification à faire ici, ça peut toujours servir.

Dans submit.php:
Vers la Ligne 76:
if (($op == 'post')||($op == 'ignore')) 
{
[
color=CC0000]// Hack SecurityImage by Dugris
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
     
redirect_header'(script removed)history.go(-1)'2_SECURITYIMAGE_ERROR ) ;
     exit();
}
//Hack SecurityImage by Dugris[/color]
// add URL-less mode
// check form
    
$flag_check $tbl_link->checkFormAddLink($_POST);



Dans include/submit_form.php:
Vers la Ligne 282-283

// button
    
$tray_button = new XoopsFormElementTray'' );
[
color=CC0000]//Hack SecurityImage by Dugris
if (defined('SECURITYIMAGE_INCLUDED')) {

    
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );

    if (
$security_image->render()) { 

        
$tray_button->addElement($security_imagetrue); 

    } 

}
//Hack SecurityImage by Dugris[/color]
$tray_button->addElement$builder->make_submit_button'''post',    $arr['post']  ) );
    
$tray_button->addElement$builder->make_submit_button'''preview'_PREVIEW ) );
    
$tray_button->addElement$builder->make_cancel_button'''cancel',  _CANCEL ) );
    
$builder->add_element$tray_button );



Il y a juste un petit bug avec la phrase "Entrez le code de sécurité" qui n'est pas du bon coté du formulaire ce qui est normal, j'aurais du mettre "builder" à la place de "tray_button". Mais si je le remplace, le formulaire ne marche plus
+++

Posté le : 22/07/2007 04:07
_________________
www.tdmxoops.net
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Xoops accro
Inscrit:
25/11/2004 12:53
De 48400 Florac - France
Messages: 3373
Merci kraven, ça m'intéresse

Philippe.

Posté le : 22/07/2007 13:39
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Développeur
Inscrit:
22/02/2004 20:41
Messages: 961
Pour Mydownloads 1.43


Dans submit.php:
Vers la Ligne 42-43:

if (!empty($_POST['submit'])) {
[
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
        
redirect_header'index.php' 1_SECURITYIMAGE_ERROR ) ;
    }
//Hack SecurityImage by Dugris[/color]
    
$submitter = !empty($xoopsUser) ? $xoopsUser->getVar('uid') : 0;


Vers la Ligne 155:
$xoopsTpl->assign('lang_cancel'_CANCEL);
    
    [
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') ) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if ( 
$security_image->render() ) {
            
$xoopsTpl->assign('lang_securityimage'_SECURITYIMAGE_CODE);
            
$xoopsTpl->assign('input_securityimage' $security_image->render() );
        }
    }
    
//Hack SecurityImage by Dugris[/color]
    
    
ob_start();
    
$mytree->makeMySelBox("title""title",0,1);


Dans mydownloads_submit.html:
Vers la Ligne 61:

<{/if}>            </td>
          </
tr>
         [
color=CC0000]<!-- Hack SecurityImage by Dugris-->
          <
tr>
            <
td class="head"><{$lang_securityimage}></td>
            <
td class="even"><{$input_securityimage}></td>
          </
tr>
     <!-- 
Hack SecurityImage by Dugris-->[/color]
        </
table>

Posté le : 22/07/2007 13:57
_________________
www.tdmxoops.net
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Développeur
Inscrit:
22/02/2004 20:41
Messages: 961
Pour Mylinks 1.1


Dans submit.php:
Vers la Ligne 42-43:

if (!empty($HTTP_POST_VARS['submit'])) {
[
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
        
redirect_header'submit.php' 1_SECURITYIMAGE_ERROR ) ;
    }
    
//Hack SecurityImage by Dugris[/color]
    
$submitter = !empty($xoopsUser) ? $xoopsUser->getVar('uid') : 0;


Vers la Ligne 155:
$xoopsTpl->assign('lang_cancel'_CANCEL);
    [
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') ) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if ( 
$security_image->render() ) {
            
$xoopsTpl->assign('lang_securityimage'_SECURITYIMAGE_CODE);
            
$xoopsTpl->assign('input_securityimage' $security_image->render() );
        }
    }
    
//Hack SecurityImage by Dugris[/color]
    
ob_start();
    
$mytree->makeMySelBox("title""title",0,1);


Dans mylinks_submit.html:
Vers la Ligne 63:

<{/if}>              </td>
          </
tr>
[
color=CC0000]<!-- Hack SecurityImage by Dugris-->
          <
tr>
            <
td class="head"><{$lang_securityimage}></td>
            <
td class="even"><{$input_securityimage}></td>
          </
tr>
<!-- 
Hack SecurityImage by Dugris-->[/color]
     </
table>

Posté le : 22/07/2007 14:16
_________________
www.tdmxoops.net
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Développeur
Inscrit:
22/02/2004 20:41
Messages: 961
Pour Xmovie 2.56


Dans submit.php:
Vers la Ligne 52:

if (!empty($_POST['submit'])) {
[
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
        
redirect_header'submit.php' 1_SECURITYIMAGE_ERROR ) ;
    }
    
//Hack SecurityImage by Dugris[/color]
    
$submitter = !empty($xoopsUser) ? $xoopsUser->getVar('uid') : 0;


Vers la Ligne 351:
$xoopsTpl->assign('lang_cancel'_CANCEL);
        [
color=CC0000]//Hack SecurityImage by Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') ) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if ( 
$security_image->render() ) {
            
$xoopsTpl->assign('lang_securityimage'_SECURITYIMAGE_CODE);
            
$xoopsTpl->assign('input_securityimage' $security_image->render() );
        }
    }
    
//Hack SecurityImage by Dugris[/color]
    
$xoopsTpl->assign( array( "xoops_module_header" => "<link rel="stylesheet" type="text/css" media="all" href="".XOOPS_URL."/modules/x_movie/index.css" />" $xoopsTpl->get_template_vars"xoops_module_header" ) , "xoops_pagetitle" => _MI_X_MOVIE_SMNAME1 ) ) ;


Dans x_movie_submit.html:
Vers la Ligne 261:

<{/if}>              </td>
          </
tr>
[
color=CC0000]<!-- Hack SecurityImage by Dugris-->
          <
tr>
            <
td class="head"><{$lang_securityimage}></td>
            <
td class="even"><{$input_securityimage}></td>
          </
tr>
<!-- 
Hack SecurityImage by Dugris-->[/color]
     </
table>

Posté le : 22/07/2007 14:26
_________________
www.tdmxoops.net
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Supporter Xoops
Inscrit:
27/12/2005 19:19
Messages: 6536
Merci Kraven ! Cela évitera d'embêter Dugris

@+

Posté le : 22/07/2007 15:51
_________________
Prestataires Xoops : http://xoopspro.com - Sourceforge : http://sourceforge.net/projects/xfr/files/
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Développeur
Inscrit:
22/02/2004 20:41
Messages: 961
Derien, si vous avez d'autres modules, dites le moi, j'essaierai.
Par contre, je bug sur xcgal, c'est bizarrement fait

Posté le : 22/07/2007 20:27
_________________
www.tdmxoops.net
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Supporter Xoops
Inscrit:
27/12/2005 19:19
Messages: 6536
Re',

Cela commence à faire une bonne tripotée de captcha :

• sur le site de Dugris :
- News version 1.54
- TellAFriend version 1.03
- Formulaire version 3.23
- Wfdownloads version 3 +
- Wordbook version 1.16
- Newbb version 1.16
- Hack Register
- Hack commentaires

• sur ce topic :
- Block system : "Infos du site"
- Module pages

• sur celui-ci :
- Catads

... sus au spam !

@+

Posté le : 22/07/2007 20:51
_________________
Prestataires Xoops : http://xoopspro.com - Sourceforge : http://sourceforge.net/projects/xfr/files/
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Supporter Xoops
Inscrit:
02/10/2004 14:09
Messages: 369
Rajoute : liaise en 1.26

Les fichiers à modifier sont :
-> index.php : ajout à la ligne 77 (juste après le "else") du code suivant
// Hack SecurityImage by DuGris
    
include_once(XOOPS_ROOT_PATH ."/class/xoopsformloader.php");
    if (
is_object($xoopsUser)) {
        if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() && 'system' != $xoopsModule->getVar('dirname') && !$xoopsUser->isAdmin($com_modid) ) {
            
redirect_header'javascript:history.go(-1)' 1_SECURITYIMAGE_ERROR ) ;
        }
    } else {
        if ( 
defined('SECURITYIMAGE_INCLUDED')     && !SecurityImage::CheckSecurityImage() ) {
            
redirect_header'javascript:history.go(-1)' 1_SECURITYIMAGE_ERROR ) ;
        }
    }
    
// Hack SecurityImage by DuGris


-> include/form_render.php : ajout à la ligne 61 (après la ligne $form_output->addElement(new XoopsFormHidden('form_id', $form->getVar('form_id')));)du code suivant
// Hack SecurityImage by DuGris
if (is_object($xoopsUser)) {
    if ( 
defined('SECURITYIMAGE_INCLUDED') && 'system' != $xoopsModule->getVar('dirname') && !$xoopsUser->isAdmin($com_modid) ) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if (
$security_image->render()) {
            
$form_output->addElement($security_imagetrue);
        }
    }
} else {
    if ( 
defined('SECURITYIMAGE_INCLUDED') ) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if (
$security_image->render()) {
            
$form_output->addElement($security_imagetrue);
        }
    }
}
// Hack SecurityImage by DuGris


Et au pire, j'avais fait un pack à une époque avec juste les fichiers modifiés : Securityimage_pack.zip

Voilou

Posté le : 23/07/2007 09:52
Transférer la contribution vers d'autres applications Transférer


Re: Security Image Weblinks
Supporter Xoops
Inscrit:
27/12/2005 19:19
Messages: 6536
Merci !

- News version 1.54
- TellAFriend version 1.03
- Formulaire version 3.23
- Wfdownloads version 3 +
- Wordbook version 1.16
- Newbb version 1.16
- Hack Register
- Hack commentaires

- Block system : "Infos du site"
- Module pages

- Catads

- Weblinks 0,96
- Mydownloads 1.43
- Mylinks 1.1
- Xmovie 2.56
- Liaise 1.26

- ... xcgal en cours

La traque continue !

Posté le : 23/07/2007 11:42
_________________
Prestataires Xoops : http://xoopspro.com - Sourceforge : http://sourceforge.net/projects/xfr/files/
Transférer la contribution vers d'autres applications Transférer



 Haut   Précédent   Suivant
(1) 2 3 4 ... 10 »