Error in loading installed plugins

Showing the following error please help
PHP Fatal error: Cannot redeclare class DefaultThemePlugin in /home/ojsthemes/public_html/ojs3/plugins/themes/default1/DefaultThemePlugin.inc.php on line 189

Hi @pharmagp,

It appears that you’ve duplicated the default theme plugin as default1 but haven’t updated all the details, e.g. the class name. You’ll need to make sure your theme’s name is unique on your system.

Regards,
Alec Smecher
Public Knowledge Project Team

hi,
i have the same problem and add file in the main directory named php.ini have

disable_functions =
safe_mode = Off
memory_limit = 256M
output_buffering = Off
upload_max_filesize = 200M
post_max_size = 200M
magic_quotes_gpc = Off
display_errors = On
date.timezone=“America/New_York”
open_basedir = Off
allow_url_fopen = On
extension=pdo.so
extension=pdo_mysql.so
zend_extension="/usr/local/IonCube/ioncube_loader_lin_5.6.so"
max_input_vars = 1800
max_exeuction_time = 3600;
max_input_time = 360;
the server support help me to add with many help from many person of this forum and become right
can try to do this

1 Like

Hi @firas,

You’ll need to get access to your PHP error log to debug this further.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi,

In version 3.0.1, Website Settings->Plugins->Plugin Gallery tries to load plugins.xml file using a DOMDocument object in PluginGalleryDAO.inc.php. However it won’t work for the servers which need proxy configured in order to access external network. I get:

failed to open stream: HTTP request failed!
failed to load external entity http://pkp.sfu.ca/ojs/xml/plugins.xml

I tried using:
> $opts = array(
> ‘http’ => array(
> ‘proxy’ => Config::getVar(‘proxy’, ‘http_host’).’:’.Config::getVar(‘proxy’, ‘http_port’),
> ‘bindto’ => ‘…’, // my servers ip address
> )
> );
> $context = stream_context_create($opts);
> libxml_set_streams_context($context);

before calling load method. But no luck yet. I think this issue needs to be looked after.

Regards
Ghazal

Below code worked:

$doc = new DOMDocument('1.0');
$proxy = Config::getVar('proxy', 'http_host').':'.Config::getVar('proxy', 'http_port');
$ch = curl_init(PLUGIN_GALLERY_XML_URL);
$options = array(  
    CURLOPT_PROXY          => $proxy, 
    CURLOPT_RETURNTRANSFER => true,
);

curl_setopt_array( $ch, $options );
$content = curl_exec( $ch );        
$doc->load($content);

Hi all,

See also Allow_url_fopen issue. @salehig, please don’t post the same conversation in two places – it makes it difficult to keep the forum organized.

Regards,
Alec Smecher
Public Knowledge Project Team

I have not any error logs, but have same loading problem in plugins page…
Please, help!!!

Hi @ashotgev,

Inquire with your provider about how to access your PHP error logs; you should have access to these, and without that, debugging will be very difficult.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi, @asmecher,

I have access to my PHP error logs, but it’s empty…
Or i must do something…

Hi @ashotgev,

Also check your Apache error log, if it’s separate. It’s possible that e.g. a server timeout is causing Apache to stop PHP, in which case the message might be logged in the Apache log instead.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi, @asmecher!

can you explain me, what does it mean?

Usage statistics plugin is disabled. No log files processed.
[2017-03-12 19:17:09] [Notice] Task process stopped.

Hi, @salehig
can you explain in details, were to put this code to fix the problem?

Hi @ashotgev,

I don’t think that error message is relevant to this problem. Is anything else there?

Regards,
Alec Smecher
Public Knowledge Project Team

Hi, @asmecher
you are right, it was something else there…

I am getting this error on error console
no errors on error log

/$$$call$$$/grid/settings/plugins/settings-plugin-grid/fetch-grid?_=1498121200152 500 (Internal Server Error)

Hi @donadoniman,

See my response to your other post: Error in loading installed plugins on ojs 3.0.2

It’s better if you don’t post the same issue in multiple places, as that divides the conversation and clutters the forum.

Regards,
Alec Smecher
Public Knowledge Project Team

I have done this bus issue is same any other usggestion

Hi @sciplatform,

Rather than re-opening an old thread, can you post your question as a new topic and include all relevant details?

Regards,
Alec Smecher
Public Knowledge Project Team

where to add these codes?