Page 1 of 1
[SOLVED]How to display youtube in a category description?
Posted: 06 Apr 2012, 11:13
by borus
Hello.
Trying to embed youtube code in phoca category description, but it doesn't appears in a category view. Simple text description can be displayed, but youtube cann't. Text filters are switched off in global configuration parameters.
What can it be?
Re: How to display youtube in a category description?
Posted: 06 Apr 2012, 15:25
by xonder
Hi
Think it's the same as here
Phoca Download Topic
lg Christian
Re: How to display youtube in a category description?
Posted: 07 Apr 2012, 07:27
by borus
thank you, i don't know German and it's difficult to understand even with Chrome translator

Re: How to display youtube in a category description?
Posted: 07 Apr 2012, 10:20
by xonder
Hi
Sorry ... my english is also very bad
ok ... in phoca gallery you can open this file (FTP)
/components/com_phocagallery/views/category/tmpl/default.php
Change this code ....
Code: Select all
// Category Description
if (isset($this->category->description) && $this->category->description != '' ) {
echo '<div class="pg-category-view-desc'.$this->params->get( 'pageclass_sfx' ).'">';
echo $this->category->description.'</div>'. "\n";
}
... to this code
Code: Select all
// Category Description
if (isset($this->category->description) && $this->category->description != '' ) {
echo '<div class="pg-category-view-desc'.$this->params->get( 'pageclass_sfx' ).'">';
echo JHTML::_('content.prepare', $this->category->description);
echo '</div>';
}
Now you can display Youtube videos with the
phoca download plugin code
e.g.
Code: Select all
{phocadownload view=youtube|youtubewidth=500|youtubeheight=306|url=http://www.youtube.com/watch?v=xxxxxxxxxxx}
I hope ... jan make a update of the
JHTML::_ code in the next release
lg christian
Re: How to display youtube in a category description?
Posted: 11 Apr 2012, 00:03
by Jan
Hi, thank you for the guide, will be added to next release.
Jan
Re: How to display youtube in a category description?
Posted: 11 Apr 2012, 09:46
by borus
xonder wrote:Hi...
Thank you, xonder.
I did as you said. It doesn't work. Why?
Here is my code for PG category description:
Code: Select all
{phocadownload view=youtube|youtubewidth=560|youtubeheight=315|url=http://www.youtube.com/watch?v=WJ1ur7Ce5hU}
Do I have to create something in Phoca Download Component also?
Re: How to display youtube in a category description?
Posted: 12 Apr 2012, 09:54
by borus
I've found that in my template folder was unchanged copy of that default.php which was blocking all changes made in original file

Re: [SOLVED]How to display youtube in a category description
Posted: 29 Jun 2012, 16:37
by Jan
Will be set in 3.2.1
Jan
Re: [SOLVED]How to display youtube in a category description
Posted: 28 Oct 2012, 09:40
by jeroenkl
Hello,
This sollution works also great with version 2.8.1. (Joomla 1.5). I used this method to combine the power of Phocagallery with the beauty of Joomlashines Imageshow. Exacmple:
http://www.bestemmingonbekend.nl/index. ... porto-2012
/components/com_phocagallery/views/category/tmpl/default.php
Change this code ....
Code: Select all
// Image, description
echo '<div class="contentpane'.$this->params->get( 'pageclass_sfx' ).'">';
if ( @$this->tmpl['image'] || @$this->category->description ) {
echo '<div class="contentdescription'.$this->params->get( 'pageclass_sfx' ).'">';
if ( isset($this->tmpl['image']) ) {
echo $this->tmpl['image'];
}
echo $this->category->description.'</div>'. "\n";
}
echo '</div>';
into
Code: Select all
// Category Description
if (isset($this->category->description) && $this->category->description != '' ) {
echo '<div class="pg-category-view-desc'.$this->params->get( 'pageclass_sfx' ).'">';
echo JHTML::_('content.prepare', $this->category->description);
echo '</div>';
}
Regards,
Jeroen Kleiberg
http://www.bestemmingonbekend.nl