Ignore:
Timestamp:
03/29/10 15:37:29 (2 years ago)
Author:
bogdan2412
Message:

Updated with changes from live.

  • Updated SMF to 1.1.11
  • Added Summify to site and forum
  • Small change to job detail view
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/smf/Sources/Post.php

    r1048 r1121  
    66* Open-Source Project Inspired by Zef Hemel (zef@zefhemel.com)                    * 
    77* =============================================================================== * 
    8 * Software Version:           SMF 1.1.10                                          * 
     8* Software Version:           SMF 1.1.11                                          * 
    99* Software by:                Simple Machines (http://www.simplemachines.org)     * 
    1010* Copyright 2006-2009 by:     Simple Machines LLC (http://www.simplemachines.org) * 
     
    106106        // Posting an event? 
    107107        $context['make_event'] = isset($_REQUEST['calendar']); 
    108  
    109         // Generate a visual verification code to make sure the user is no bot. 
    110         $context['visual_verification'] = (empty($modSettings['disable_visual_verification']) || $modSettings['disable_visual_verification'] != 1) && ($user_info['is_guest'] && $modSettings['visual_verification_guest_post']); 
    111         if ($context['visual_verification']) 
    112         { 
    113                 loadLanguage('Login'); 
    114  
    115                 $context['use_graphic_library'] = in_array('gd', get_loaded_extensions()); 
    116                 $context['verificiation_image_href'] = $scripturl . '?action=verificationcode;rand=' . md5(rand()); 
    117  
    118                 // Only generate a new code if one hasn't been set yet 
    119                 if (!isset($_SESSION['visual_verification_code'])) 
    120                 { 
    121                         // Skip I, J, L, O and Q. 
    122                         $character_range = array_merge(range('A', 'H'), array('K', 'M', 'N', 'P'), range('R', 'Z')); 
    123  
    124                         // Generate a new code. 
    125                         $_SESSION['visual_verification_code'] = ''; 
    126                         for ($i = 0; $i < 5; $i++) 
    127                                 $_SESSION['visual_verification_code'] .= $character_range[array_rand($character_range)]; 
    128                 } 
    129         } 
    130  
    131108 
    132109        // You must be posting to *some* board. 
     
    637614                                                continue; 
    638615                                        $context['current_attachments'][] = array( 
    639                                                 'name' => $row['filename'], 
     616                                                'name' => htmlspecialchars($row['filename']), 
    640617                                                'id' => $row['ID_ATTACH'] 
    641618                                        ); 
     
    729706                        if ($attachment['filesize'] >= 0 && !empty($modSettings['attachmentEnable'])) 
    730707                                $context['current_attachments'][] = array( 
    731                                         'name' => $attachment['filename'], 
     708                                        'name' => htmlspecialchars($attachment['filename']), 
    732709                                        'id' => $attachment['ID_ATTACH'] 
    733710                                ); 
     
    14151392                $_POST['email'] = addslashes($user_info['email']); 
    14161393        } 
    1417  
    1418         // Check whether the visual verification code was entered correctly. 
    1419         if ((empty($modSettings['disable_visual_verification']) || $modSettings['disable_visual_verification'] != 1) && ($user_info['is_guest'] && $modSettings['visual_verification_guest_post'])) 
    1420         { 
    1421                 if ((empty($_REQUEST['visual_verification_code']) || strtoupper($_REQUEST['visual_verification_code']) !== $_SESSION['visual_verification_code'])) 
    1422                 { 
    1423                         $_SESSION['visual_errors'] = isset($_SESSION['visual_errors']) ? $_SESSION['visual_errors'] + 1 : 1; 
    1424                         if ($_SESSION['visual_errors'] > 3 && isset($_SESSION['visual_verification_code'])) 
    1425                                 unset($_SESSION['visual_verification_code']); 
    1426  
    1427                         $post_errors[] = 'visual_verification_failed'; 
    1428                 } 
    1429         } 
    1430  
    14311394 
    14321395        // Any mistakes? 
Note: See TracChangeset for help on using the changeset viewer.