Thanx Skrol29 for help,
I've tried a lot in the last days but without any result.
It seems that there is no effect when I include a self written function.
- Ok, this is the mysql-table I've created:
<img src="www.netzkompakt.de/sonstiges/andreas/tinybutstrong/tbs_table.jpg">
- This is my tpl-file:
<html>
<head>
</head>
<body>
<table>
<tr><td></td></tr>
<tr>
<td><font></font></td><td><font>[blk1.alter;]</font></td><td><font>[blk1.geschlecht;onsection=showme]</font></td>
</tr>
</table>
</body>
</html>
|
- This is my php-file:
<?php
include_once("../config/config.inc.php");
include_once('tbs_class.php');
$TBS = new clsTinyButStrong ;
$TBS->LoadTemplate('variablen_ersetzen.tpl') ;
$TBS->MergeBlock('blk1','mysql','SELECT * FROM template') ;
mysql_close($db) ;
$TBS->Show() ;
function showme($BlockName,&$CurrRec,&$DetailSrc,$RecNum)
{
if ($BlockName) echo "$CurrRec[0]";
echo "bla";
}
?>
|
As you can see I going to include the function showme which only should give out the string 'bla' if $BlockName exists.
In the html-code I've added 'onsection=showme'.
I've tried a lot of other things that the functions showme should give out, e.g. echo "$CurrRec";, echo "$DetailSrc"; or echo "$RecNum"; , but without any result!
- The result always is
<img src="www.netzkompakt.de/sonstiges/andreas/tinybutstrong/tbs_result.jpg">
It seems that the function doesn't have any effect to the result.
I think it's a beginner fault I do but what's wrong?
How will I be able to manipulate e.g. 'männlich'?
With my function 'showme' I actually expected something like 'männlichbla' -> männlich, cause it's in the table at first row -> bla, cause it's in the function echo "bla";
Mh, would be absolutely nice if you could give me a tip whats mainly wrong, I think I havn't understood the principle.
thanx
glanzlicht