@Kalbaskin said:
@a_5mith not works. Now i use composer-redactor - it works.
I use Markdown, it works. 👍
I get affiliate banners as HTML/ iframe which I would like to embed in the post itself. Is it possible to do so ? If yes, please guide .
@meetdilip said:
I get affiliate banners as HTML/ iframe which I would like to embed in the post itself. Is it possible to do so ? If yes, please guide .
Embedding iframes into a post isn't possible with the composer, it would be a massive security issue. Can you paste an example of an iframe, I may be able to make a plugin that does it. But it depends on the affiliate banner and the URLs used etc.
Yep, true. Please find the code below. Hope this will be the contest winning plugin
<iframe src='http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141229141866629212' frameborder=0 height=250 width=300></iframe>
@meetdilip Is that the only iFrame you wish to post? Or is their an iframe for individual items?
I could do something like
fkid=141229141866629212
to get the iFrame to display, assuming the ID is the only thing that changes. However do note that any user could do this to get their affiliate code in. Although I could possibly look into making sure it's admin only.
This is from my affiliate account. I will post a few more samples for you evaluation. I guess it changes with every deal. It will be nice to allow only admin to add the code.
Horizonal bar :
<iframe src='http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141141282406034773' frameborder=0 height=90 width=728></iframe>
<iframe src='http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141229213124264046' frameborder=0 height=90 width=728></iframe>
Skyscraper :
<iframe src='http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141229221834379337' frameborder=0 height=600 width=160></iframe>
Right, think I've got an idea, I'll see what I can do.
Many thanks @a_5mith
Haha looks like somebody is getting some upvotes on his entries from @meetdilip
Right, so I can't actually test this, as it appears that the iFrames only appear if you're on the allowed list of affiliate users, so I'm only getting a white box.
You can test it by going to your node_modules folder and typing
git clone https://github.com/a5mith/nodebb-plugin-flipkart-iframe.git
Activate it in your ACP, then restart your forum.
Then go to a topic and paste in the affiliate src link. (This bit: http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141229213124264046
)
Let me know if it displays. It should work, the code is valid, the iFrame just doesn't display for me.
Thanks, in a minute...
Where is the option in ACP to activate ? I just used the first command.
@meetdilip said:
Where is the option in ACP to activate ? I just used the first command.
If you're on the new style Admin panel, it's under Extend > Plugins.
@a_5mith said:
@meetdilip said:
Where is the option in ACP to activate ? I just used the first command.
If you're on the new style Admin panel, it's under Extend > Plugins.
There is only @Schamper 's Flipkart Affiliate plugin there. I tried CTRL + F and used keywords iframe and flipkart. No luck.
@meetdilip Go to your node_modules folder inside nodebb and type ls
, make sure it's in there. (If you installed it from anywhere else (like the nodebb folder for example), it won't display in the admin panel.)
Is it this ?
@meetdilip said:
Is it this ?
On the left, click Extend, then Plugins. If it's not in there, then it's not in your node_modules folder.
@a_5mith said:
@meetdilip said:
Is it this ?
On the left, click Extend, then Plugins. If it's not in there, then it's not in your node_modules folder.
Got it.
@meetdilip said:
@a_5mith said:
http://www.flipkart.com/affiliate/displayWidget?affrid=WRID-141229213124264046
Something wrong
Your sites offline.
@a_5mith said:
Your sites offline.
Try now please. New ACP is a bit buggy. It crashes NodeBB whenever I try restart. Have to start NodeBB again through terminal. Restart command never works.