PDA

View Full Version : EZPoll Compatibility Issue with Cycling



cybohmoob
04-04-2013, 07:56 PM
WordPress Social Polling Plugin stops SG from cycling through the gallery when you reach the end. I have messaged Author about and awaiting response.

I'll will update when I get it.

But just letting you know in case it's not his plugin.
Check out the links and you'll get a better picture what the error is.

Page with it Halts at the last image and doesn't cycle and there's an error.
http://hmonglife.com/2013/03/30/ken-theeradeth/

Page without works fine.
http://hmonglife.com/2013/03/31/korean-model-kim-shin-young/

mikemayhem3030
04-04-2013, 10:37 PM
Hello

Easy Polling is one of my plugins so I'll take a look now for you.

Cheers

mikemayhem3030
04-04-2013, 10:41 PM
OK

Here's what's happening.

The Easy Polling Facebook "Facepiles" are linked as images, so Social Gallery is trying to open these in the lightbox - if you were to press the right key 5 more times, you get back to the start of the gallery.

Can you try adding the following to the "disclude CSS selector" .fb_poll

That way it won't include the FB poll in the Gallery lightbox.

Cheers

Mike

cybohmoob
04-05-2013, 02:52 AM
OK

Here's what's happening.

The Easy Polling Facebook "Facepiles" are linked as images, so Social Gallery is trying to open these in the lightbox - if you were to press the right key 5 more times, you get back to the start of the gallery.

Can you try adding the following to the "disclude CSS selector" .fb_poll

That way it won't include the FB poll in the Gallery lightbox.

Cheers

Mike

Ok I tried it and no success.
.fb_poll does nothing. The bug remains.

I upgraded to latest and it's same issue.

Here's the script. Tried all the classes and nothing. Disclude is not excluding them.

<script type="text/javascript">
</script>
<div id="fb-root">
</div>
<script>
</script>
<div class="fb_poll">
<div class="row">
<div class="span7">
<div class="uiHeader uiHeaderTopBorder mbm pbs uiSideHeader">
</div>
<div class="rtn-holder">
</div>
<table class="pollOptions" cellspacing="0" cellpadding="1">
<tbody>
<tr class="myo-pollbar2">
<td class="pollResultsBar selectedPollOption">
</td>
<td class="pollResultsFacepile">
</td>
</tr>
<tr class="myo-pollbar2">
<td class="pollResultsBar selectedPollOption">
</td>
<td class="pollResultsFacepile">
</td>
</tr>
</tbody>
</table>
<div class="padding">
</div>
</div>
<div class="span5">
</div>
</div>
</div>
<script type="text/javascript">
</script>
<script type="text/javascript">
</script>
</div>
<!-- END entry-content -->

mikemayhem3030
04-05-2013, 08:21 AM
OK

One way to "fix" it is to be more specific about the images Social Gallery should open. What do you have set? For example if you put the following around any places where you want social gallery to work

<div class = "socgal">

// your lightbox images here

</div>

// rest of the page

Then in the CSS selector settings of Soc Gal put .socgal a:has(img)

And it will know NOT to look anywhere else apart from inside the <div class = "socgal"> element of your pages.

I don't know how you're putting the galleries onto your pages but that's what I'd suggest to save you editing the facebook polling plugin code.

If you're happy to edit the plugin facebook easy polling add on:

The other option is to add a class to the images in facebookquestions.PHP where it outputs the thickbox images for who has voted (adding the class = "noLightbox") to the facebookquestions.php in the shortcode for myo_fb_polling. It's line 414 roughly of facebookquestions.php (add the bit in bold to the code).

foreach ( $al as $face )
{
$facename = $facename = $face->myo_fb_name;
echo "<img class = '_ry noLightbox' title = '$facename' src = 'http://graph.facebook.com/$face->myo_polling_ip/picture' />";
if($faces >= 1){
break;
}
$faces++;
}

There's also a bit more code lower down where you'll want to add the "noLightbox" class (from approx line 433)

foreach ( $al as $face )
{
echo "<tr style = 'padding-bottom:2px'>";
$facename = $face->myo_fb_name;
echo "<td><img class = 'noLightbox' title = '$facename' src = 'http://graph.facebook.com/$face->myo_polling_ip/picture' /></td>";
echo "<td><a href = 'http://facebook.com/$face->myo_polling_ip' target = '_blank'>$facename</a></td>";
echo "<td><a href = 'http://facebook.com/$face->myo_polling_ip' target = '_blank'><div class = 'uiButton'><span class = 'uiButtonText'>View Profile</span></div></a>";
echo "</tr>";

if($faces >= 6){
break;
}
$faces++;
}

cybohmoob
04-05-2013, 02:55 PM
OK

One way to "fix" it is to be more specific about the images Social Gallery should open. What do you have set? For example if you put the following around any places where you want social gallery to work

<div class = "socgal">

// your lightbox images here

</div>

// rest of the page

Then in the CSS selector settings of Soc Gal put .socgal a:has(img)

And it will know NOT to look anywhere else apart from inside the <div class = "socgal"> element of your pages.

I don't know how you're putting the galleries onto your pages but that's what I'd suggest to save you editing the facebook polling plugin code.

If you're happy to edit the plugin facebook easy polling add on:

The other option is to add a class to the images in facebookquestions.PHP where it outputs the thickbox images for who has voted (adding the class = "noLightbox") to the facebookquestions.php in the shortcode for myo_fb_polling. It's line 414 roughly of facebookquestions.php (add the bit in bold to the code).

foreach ( $al as $face )
{
$facename = $facename = $face->myo_fb_name;
echo "<img class = '_ry noLightbox' title = '$facename' src = 'http://graph.facebook.com/$face->myo_polling_ip/picture' />";
if($faces >= 1){
break;
}
$faces++;
}

There's also a bit more code lower down where you'll want to add the "noLightbox" class (from approx line 433)

foreach ( $al as $face )
{
echo "<tr style = 'padding-bottom:2px'>";
$facename = $face->myo_fb_name;
echo "<td><img class = 'noLightbox' title = '$facename' src = 'http://graph.facebook.com/$face->myo_polling_ip/picture' /></td>";
echo "<td><a href = 'http://facebook.com/$face->myo_polling_ip' target = '_blank'>$facename</a></td>";
echo "<td><a href = 'http://facebook.com/$face->myo_polling_ip' target = '_blank'><div class = 'uiButton'><span class = 'uiButtonText'>View Profile</span></div></a>";
echo "</tr>";

if($faces >= 6){
break;
}
$faces++;
}
Yay. THIS WORKED>:)

Knowledge is power. Thank You Mike.

mikemayhem3030
04-05-2013, 04:40 PM
No worries :) which option did you go for? the <div class = "socgal"></div> or the edit the PHP?

cybohmoob
04-06-2013, 06:13 AM
No worries :) which option did you go for? the <div class = "socgal"></div> or the edit the PHP?

Both. I used discluded the thickbox and it worked nicely. You taught me how to customize the code as well so Played around with coding also. Works too when using my own php classes. Well it was a learning experience and knowing both methods of it is cool. I manage to remove the duplicate facebook coding and learned a load of php in the process too:) Thanks.

mikemayhem3030
04-06-2013, 09:45 AM
Yay :) you'll be after my job next ;)