sNews 1.7 (current stable version) > Patches/fixes

\r\n bug when article saving error occurs.


if article name or sef is already in db or title was left empty, then an error notification is generated.
However, the end of line chars are displayed in the text box of the editor as per report here

To rectify (supplied by Joost)

--- Quote from: Joost on February 23, 2009, 11:31:25 am ---A patch:
Replace in function process ( in snews.php)

--- Code: (old code) ---<?php
case 'admin_article':
$_SESSION[_SITE.'temp']['title'] = $title;
$_SESSION[_SITE.'temp']['seftitle'] = $seftitle;
$_SESSION[_SITE.'temp']['text'] = $text;

--- End code ---

--- Code: (NEW code) ---<?php
case 'admin_article':
$_SESSION[_SITE.'temp']['title'] = $_POST['title'];
$_SESSION[_SITE.'temp']['seftitle'] = $_POST['seftitle'];
$_SESSION[_SITE.'temp']['text'] = $_POST['text'];

--- End code ---
Note: If magic_quotes_gpc is turned on, add the following to .htaccess:

--- Code: ---php_flag magic_quotes_gpc OFF

--- End code ---

--- End quote ---


[0] Message Index

Go to full version