Changeset 1156 in ExiteCMS


Ignore:
Timestamp:
12/02/07 16:23:17 (4 years ago)
Author:
hverton
Message:

removed descript() calls, stripped way to much html
fixed not being able to save a new newsletter after a preview

File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/common/newsletters/php-files/modules/newsletters/newsletters.php

    r1074 r1156  
    9191    // save or copy a newsletter 
    9292    if (isset($_POST['copy'])) unset($newsletter_id); 
    93     $subject = addslash(descript($_POST['subject'])); 
    94     $content = addslash(descript($_POST['content'])); 
    95     if (isset($newsletter_id)) { 
     93    $subject = addslash($_POST['subject']); 
     94    $content = addslash($_POST['content']); 
     95    if (isset($newsletter_id) && $newsletter_id) { 
    9696        $result = dbquery("UPDATE ".$db_prefix."newsletters SET newsletter_subject='$subject', newsletter_content='$content', newsletter_format='".$_POST['format']."' WHERE newsletter_id='$newsletter_id'"); 
    9797        $variables['message'] = $locale['nl414']; 
     
    381381 
    382382    if (isset($_POST['preview'])) { 
    383         $subject = stripslashes(descript($_POST['subject'])); 
     383        $subject = stripslashes($_POST['subject']); 
    384384        $subject = str_replace("{:USER_NAME:}", "<span style='font-family:monospace;color:red;font-size:12px'>".$userdata['user_name']."</span>", $subject); 
    385         $content = stripslashes(descript($_POST['content'])); 
     385        $content = stripslashes($_POST['content']); 
    386386        $content = str_replace("{:USER_NAME:}", "<span style='font-family:monospace;color:red;font-size:12px'>".$userdata['user_name']."</span>", $content); 
    387387        $content = str_replace("{:USER_ID:}", "<span style='font-family:monospace;color:red;font-size:12px'>".$userdata['user_id']."</span>", $content); 
Note: See TracChangeset for help on using the changeset viewer.