OJS OCS OMP OHS

You are viewing the PKP Support Forum | PKP Home Wiki



OJS social media block plugins

The Plugin Gallery is a venue for users of PKP software to share their plugins.

Moderators: jmacgreg, michael, John

Forum rules
If you post a plugin here, please include information on which versions of which applications it is compatible with. Attach a tarball of the plugin (e.g. tar cvzf myPlugin-0.1.tar.gz plugins/generic/myPlugin). Thanks for contributing!

Re: OJS social media block plugins

Postby dsully » Tue Jan 28, 2014 8:11 am

Hi Alec,

My php.ini file shows that magic quotes are turned off, but I do see that the code is changed when I paste it into the custom block plugin. As to why that is, I am still lost. If you have any other suggestions please let me know, I really appreciate all your help!

Sincerely,
David
dsully
 
Posts: 33
Joined: Mon Jan 13, 2014 7:47 am

Re: OJS social media block plugins

Postby asmecher » Tue Jan 28, 2014 8:21 am

Hi David,

Are you pasting that directly into the rich text editor, or using the "HTML" button to enter HTML editing mode? It should be the latter.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby dsully » Tue Jan 28, 2014 8:24 am

Hi Alec,

The latter. It is strange that it would provide a link to the widget if there are syntax errors, but the code is certainly changed by the OCS software, as it is different when I reopen the HTML window after pasting the code into it.

David
dsully
 
Posts: 33
Joined: Mon Jan 13, 2014 7:47 am

Re: OJS social media block plugins

Postby asmecher » Tue Jan 28, 2014 8:27 am

Hi David,

I don't think there's anything in OCS that should be adding escaping -- the most obvious suspect is still the TinyMCE rich text editor. I would suggest temporarily disabling it by editing plugins/generic/customBlockManager/CustomBlockEditForm.inc.php and removing the call to $this->addTinyMCE(); from the initData function. Then re-paste the code into the form and see if that helps.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby dsully » Tue Jan 28, 2014 8:38 am

Hi Alec,

I tried disabling the plugin from the System Plugin Manager section and then reentering the code for the twitter feed. The result was the same. I then commented out the call to the plug in in the CustomBlockEditForm.inc.php file as you suggested and the results was still the same.

David
dsully
 
Posts: 33
Joined: Mon Jan 13, 2014 7:47 am

Re: OJS social media block plugins

Postby asmecher » Tue Jan 28, 2014 9:11 am

Hi David,

Did the change I suggested above successfully disable the rich text controls for the custom block edit form, or were they still shown?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby dsully » Tue Jan 28, 2014 9:15 am

Hi Alec,

Yes it did remove the TinyMCE from the Custom Block Editing form, but the result was still the same.

-David
dsully
 
Posts: 33
Joined: Mon Jan 13, 2014 7:47 am

Re: OJS social media block plugins

Postby asmecher » Tue Jan 28, 2014 10:02 am

Hi David,

Hmm, I'm afraid this looks like a platform issue on your server. There is no escaping done by OCS upon saving or displaying the form, so between the script being sent to your server and OCS receiving it on the PHP side, some escaping is getting done. This is usually "magic quotes" or similar but you report that this is disabled. A work-around that could get you un-stuck, at least: try editing the contents directly in your database (in the plugin_settings table). This is easiest done using something like phpMyAdmin. Before you try it on the OCS side, make sure you flush your OCS data cache.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby dsully » Thu Jan 30, 2014 8:48 am

Alec,

Clearing the cache revealed that the code had been altered in our database. I replaced that altered code with the code in this post and it now works. I will have to find what setting is causing that escaping to occur, but for now your workaround was successful. Thanks so much for the help

-David
dsully
 
Posts: 33
Joined: Mon Jan 13, 2014 7:47 am

Re: OJS social media block plugins

Postby ragutierrez » Thu May 22, 2014 11:04 am

Hello everybody.
I was installing every tar.gz but I can't see them in:
Home > User > Journal Management > Plugin Management > *

Can someone teach me how to install them in the correct way???

My OJS version is 2.3.7 as it required
PHP = PHP 5.4.4-14+deb7u9 (cli) (built: Apr 18 2014 14:34:31)
Apache = Server version: Apache/2.2.22 (Debian)

Please help me ASAP
ragutierrez
 
Posts: 4
Joined: Wed Apr 23, 2014 3:44 pm
Location: Loja, Ecuador

Re: OJS social media block plugins

Postby asmecher » Thu May 22, 2014 11:20 am

Hi ragutierrez,

Which method did you use to install the plugin?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby ragutierrez » Thu May 22, 2014 12:26 pm

Hi asmecher, thanks for replying

1. Dounloaded the .zip
2. Unzip the files
3. Home > User > Journal Management > Plugin Management > Install A New Plugin
4. Search the tar.gz files and click "continue" button
ragutierrez
 
Posts: 4
Joined: Wed Apr 23, 2014 3:44 pm
Location: Loja, Ecuador

Re: OJS social media block plugins

Postby asmecher » Thu May 22, 2014 3:15 pm

Hi ragutierrez,

If it's a .zip then it's not properly packaged for the web-based plugin installer. I'd suggest contacting the author of the plugin for installation instructions, if they haven't provided them in the post.

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

Re: OJS social media block plugins

Postby ragutierrez » Thu May 22, 2014 9:11 pm

asmecher, the files are in tar.gz after unziped them.

Regards,
Rommel Gutierrez
Loja - Ecuador
ragutierrez
 
Posts: 4
Joined: Wed Apr 23, 2014 3:44 pm
Location: Loja, Ecuador

Re: OJS social media block plugins

Postby asmecher » Fri May 23, 2014 9:09 am

Hi Rommel,

Have you checked e.g. in the "Block Plugins" category in Journal Management > Plugin Management?

If you look in the plugins/blocks subdirectory, do you see the plugins there?

Regards,
Alec Smecher
Public Knowledge Project Team
asmecher
 
Posts: 8676
Joined: Wed Aug 10, 2005 12:56 pm

PreviousNext

Return to Plugin Gallery

Who is online

Users browsing this forum: No registered users and 2 guests