http://www.cnns.net/article/db/3758.htm
http://www.cnns.net/article/db/3757.htm
In each page,
first section is talk about source,
last section is the solution.
FYI
// If there is a category, add a New Link
echo"<table width='100%' border='0' cellspacing='1' class='outer'>"
."<tr class=\"odd\"><td>";
echo "<form method=post action=index.php>\n";
echo "<h4>"._MD_ADDNEWLINK."</h4><br />\n";
echo "<table width=\"80%\"><tr>\n";
echo "<td align=\"right\">"._MD_SITETITLE."</td><td>";
echo "<input type=text name=title size=50 maxlength=100>";
echo "</td></tr><tr><td align=\"right\" nowrap>"._MD_SITEURL."</td><td>";
echo "<input type=text name=url size=50 maxlength=250 value=\"http://\">";
echo "</td></tr>";
echo "<tr><td align=\"right\" nowrap>"._MD_CATEGORYC."</td><td>";
$mytree->makeMySelBox("title", "title");
echo "<tr><td align=\"right\" valign=\"top\" nowrap>"._MD_DESCRIPTIONC."</td><td
width=540>\n";
xoopsCodeTarea("description",60,8);
xoopsSmilies("description");
//echo "<textarea name=description cols=60 rows=5></textarea>\n";
echo "</td></tr>\n";
/**
* prepare HTML for output of the smiley list.
*
* @return string HTML
*/
function _renderSmileys()
{
$myts =& MyTextSanitizer::getInstance();
$smiles =& $myts->getSmileys();
$ret = '';
if (empty($smileys)) {
$db =& Database::getInstance();
if ($result = $db->query('SELECT * FROM '.$db->prefix('smiles').' WHERE display=1')) {
while ($smiles = $db->fetchArray($result)) {
$ret .= "<img onclick='xoopsCodeSmilie(\"".$this->getName()."\", \" ".$smiles['code']." \");' onmouseover='style.cursor=\"hand\"' src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'], ENT_QUOTES)."' alt='' />";
[color=0000FF]$ret .= "\n"; /color]
}
}
} else {
$count = count($smiles);
for ($i = 0; $i < $count; $i++) {
if ($smiles[$i]['display'] == 1) {
$ret .= "<img onclick='xoopsCodeSmilie(\"".$this->getName()."\", \" ".$smiles[$i]['code']." \");' onmouseover='style.cursor=\"hand\"' src='".XOOPS_UPLOAD_URL."/".$myts->oopsHtmlSpecialChars($smiles['smile_url'])."' border='0' alt='' />";
}
}
}
$ret .= " [<a href='#moresmiley' onclick='javascript:openWithSelfMain(\"".XOOPS_URL."/misc.php?action=showpopups&type=smilies&target=".$this->getName()."\",\"smilies\",300,475);'>"._MORE."</a>]";
return $ret;
}
}
?>
echo "<tr valign='top'><td class='head' width='25%'>"._PM_MESSAGEC."</td>";
echo "<td class='even' [color=0000FF]width='540'[/color]>";
xoopsCodeTarea("message",37,8);
xoopsSmilies("message");
echo "</td>";
echo "</tr>";
<tr align='left'>
<td class='head' valign='top' nowrap='nowrap'>". _MD_MESSAGEC ."
</td>
<td class='odd' width='540'>";
xoopsCodeTarea("message");
if ( !empty($isreply) && isset($hidden) && $hidden != "" ) {
echo "<input type='hidden' name='isreply' value='1' />";
echo "<input type='hidden' name='hidden' id='hidden' value='$hidden' />
<input type='button' name='quote' class='formButton' value='"._MD_QUOTE."'
onclick='xoopsGetElementById("message").value=xoopsGetElementById("message").value +
xoopsGetElementById("hidden").value; xoopsGetElementById("hidden").value="";' /><br />";
}
xoopsSmilies("message");
echo "</td></tr>
// ------------------------------------------------------------------------ //
if ( !preg_match("/index.php/", $HTTP_SERVER_VARS['PHP_SELF']) ) {
exit("access denied");
}
include XOOPS_ROOT_PATH."/include/xoopscodes.php";
if(!isset($submit_page)){
$submit_page = $HTTP_SERVER_VARS['PHP_SELF'];
}
?>
<table><tr><td width=540>
<form action='<?php echo $submit_page;?>' method='post' name='coolsus'>
<?php
echo "<p>[b]"._AM_TITLE."[/b]<br />";
echo "<input type='text' name='title' id='title' value='";
if(isset($title)){
echo $title;
}
echo "' size='70' maxlength='80' /><br />";
echo "<a href='javascript: justReturn()' onclick='xoopsCodeSmilie("hometext", "[picnews@index]
");'>";
/**
* prepare HTML for output of the smiley list.
*
* @return string HTML
*/
function _renderSmileys()
{
$myts =& MyTextSanitizer::getInstance();
$smiles =& $myts->getSmileys();
$ret = '';
if (empty($smileys)) {
$db =& Database::getInstance();
if ($result = $db->query('SELECT * FROM '.$db->prefix('smiles').' WHERE display=1')) {
while ($smiles = $db->fetchArray($result)) {
$ret .= "<img onclick='xoopsCodeSmilie(\"".$this->getName()."\", \" ".$smiles['code']." \");' onmouseover='style.cursor=\"hand\"' src='".XOOPS_UPLOAD_URL."/".htmlspecialchars($smiles['smile_url'], ENT_QUOTES)."' alt='' />";
}
}
} else {
$count = count($smiles);
for ($i = 0; $i < $count; $i++) {
if ($smiles[$i]['display'] == 1) {
$ret .= "<img onclick='xoopsCodeSmilie(\"".$this->getName()."\", \" ".$smiles[$i]['code']." \");' onmouseover='style.cursor=\"hand\"' src='".XOOPS_UPLOAD_URL."/".$myts->oopsHtmlSpecialChars($smiles['smile_url'])."' border='0' alt='' />";
}
}
}
$ret .= " [<a href='#moresmiley' onclick='javascript:openWithSelfMain(\"".XOOPS_URL."/misc.php?action=showpopups&type=smilies&target=".$this->getName()."\",\"smilies\",300,475);'>"._MORE."</a>]";
return $ret;
}
}
?>
for ($i = 0; $i < $count; $i++) {
if ($smiles[$i]['display'] == 1) {
$ret .= "getName()."\", \" ".$smiles[$i]['code']." \");' onmouseover='style.cursor=\"hand\"' src='".XOOPS_UPLOAD_URL."/".$myts->oopsHtmlSpecialChars($smiles['smile_url'])."' border='0' alt='' />";
$iii++;
$ret .= "\n";
}
if ($i%15==14) $ret .="\n";//add a line
if ($iii == 15 ) {
$ret .="\n"; //add a empty line (another hack way)
$ret .= "\n\n";
}
}
}
$ret .= "\n";
// * $ret .= "
\n\n";
$ret .= " [getName()."\",\"smilies\",300,475);'>"._MORE."]";
return $ret;
}
}
?>
kjs222 wrote:
I found a quick fix. The problem is caused by an odd deletion of rows in the group_permissions table.
If you go into that table, you'll it probably has no rows that look like this:
gperm_id = 2509 (primary table ID)
gperm_groupid = 1 (the group # with this permission - 1 is required to see in admin)
gperm_itemid = 7 (this is the image category ID, see img category table)
gperm_modid = 1 (this should be 1 for you too - aka System Module)
gperm_name = imgcat_read
You just need to insert one such row for each itemid (aka image category). Everything else should be in-tact. Not sure what causes the problem, but hopefully this should solve it for you.
If you are unsure of the syntax, you can also go to your image manager, create a new category, and then look at it in the gperm table... then you can just duplicate the entry for each itemid.
Best wishes,
Keith
onokazu wrote:
Sorry that I hadn't post anything here, but as knight said, this bug has been fixed on the CVS..
Emilien wrote:
Hi !
The version of newbb include in XOOPs is now out of date !! They released the 2.0.6 version of phpBB.
The 2.2 is on the way, are you willing update that version ? Do you want me to try to do such things ?
My idea:
- Modify phpBB templates to make it enter in the XOOPS template.
- Link bitween both user system...
Why ?
- More options
- More permissions
sunsnapper wrote:
In fact, the Spanish support site puts the center-left and center-right blocks above the rest of the content... using x2t theme.
http://www.esxoops.com/modules/news/