The Phoca Gallery Plugin didnt work

Phoca Gallery plugins - plugins for Phoca Gallery extension
dfsoftware
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 19 Aug 2012, 13:04
Location: Ukraine
Contact:

The Phoca Gallery Plugin didnt work

Post by dfsoftware »

Hi, guys!

I have a problem with using this plugin. I make changes in one Joomla project (which was developed by other man). It (project) work under Joomla 1.5.22 and use next Phoca Gallery components:
- PhocaGallery v2.8.1
- PhocaMaps v1.0.5
- mod_phocagallery_image v2.7.5
- Phoca Gallery Plugin v2.7.7
- Phoca Gallery Slideshow Plugin v2.7.1
- Phoca Maps Plugin v1.1.0
- Button - Phoca Gallery v2.7.1

In articles i try to view image from one of galleries with Phoca Gallery Plugin help. I use next command:
{phocagallery view=category|categoryid=41|imageid=569}
And in article in front-end side i see simple white box with name of image. Mouse over function work fine (background of box change color), but clicking function dont work (simple nothing do not happen ). When i look at code with Firebug help on the image place in article (front-end side), i see next:

Code: Select all

	<div class="phocagallery">
		<div class="phocagallery-box-file pgplugin1" style="height:138px; width:120px;margin: 5px;padding: 5px;">
			<center>
				<div class="phocagallery-box-file-first" style="background: url('/components/com_phocagallery/assets/images/shadow1.gif') 0px 0px no-repeat;height: 118px; width: 118px;">
					<div class="phocagallery-box-file-second">
						<div class="phocagallery-box-file-third">
							<center>
								<a class="highslide" title="trgovina" href="/images/phocagallery/krpanke/thumbs/phoca_thumb_l_trgovina.jpg" onclick="return hs.expand(this, { slideshowGroup: 'groupPl1',  wrapperClassName: 'rounded-white', outlineType : 'rounded-white', dimmingOpacity: 0,  align : 'center',  transitions : ['expand', 'crossfade'], fadeInOut: true });">
									<br>
								</a>
							</center>
						</div>
					</div>
				</div>
			</center>
			<div class="name" style="color: #7a2136 ;font-size:14px;margin-top:5px;text-align:center;">trgovina</div>
		</div>
	</div>
So, how you can see instead of image between "<a href=...." and "</a>" is writen "<br>" HTML tag!!! Where is "<img href...."? :x

I was try to find the way to solve this problem in Internet (on Phoca Gallery forums including) and cant to do it.

I was check all images in this category, it all have created thumbals (s,m, l) and i write correct IDs of image and gallery, also directory with images have needed permitions (777). But just in case for test i was create new category and upload new images, and was create needed thumbals - all checked by manualy. And was try to view one of the images from this category into article:
{phocagallery view=category|categoryid=45|imageid=572}
And againe all the same. :x

Then i try to view all galleries:
{phocagallery view=categories}
All work fine. I enter on my test created category and i was see my images. I was click on every of it and it was viewed as more big images in pop-up window. Its ok. :twisted:

Then i was try to do next:
{phocagallery view=category|categoryid=45|limitstart=0|limitcount=3|enableswitch=1}
And in article from front-end on that place i see in one row three white boxes (in my test category 3 images) with names of images at bottom. And again dont work click function... :x

Also i dont use on this project "F...content" (forgot the name) module about which is warn on this forum. :!:

May be some conflict with other jQuery or Mootools components? I was try to disable one by one used modules in Joomla admin zone - but nothing not changed. :idea:

So, please, help me find how to solve this problem. :?:

Best regards,
Dmitry
dfsoftware
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 19 Aug 2012, 13:04
Location: Ukraine
Contact:

Re: The Phoca Gallery Plugin didnt work

Post by dfsoftware »

One more... Browser view 1 error and 1 warn, then i try view needed article with image:

Resource interpreted as Image but transferred with MIME type application/octet-stream: "http://www.(my domain)/components/com_phocagallery/assets/js/highslide/graphics/zoomout.cur". highslide-full.js:257
hs.extend highslide-full.js:257
hs.createElement highslide-full.js:249
hs.preloadImages highslide-full.js:900


GET _ttp://www.(my domain)/undefined 404 (Not Found) undefined:1
predictad_preloadImages
predictad_teaser_mnger
(anonymous function)
PredictadWindowAddLoadPEvnt.window.onload


May be it can be help to solve my problem?
dfsoftware
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 19 Aug 2012, 13:04
Location: Ukraine
Contact:

Re: The Phoca Gallery Plugin didnt work

Post by dfsoftware »

I was find a new problem which not give ability to normal work for click function (<a href="....... " <br> </a>). The fact is that what when i made mouse over under white box with shadow (where must be placed image), cursor dont accept "pointer" view (its happen when mouse pointer over link ). Its mean (i think) what DIV layer with Phoca Gallery Plugin link on image can have more small z-index as other DIV layer which overlap with it.

I was check CSS styles (with Firebug help) and experiment with CSS rule "z-index: 1000;" for earch DIV layout of Phoca Gallery Plugin (with Firebug help), but cursor didnt accept "pointer" view... :x

Fact - click on image function didnt work, because is not available in front-end. :!:

Any idea? :idea:
dfsoftware
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 19 Aug 2012, 13:04
Location: Ukraine
Contact:

Re: The Phoca Gallery Plugin didnt work

Post by dfsoftware »

Hi, guys! :)

I found the cause of my problem and fix it. :twisted: I think its will be interesting and useful for all Joomla developers that using Phoca Gallery Plugin.

In my current Joomla project (which was made by other man) is some strange, suspect plugin (i think so), which replace all images in articles without 'alt' attribute on '<br>' HTML tag (do you remember the '<br>' HTML tag between '<a href=....' and '</a>' in code above?). I found this with help of numerous experiments in try display image in article with IMG HTML tag help and changing alt attribute in it (order and value).

Attention!!! :!: For succesfull display image in article - the alt attribute (in IMG tag) must be present and must be the first attribute at once after IMG tag.

Example: <img alt="something" href="somelink" />

After that all, i understand what Phoca Gallery Plugin do not write alt attribute inside img HTML tag. That is why instead of image in article, Phoca Gallery Plugin was display white box without image inside.

I was try to make right settings in 'Parameters' -> 'Global Configuration' -> 'General Settings' -> 'ALT Value' (experiment with this options), but this dont work and dont help me in solve my problem. :roll:

When i was decided to make changes directly in Phoca Gallery Plugin main php file ('plugins\content\phocagallery.php'). I did search for '<img' in all file (its finded 6-8 lines) and in every finded line added 'alt="" ' attribute on first place (!!!) at once after img tag.

And after save changes Phoca Gallery Plugin start work normaly in articles! :twisted:

I think this thing will be rewarding experience for every Joomla developer.

Best regards,
Dmitry
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 47865
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: The Phoca Gallery Plugin didnt work

Post by Jan »

Hi, thank you very much for your info, I will take a look at it.

Jan
If you find Phoca extensions useful, please support the project
lucas3001
Phoca Member
Phoca Member
Posts: 43
Joined: 10 Feb 2015, 15:44

Re: The Phoca Gallery Plugin didnt work

Post by lucas3001 »

Hey thank you for this post!

it helped me in identifying where to change the alt value for plugin, which does not follow the setting of phocagallery main component.
In my case I found the alt parameter not in first position, but later, and worked anyway.

My purpose was to not showing the title, but description.
I found the expression:

Code: Select all

alt="'.$image->title.'"
and changing in

Code: Select all

alt="'.$image->description.'"
I had to try all the <img occurency in order to find the one related to my detail view, but at the end I did It.

thank you again dfsoftware!
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 47865
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: The Phoca Gallery Plugin didnt work

Post by Jan »

Ok, thank you for the info.

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