Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
I
ISPConfig 3
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
479
Issues
479
List
Boards
Labels
Service Desk
Milestones
Merge Requests
22
Merge Requests
22
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ISPConfig
ISPConfig 3
Commits
2b81b8f6
Commit
2b81b8f6
authored
Sep 06, 2011
by
tbrehm
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed: FS#1714 - Email autoresponder eliminates <newline>
parent
27865260
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
7 deletions
+8
-7
interface/lib/classes/tform.inc.php
interface/lib/classes/tform.inc.php
+7
-6
interface/lib/classes/tform_actions.inc.php
interface/lib/classes/tform_actions.inc.php
+1
-1
No files found.
interface/lib/classes/tform.inc.php
View file @
2b81b8f6
...
...
@@ -600,7 +600,7 @@ class tform {
* @param record = Datensatz als Array
* @return record
*/
function
encode
(
$record
,
$tab
)
{
function
encode
(
$record
,
$tab
,
$dbencode
=
true
)
{
global
$app
;
if
(
!
is_array
(
$this
->
formDef
[
'tabs'
][
$tab
]))
$app
->
error
(
"Tab is empty or does not exist (TAB:
$tab
)."
);
...
...
@@ -614,14 +614,14 @@ class tform {
switch
(
$field
[
'datatype'
])
{
case
'VARCHAR'
:
if
(
!@
is_array
(
$record
[
$key
]))
{
$new_record
[
$key
]
=
(
isset
(
$record
[
$key
]))
?
$
app
->
db
->
quote
(
$record
[
$key
])
:
''
;
$new_record
[
$key
]
=
(
isset
(
$record
[
$key
]))
?
$
record
[
$key
]
:
''
;
}
else
{
$new_record
[
$key
]
=
implode
(
$field
[
'separator'
],
$record
[
$key
]);
}
break
;
case
'TEXT'
:
if
(
!
is_array
(
$record
[
$key
]))
{
$new_record
[
$key
]
=
$
app
->
db
->
quote
(
$record
[
$key
])
;
$new_record
[
$key
]
=
$
record
[
$key
]
;
}
else
{
$new_record
[
$key
]
=
implode
(
$field
[
'separator'
],
$record
[
$key
]);
}
...
...
@@ -658,7 +658,7 @@ class tform {
//if($key == 'refresh') die($record[$key]);
break
;
case
'DOUBLE'
:
$new_record
[
$key
]
=
$
app
->
db
->
quote
(
$record
[
$key
])
;
$new_record
[
$key
]
=
$
record
[
$key
]
;
break
;
case
'CURRENCY'
:
$new_record
[
$key
]
=
str_replace
(
","
,
"."
,
$record
[
$key
]);
...
...
@@ -686,8 +686,9 @@ class tform {
$this
->
errorMessage
.
=
$this
->
wordbook
[
$errmsg
]
.
"<br />
\r\n
"
;
}
}
//* Add slashes to all records, when we encode data which shall be inserted into mysql.
if
(
$dbencode
==
true
)
$new_record
[
$key
]
=
$app
->
db
->
quote
(
$new_record
[
$key
]);
}
}
return
$new_record
;
...
...
interface/lib/classes/tform_actions.inc.php
View file @
2b81b8f6
...
...
@@ -537,7 +537,7 @@ class tform_actions {
if
(
!
$record
=
$app
->
db
->
queryOneRecord
(
$sql
))
$app
->
error
(
$app
->
lng
(
'error_no_view_permission'
));
}
else
{
// $record = $app->tform->encode($_POST,$this->active_tab);
$record
=
$app
->
tform
->
encode
(
$this
->
dataRecord
,
$this
->
active_tab
);
$record
=
$app
->
tform
->
encode
(
$this
->
dataRecord
,
$this
->
active_tab
,
false
);
}
$this
->
dataRecord
=
$record
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment