Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
ncphp
/
mcClasses
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 18e87fbb
authored
May 15, 2012
by
meier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#141
1 parent
fe72102f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
5 deletions
mcPUIX/class_Converter.inc.php
mcPUIX/mcPUIX.xsl
mcPUIX/class_Converter.inc.php
View file @
18e87fb
...
...
@@ -6,7 +6,7 @@
* Window - Preferences - PHPeclipse - PHP - Code Templates
*/
class
Converter
{
private
static
$LineBreaks
=
array
(
"
\r
"
,
"
\r\n
"
,
"
\n
"
);
private
static
$Specials
=
array
(
'&'
=>
''
,
''
=>
''
,
...
...
@@ -65,7 +65,25 @@ class Converter{
public
static
function
StringToUrl
(
$param_Url
)
{
return
htmlentities
(
$param_Url
);
}
/**
*
* function returns an cleared string/array from line breaks ("\r", "\r\n", "\n")
*
* @param mixed $param_value
* @param string $param_replaceWith, default ""
* @return mixed - cleared String/array
*/
public
static
function
replaceLineBreaks
(
$param_value
,
$param_replaceWith
=
''
){
$return_value
=
$param_value
;
if
(
is_array
(
$return_value
)){
foreach
(
$return_value
as
$key
=>
&
$value
){
$value
=
self
::
replaceLineBreaks
(
$value
,
$param_replaceWith
);
}
}
else
{
$return_value
=
str_replace
(
self
::
$LineBreaks
,
''
,
$return_value
);
}
return
$return_value
;
}
}
...
...
mcPUIX/mcPUIX.xsl
View file @
18e87fb
...
...
@@ -37,7 +37,7 @@
<xsl:with-param
name=
"param_inputBE"
><xsl:value-of
select=
"$param_inputBE"
/></xsl:with-param>
</xsl:apply-templates>
</td>
</tr>
</tr>
</xsl:if>
<tr>
<td>
...
...
@@ -216,7 +216,7 @@
<input
type=
"hidden"
name=
"{$var_formpath}"
value=
"{@value}"
/>
<xsl:if
test=
"@show=1"
><xsl:value-of
select=
"@value"
/></xsl:if>
</xsl:when>
<xsl:when
test=
"@type='text'"
>
<xsl:when
test=
"@type='text'"
>
4
<!-- <textarea name="{$param_inputBE}[{@objvar}]" class="width" cols="40" rows="20">-->
<textarea
name=
"{$var_formpath}"
class=
"width"
cols=
"40"
rows=
"20"
>
<xsl:value-of
select=
"."
/>
...
...
@@ -334,4 +334,4 @@
</span>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
</xsl:stylesheet>
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
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 post a comment