charset ?

Phoca Gallery - image gallery extension
morgane2911
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 08 May 2018, 08:14

charset ?

Post by morgane2911 »

Hello

I have a problem with phoca gallery 4.3.10. My joomla is 3.8.7.
I have a problem with the display in the description of the picture under detail. Phoca displays \' instead of '
How can I fix this problem.

https://jmaubert.ch/index.php/galerie/c ... id=1&pid=1

phoca gallery 4.3.10. joomla 3.8.7

Thank you for your reply.
Martine
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49138
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: charset ?

Post by Jan »

Hi, try to open this file:

components\com_phocagallery\views\category\view.html.php

line cca 1265

and change
FROM:

Code: Select all

switch ($this->tmpl['photoswipe_display_caption']) {
					case 0:
						$this->items[$iS]->photoswipecaption = '';
					break;
					
					case 2:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(addslashes( $this->items[$iS]->description));
					break;
					
					case 3:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(addslashes($this->items[$iS]->title));
						if ($this->items[$iS]->description != '') {
							$this->items[$iS]->photoswipecaption .='<br />' .PhocaGalleryText::strTrimAll(addslashes($this->items[$iS]->description));
						}
					break;
					
					case 1:
					default:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(addslashes($this->items[$iS]->title));
					break;
				}
TO:

Code: Select all

switch ($this->tmpl['photoswipe_display_caption']) {
					case 0:
						$this->items[$iS]->photoswipecaption = '';
					break;
					
					case 2:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(( $this->items[$iS]->description));
					break;
					
					case 3:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(($this->items[$iS]->title));
						if ($this->items[$iS]->description != '') {
							$this->items[$iS]->photoswipecaption .='<br />' .PhocaGalleryText::strTrimAll(($this->items[$iS]->description));
						}
					break;
					
					case 1:
					default:
						$this->items[$iS]->photoswipecaption = PhocaGalleryText::strTrimAll(($this->items[$iS]->title));
					break;
				}
And let me know if this is OK, if yes, I will change it in the next version.

Jan
If you find Phoca extensions useful, please support the project
morgane2911
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 08 May 2018, 08:14

Re: charset ?

Post by morgane2911 »

Hi, it's perfect ;-)

Thank you and have a good day
Martine
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49138
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: charset ?

Post by Jan »

Ok, I will set it in next version.

Jan
If you find Phoca extensions useful, please support the project
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49138
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: charset ?

Post by Jan »

Hi, should be OK in version 4.3.11
https://www.phoca.cz/news/1003-phoca-ga ... 1-released

Jan
If you find Phoca extensions useful, please support the project
Post Reply