News:

Wondering if this will always be free?  See why free is better.

Main Menu

I want to let my visitor to embed polls

Started by cong, August 31, 2008, 11:35:34 PM

Previous topic - Next topic

cong

hello

i hope this is the place for my qustion


I want the visitors to embed polls in to thier sites
embed space beside polls Like the following image

____________________________________________________________

____________________________________________________________




then visitor of my site can copy & paste this code to his site and get poll in his site Like the following image
____________________________________________________________

____________________________________________________________





when his visitors vote the result shown in my forum like the following image
____________________________________________________________

____________________________________________________________




I hope there is mod or plugin for that
if there is not plugin or mod for that how can i do this ?

thanx in advance

Kindred

I can't see the "embed" image... it's too small.
I have also never specifically seen that as a mod.

The display of the poll looks like a TinyPortal block...

the results is standard smf.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong

i made it with photoshop it just say the concept

so no solution to this problem ??

i want it

i am ready to pay money to who do it

Kindred

I still do not understand.

What do you expect the "embed" section to do?


I have already told you that the poll display can be done with TinyPortal and the results display is standard SMF functionality.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

DonGiovanni

If i understood. He need this code that other users can embed to their page.

cong

#5
Quote from: DonGiovanni on September 01, 2008, 03:07:14 PM
If i understood. He need this code that other users can embed to their page.

yes you are right i need users to copy and paste code to embed  poll to their page

what is TinyPortal >> sorry i am beginner

i am ready to  pay money to anyone who ready to solve this problem for me

Kindred

wait...   you want a code to allow other users to post your forums polls on other pages?

Nope. can not do it.  SMF is not designed to be used that way.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong

Quote from: Kindred on September 01, 2008, 06:23:48 PM
wait...   you want a code to allow other users to post your forums polls on other pages?

Nope. can not do it.  SMF is not designed to be used that way.

this is not agree with smf  license ?

Kindred

it has nothing to do with the license.

SMF is not programatically designed to be used across multiple sites. Even SSI function only work on the same server/main domain.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong

Quote from: Kindred on September 01, 2008, 07:15:10 PM
it has nothing to do with the license.

SMF is not programatically designed to be used across multiple sites. Even SSI function only work on the same server/main domain.

so programmers can't do this ?

cong

i will clear what i want to do
may be there is miss understand

lets say i Have
website "A" >> run smf
another "B" >> this is the external websites that users will embed the polls there

when the webmaster take code from "A" he put it in "B"
Then visitors of "B" will just choose from poll choices then click vote when they click vote they go to results in "A"

may be now you understand me

i think this is easy fr programmers

Kindred

and the answer is NO, it is not easy for programmers.   SMF is not intended to be used like that and has no functionality for embedding polls into another site, nor for collecting the data from that site.

SMF is a forum that is intended to be run on a single site/domain. Although you can display posts, etc via RSS, there is no way to send back data.

My first impression was that you wanted to do this all from within your site.  Now that you have explained, I will tell you that it can not be easily done... if it can be done at all.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong


Kindred

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong

just the poll that will be in  Ifram  not all the forums

just when vistor click on vote he will go to smf

Kindred

Quote from: Kindred on September 02, 2008, 07:50:48 AM
smf does not work in iframes

the poll is part of smf.
I will say again...

Quote from: Kindred on September 01, 2008, 07:58:22 PM
and the answer is NO, it is not easy for programmers.   SMF is not intended to be used like that and has no functionality for embedding polls into another site, nor for collecting the data from that site.

SMF is a forum that is intended to be run on a single site/domain. Although you can display posts, etc via RSS, there is no way to send back data.

In other words, you CAN NOT do what you are asking, without MAJOR coding.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

cong


what is major coding ?

you mean paid one i am ready for this

where i can find coder for this ?

Kindred

If you can find a coder...  go for it.     good luck.

When I say major coding, I mean that I expect that you will need a professional programmer who will have to re-write major portions of code.

basically, SMF's current design does not support what you are trying to do.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

[SiNaN]

You just need a form with the correct information Kindred. You can do it, but note that guests cannot vote in polls in SMF 1.1.5.

../Themes/default/Display.template.php

Find:

echo '
<table cellpadding="3" cellspacing="0" border="0" width="100%" class="tborder" style="padding-top: 0; margin-bottom: 2ex;">
<tr>
<td class="titlebg" colspan="2" valign="middle" style="padding-left: 6px;">
<img src="', $settings['images_url'], '/topic/', $context['poll']['is_locked'] ? 'normal_poll_locked' : 'normal_poll', '.gif" alt="" align="bottom" /> ', $txt['smf43'], '
</td>


Replace:

$embed = '
<form action="' . $scripturl . '?action=vote;topic=' . $context['current_topic'] . '.' . $context['start'] . ';poll=' . $context['poll']['id'] . '" method="post" accept-charset="' . $context['character_set'] . '" style="margin: 0px;">
<table>
<tr>
<td colspan="2">';

if ($context['poll']['allowed_warning'])
$embed .= '
' . $context['poll']['allowed_warning'] . '
</td>
</tr><tr>
<td>';

foreach ($context['poll']['options'] as $option)
$embed .= '
' . $option['vote_button'] . ' ' . $option['option'] . '<br />';

$embed .= '
</td>
<td valign="bottom" style="padding-left: 15px;">';

$embed .= '
</td>
</tr><tr>
<td colspan="2"><input type="submit" value="' . $txt['smf23'] . '" /></td>
</tr>
</table>
</form>';

$embed = htmlspecialchars($embed);

echo '
<table cellpadding="3" cellspacing="0" border="0" width="100%" class="tborder" style="padding-top: 0; margin-bottom: 2ex;">
<tr>
<td class="titlebg" colspan="2" valign="middle" style="padding-left: 6px;">
<img src="', $settings['images_url'], '/topic/', $context['poll']['is_locked'] ? 'normal_poll_locked' : 'normal_poll', '.gif" alt="" align="bottom" /> ', $txt['smf43'], '
</td>
<td class="titlebg" valign="middle" style="padding-left: 6px;">
Embed
</td>


Find:

echo '
</td>
</tr>
</table>';


Replace:

echo '
</td>
<td class="windowbg">
<textarea rows="5" style="width: 400px;">' . $embed . '</textarea>
</td>
</tr>
</table>';


Also, in SMF 2.0, guests can also vote in polls. It will be better idea to use this with SMF 2.0.
Former SMF Core Developer | My Mods | SimplePortal

aishaweb

Quote from: Kindred on September 01, 2008, 10:11:34 AM
I can't see the "embed" image... it's too small.



What?

The pics are pretty big, just this forum has resized them in the post.

Advertisement: