other comments icon when a comment is present
Posted: 06 Jun 2011, 14:08
excuse my english. (translated by Google)
Stats:
- Joomla v1.6.3
- Phoca Gallery v3.0.0. rc5 for Joomla 1.6
I know it was already some post on the subject, but most of these were related to the JComments or facebook version.
But since JComments currently not available for 1.6 is the standard I wanted something Comment variant conversion.
If a comment is available for the image to display a different icon: Plan. (See picture)

In part, I have it already. Different icons already in the "assets directory packed. Only when the DB query, I'm not really continue. Somehow he is in the wrong table (_phocagallery) and yes I need the values from the table (_phocagallery_comments).
How can I query this table, so it must go as the modal box, too, this table queries. In this case, yes, the file ".. / components / com_phocagallery / views / comment / tmpl / default.php" is used.
Here's the "experiment"
(In file .. / components / com_phocagallery / views / category / tmpl / default.php):
And here is the original line 429-438
(From file .. / components / com_phocagallery / views / category / tmpl / default.php):
Furthermore, I would like if you go with the mouse over the icon, an adapted text appears in the "title" field. (As seen on the two pictures)


But here the same problem as stated above. Wrong table.
Ideally, any comments right in the Title field, then read out from the DB. That something is clearly not every browser I realize, but I think it's beautiful.
One would like to see what was written on mouseover.
My attempt (same php file):
Original line 410-411:
Maybe someone can give me on these little "problems" a little helping hand ...
Thanks in advance
Stats:
- Joomla v1.6.3
- Phoca Gallery v3.0.0. rc5 for Joomla 1.6
I know it was already some post on the subject, but most of these were related to the JComments or facebook version.
But since JComments currently not available for 1.6 is the standard I wanted something Comment variant conversion.
If a comment is available for the image to display a different icon: Plan. (See picture)
In part, I have it already. Different icons already in the "assets directory packed. Only when the DB query, I'm not really continue. Somehow he is in the wrong table (_phocagallery) and yes I need the values from the table (_phocagallery_comments).
How can I query this table, so it must go as the modal box, too, this table queries. In this case, yes, the file ".. / components / com_phocagallery / views / comment / tmpl / default.php" is used.
Here's the "experiment"
(In file .. / components / com_phocagallery / views / category / tmpl / default.php):
Code: Select all
echo ' >';
// If you go from RSS or administration (e.g. jcomments) to category view, you will see already commented image (animated icon)
$cimgid = JRequest::getVar( 'cimgid', 0, '', 'int');
if($cimgid > 0) {
echo JHTML::_('image', 'components/com_phocagallery/assets/images/icon-comment-a.jpg', JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE'));
} else {
$commentImg = ($this->tmpl['externalcommentsystem'] == 2) ? 'icon-comment-fb-small' : 'icon-comment';
if ($value->id != 138) {
echo JHTML::_('image', 'components/com_phocagallery/assets/images/icon-comment-a.png', JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE'));
} else {
echo JHTML::_('image', 'components/com_phocagallery/assets/images/icon-comment-b.png', JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE'));
}
}
(From file .. / components / com_phocagallery / views / category / tmpl / default.php):
Code: Select all
echo ' >';
// If you go from RSS or administration (e.g. jcomments) to category view, you will see already commented image (animated icon)
$cimgid = JRequest::getVar( 'cimgid', 0, '', 'int');
if($cimgid > 0) {
echo JHTML::_('image', 'components/com_phocagallery/assets/images/icon-comment-a.gif', JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE'));
} else {
$commentImg = ($this->tmpl['externalcommentsystem'] == 2) ? 'icon-comment-fb-small' : 'icon-comment';
echo JHTML::_('image', 'components/com_phocagallery/assets/images/'.$commentImg.'.'.$this->tmpl['formaticon'], JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE'));
}
Furthermore, I would like if you go with the mouse over the icon, an adapted text appears in the "title" field. (As seen on the two pictures)


But here the same problem as stated above. Wrong table.
Ideally, any comments right in the Title field, then read out from the DB. That something is clearly not every browser I realize, but I think it's beautiful.
One would like to see what was written on mouseover.
My attempt (same php file):
Code: Select all
if ($value->id != 138) {
echo ' <a '.$tmplClass.' title="Es wurde noch kein Kommentar geschrieben"'
.' href="'. JRoute::_('index.php?option=com_phocagallery&view=comment&catid='.$this->category->slug.'&id='.$value->slug.$tmplCom.'&Itemid='. JRequest::getVar('Itemid', 0, '', 'int') ).'"';
} else {
echo ' <a '.$tmplClass.' title="'.$value->id.' - '.$value->imgid.' - '.$value->cimgig.' ---------- hier könnten dann die Kommentare stehen --------- von: Benutzername Kommentar 1 -------- von: Benutzername Kommentar 2 --------- u.s.w."'
.' href="'. JRoute::_('index.php?option=com_phocagallery&view=comment&catid='.$this->category->slug.'&id='.$value->slug.$tmplCom.'&Itemid='. JRequest::getVar('Itemid', 0, '', 'int') ).'"';
}
Code: Select all
echo ' <a '.$tmplClass.' title="'.JText::_('COM_PHOCAGALLERY_COMMENT_IMAGE').'"'
.' href="'. JRoute::_('index.php?option=com_phocagallery&view=comment&catid='.$this->category->slug.'&id='.$value->slug.$tmplCom.'&Itemid='. JRequest::getVar('Itemid', 0, '', 'int') ).'"';
Thanks in advance