Reply to URGENT: Break-lines disappearing.

Your name:

Reply:


Posted by Bruno B B Magalh�es on 01/20/05 20:07

Hi you all,

I am having a very big problem... I have an article module in a system,
when an user creates an article it's parsed (as everything else in the
system) by an input class, after, it is checked for emptily and after
is build an insert query... But the break-lines just disappear... I've
tested right before parsing to the database build query function and
the breaks are there! And the build query function is this:

function insert_query($table='',$values='')
{
if($table != '' && $values != '')
{
foreach($values as $var=>$val)
{
$insert_vars[] = $var;
$insert_vals[] = $val;
}
return $this->query('INSERT INTO '.$table.'
('.implode(',',$insert_vars).') VALUES
(\''.implode('\',\'',$insert_vals).'\') ');
}
else
{
return false;
}
}

And the sanitize function is:

function sanitize($input_data, $sanitize = true)
{
if(is_array($input_data))
{
foreach($input_data as $input_key=>$input_value)
{
$output_data[$input_key] = $this->sanitize($input_value,$sanitize);
}
return $output_data;
}
elseif($sanitize)
{
return addslashes($input_data);
}
else
{
return $input_data;
}
}

Where are the break-lines?!?!? I am really desperate! Please! I am
using MySQL and PHP4.

Regards,
Bruno B B Magalhaes

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация