Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Admin problem


Guest

Recommended Posts

When I try and access my oscommerce admin area to amend my products after i log in all I get is the following error message.

 

Fatal error: Cannot re-assign $this in /home/adoappco/public_html/admin/includes/classes/upload.php on line 31

Link to comment
Share on other sites

what does the line say?

 

 

I ´ve the same problem. read this:

 

Hola, en primer lugar gracias a vladi, pero mi problema es que cuando desde el mudulo Multishop doy de alta un tienda a una categoria, esta no me aparece al pulsar sobre la categoria, tampoco me aparecen los productos relacionados con las tiendas de la categoria en concreto.

 

Referente a tu problam con el admin, no lo entiendo muy bien, pero se en la 2ª parte de la instalacion de Store side, te pregunta cual es el directorio original de la tienda. Si te coje el catalogo de productos de la tienda deberia funcionarte.

 

No obstante prueba a ver si el directorio admin a sido renonmbrado:

 

http://"directorio donde estan las tiendas "/tienda1/admin/

 

Verifica su contenido, sino dame mas detalles de lo que te sale o del probelma, creo que con OScommerce si podre ayudarte, aunque mis conocimientos de PHP son escasos.

 

Back to top

 

 

vladi

Newbie

 

 

 

Joined: Jan 02, 2008

Posts: 13

 

Posted: Mon Jan 07, 2008 2:29 pm Post subject:

 

--------------------------------------------------------------------------------

 

Hola mira

 

Lo de la categoria que no se ven phpnuke a lo mejor puede ser que no has activado la categorias en tu administracion . por lo poco que he visto phpmultishop se que en la administracion -> multishop -> crear una tienda.

 

alli puedes activar las categorias o crear una y luego activarla. desde alli puedes activar los producto, categorias y tiendas para que se vean en tu portal. He visto que si no se activan estos tres ejemplos no se ve la tienda ni los productos en el portal phpnuke.

 

Revisa eso si es tu problema.

 

--------------------------------------------------

Ahora con mi problemas aqui te posteo lo mismo que posteado en el otro lado del foro.

 

Hola

 

Pues todabia no he recibido ninguna repuesta del problema. he estado pensando que este problema puede ser de mi servidor por que he instalado oscommerce y nuke en mi PC con EASYPHP1-8. tanto como la tienda y la administracion me Funcionan correctamente. Ahora en mi servidor tengo en el configure.php de admin lo que pongo abajo. Tambien quiero explicar que mi servidor de internet tiene PHP 5 instalado. Aunque tengo otras tiendas instaladas en mi servidor pero NO MULTISHOP y el Admin Funciona correctamente.

 

mi configure.php de Admin.

 

<?php

/*

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2003 osCommerce

 

Released under the GNU General Public License

*/

 

// set prefix for Php-MultiShop

define('STORE_PREFIX', 'miprefijodebasedatos'); // prefix for the store

 

 

// Define the webserver and path parameters

// * DIR_FS_* = Filesystem directories (local/physical)

// * DIR_WS_* = Webserver directories (virtual/URL)

define('HTTP_SERVER', 'http://www.misitio.com'); // eg, http://localhost - should not be empty for productive servers

define('HTTP_CATALOG_SERVER', 'http://www.misitio.com');

define('HTTPS_CATALOG_SERVER', '');

define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module

define('DIR_FS_DOCUMENT_ROOT', '/var/www/vhosts/misitio.com/httpdocs/mitiendaensubdominio/'); // where the pages are located on the server

define('DIR_WS_ADMIN', '/misitio/admin/'); // absolute path required

define('DIR_FS_ADMIN', '/var/www/vhosts/misitio.com/httpdocs/mitiendaensubdominio/admin/'); // absolute pate required

define('DIR_WS_CATALOG', '/mitiendaensubdominio/'); // absolute path required

define('DIR_FS_CATALOG', '/var/www/vhosts/misitio.com/httpdocs/mitiendaensubdominio/'); // absolute path required

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');

define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');

define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');

define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');

define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');

define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');

define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

 

// define our database connection

define('DB_SERVER', 'localhost'); // eg, localhost - should not be empty for productive servers

define('DB_SERVER_USERNAME', 'miusuariobasedatos');

define('DB_SERVER_PASSWORD', 'micontraseña');

define('DB_DATABASE', 'mibasededatos');

define('USE_PCONNECT', 'true'); // use persisstent connections?

define('STORE_SESSIONS', 'mysql'); // leave empty '' for default handler or set to 'mysql'

?>

 

 

Bueno os Quiero decir que este configure.php para mi esta bien por que lo he comparado con otro configure de otra tienda oscommerce no multishop y es correcto. solamente que este lleva el codigo de prefijo.

 

Tambien lo he comparado con el configure.php del INCLUDE y es igual sin el root admin por supuesto. y la tienda FUNCIONA se ve pero en ADMIN no se nada ni siquiera error . Solamente la pagina en Blanco.

 

Ahora he comprobado el .htaccess con el codigo para que el servidor php 5 me deje visualizar la pagina y es el mismo codigo que tengo para la otra tienda NO Multishop, donde el admin me funciona normal.

 

El codigo .htaccess es este:

 

# $Id: .htaccess,v 1.2 2007/05/14 05:00:03 ilobachev Exp $

#

# This is used with Apache WebServers

#

# For this to work, you must include the parameter 'Options' to

# the AllowOverride configuration

#

# Example:

#

# <Directory "/usr/local/apache/htdocs">

# AllowOverride Options

# </Directory>

#

# 'All' with also work. (This configuration is in the

# apache/conf/httpd.conf file)

 

# The following makes adjustments to the SSL protocol for Internet

# Explorer browsers

 

<IfModule mod_setenvif.c>

<IfDefine SSL>

SetEnvIf User-Agent ".*MSIE.*" \

nokeepalive ssl-unclean-shutdown \

downgrade-1.0 force-response-1.0

</IfDefine>

</IfModule>

 

# If Search Engine Friendly URLs do not work, try enabling the

# following Apache configuration parameter

#

# AcceptPathInfo On

 

# Fix certain PHP values

# (commented out by default to prevent errors occuring on certain

# servers)

#

#<IfModule mod_php4.c>

# php_value session.use_trans_sid 0

# php_value register_globals 1

#</IfModule>

 

<IfModule mod_php5.c>

php_value register_globals On

php_value register_long_arrays On

</IfModule>

 

<IfModule mod_php4.c>

php_value register_globals On

php_value register_long_arrays On

</IfModule>

 

 

Con este codigo .htaccess es para activar register_global en ON para que oscommerce pueda interpretar php 5.

 

Bueno sera que faltara algo mas aqui.

 

Lo raro es que la tienda se ve y el admin no.

 

 

Espero que alguien me ayude en este tema que me a crecido 5 cm el pelo tratando de buscar la solucion de este problema.

 

Yo Pienso que el problema esta al lado del servidor. aunque mi servidor tiene activado scripts, php y otros modulos.

 

 

Bueno Hasta luego espero que alguien me postee

 

I accept any instruction in english.

Link to comment
Share on other sites

Thats fine, but could you translate your post to english?

 

I 've the same problem. Read this:

 

Hello, first of all thanks to vladi, but my problem is that when I Multishop since mudulo up to a shop to a category, it does not appear to me by clicking on the category, I also appear related products stores OF THE CLASS in particular.

 

Regarding your problam with admin, do not understand it very well, but in the 2 nd part of the installation Store side, we wondered what the original directory of the store. If you picks up the catalog of products from the store should funcionarte.

 

However test to see if the directory has been renonmbrado admin:

 

Http:// directory where the shops are "/ tienda1/admin /

 

Check your content, but give me more details of what turns out or probelma, I think if OScommerce podre help, but my knowledge of PHP are scarce.

 

Back to top

 

 

Vladi

Newbie

 

 

 

Joined: Jan 02 2008

Posts: 13

 

Posted: Mon Jan 07 2008 2:29 pm Post subject:

 

-------------------------------------------------- ------------------------------

 

Hello looks

 

What the category that are not phpnuke perhaps may be that you have not activated the categories in your administration. By the little that I have seen phpmultishop is that the administration -> multishop -> create a store.

 

There can activate the categories or create one and then activate it. From there you can activate the product categories and shops to display on your site. I saw that failure to activate these three examples is not the store or the products in the portal phpnuke.

 

Check if this is your problem.

 

--------------------------------------------------

Now with my problems here you post the same as posted on the other side of the forum.

 

Hello

 

Well todabia I have not received any response to the problem. I have been thinking that this problem can be my server because I have installed oscommerce and nuke on my PC with EASYPHP1-8. Both the store and the administration I operate correctly. Now I have my server in the configure.php admin's what I put down. You want to explain that my internet service provider has installed PHP 5. Although other stores have installed on my server but NOT MULTISHOP and Admin Works fine.

 

My configure.php Admin.

 

<? PHP

/ *

OsCommerce, Open Source E-Commerce Solutions

Http://www.oscommerce.com

 

Copyright © 2003 osCommerce

 

Released under the GNU General Public License

* /

 

/ / Set prefix for Php-MultiShop

Define ( 'STORE_PREFIX', 'miprefijodebasedatos'); / / prefix for the store

 

 

/ / Define the webserver and path parameters

/ / * * = DIR_FS_ Filesystem directories (local / physical)

/ / * * = DIR_WS_ Webserver directories (virtual / URL)

Define ( 'HTTP_SERVER', 'http://www.misitio.com'); / / eg, http://localhost - should not be empty for productive servers

Define ( 'HTTP_CATALOG_SERVER', 'http://www.misitio.com');

Define ( 'HTTPS_CATALOG_SERVER','');

Define ( 'ENABLE_SSL_CATALOG', 'false'); / / secure webserver module for catalog

Define ( 'DIR_FS_DOCUMENT_ROOT', '/ var / www / vhosts / misitio.com / httpdocs / mitiendaensubdominio /'); / / where the pages are located on the server

Define ( 'DIR_WS_ADMIN', '/ misitio / admin /'); / / absolute path required

Define ( 'DIR_FS_ADMIN', '/ var / www / vhosts / misitio.com / httpdocs / mitiendaensubdominio / admin /'); / / absolute pate required

Define ( 'DIR_WS_CATALOG', '/ mitiendaensubdominio /'); / / absolute path required

Define ( 'DIR_FS_CATALOG', '/ var / www / vhosts / misitio.com / httpdocs / mitiendaensubdominio /'); / / absolute path required

Define ( 'DIR_WS_IMAGES', 'images /');

Define ( 'DIR_WS_ICONS' DIR_WS_IMAGES. "Icons / ');

Define ( 'DIR_WS_CATALOG_IMAGES' DIR_WS_CATALOG. "Images / ');

Define ( 'DIR_WS_INCLUDES', 'includes /');

Define ( 'DIR_WS_BOXES' DIR_WS_INCLUDES. "Boxes / ');

Define ( 'DIR_WS_FUNCTIONS' DIR_WS_INCLUDES. "Functions / ');

Define ( 'DIR_WS_CLASSES' DIR_WS_INCLUDES. "Classes / ');

Define ( 'DIR_WS_MODULES' DIR_WS_INCLUDES. "Modules / ');

Define ( 'DIR_WS_LANGUAGES' DIR_WS_INCLUDES. "Languages / ');

Define ( 'DIR_WS_CATALOG_LANGUAGES' DIR_WS_CATALOG. "Includes / languages / ');

Define ( 'DIR_FS_CATALOG_LANGUAGES' DIR_FS_CATALOG. "Includes / languages / ');

Define ( 'DIR_FS_CATALOG_IMAGES' DIR_FS_CATALOG. "Images / ');

Define ( 'DIR_FS_CATALOG_MODULES' DIR_FS_CATALOG. "Includes / modules / ');

Define ( 'DIR_FS_BACKUP' DIR_FS_ADMIN. 'Backups /');

 

/ / Define our database connection

Define ( 'DB_SERVER', 'localhost') / / eg, localhost - should not be empty for productive servers

Define ( 'DB_SERVER_USERNAME', 'miusuariobasedatos');

Define ( 'DB_SERVER_PASSWORD', 'micontraseña');

Define ( 'DB_DATABASE', 'mibasededatos');

Define ( 'USE_PCONNECT', 'true'); / / use persisstent connections?

Define ( 'STORE_SESSIONS', 'mysql'); / / leave empty''for default handler or set to 'mysql'

>

 

 

Well I want you to say that this is good for my configure.php that I have compared with another set of another shop oscommerce multishop and is not correct. Only that this bears the code prefix.

 

Also, I have compared to configure.php the INCLUDE and is the same without the root admin of course. WORKS and the store is not ADMIN but nothing even wrong. Only page White.

 

Now I have seen it. Htaccess with the code for the server php 5 let me see the page and is the same code that I have for NOT Multishop another shop, where I admin functions normally.

 

The code. Htaccess is this:

 

# $ Id:. Htaccess, v 1.2 2007/05/14 05:00:03 ilobachev Exp $

#

# This is used with Apache WebServers

#

# For this to work, you must include the parameter 'Options' to

# The AllowOverride Configuration

#

# Example:

#

# <Directory "/usr/local/apache/htdocs">

# AllowOverride Options

# </ Directory>

#

# 'All' with also work. (This configuration is in the

# Apache / conf / httpd.conf file)

 

# The following makes adjustments to the SSL protocol for the Internet

# Explorer browsers

 

<IfModule Mod_setenvif.c>

<IfDefine SSL>

SetEnvIf User-Agent ".* MSIE .*" \

Nokeepalive ssl-unclean shutdown-\

Downgrade-1.0-response force-1.0

</ IfDefine>

</ IfModule>

 

# If Search Engine Friendly URLs do not work, try enabling the

# Following Apache configuration parameter

#

# On AcceptPathInfo

 

# Fix certain PHP Values

# (Commented out by default to prevent errors occuring on certain

# Servers)

#

# <IfModule Mod_php4.c>

Php_value session.use_trans_sid # 0

Php_value register_globals # 1

# </ IfModule>

 

<IfModule Mod_php5.c>

On php_value register_globals

On php_value register_long_arrays

</ IfModule>

 

<IfModule Mod_php4.c>

On php_value register_globals

On php_value register_long_arrays

</ IfModule>

 

 

With this code. Htaccess is to activate ON register_global to oscommerce can interpret php 5.

 

Well be missing something more here.

 

It is rare that the store is not and admin.

 

 

I hope that someone will help me in this matter that I grew to 5 cm hair trying to find the solution to this problem.

 

Yo I think that the problem is with the server. Although my server has enabled script, php and other modules.

 

 

Well Until then I hope that someone posteen

Link to comment
Share on other sites

what does the line say?

The the error is

 

Fatal error: Cannot re-assign $this in /home/adoappco/public_html/admin/includes/classes/upload.php on line 31

 

The line says

 

if ( ($this->parse() == true) && ($this->save() == true) ) {

return true;

} else {

// self destruct

Link to comment
Share on other sites

sorry line reads

 

if ( ($this->parse() == true) && ($this->save() == true) ) {

return true;

} else {

// self destruct

$this = null;

Link to comment
Share on other sites

sorry line reads

 

if ( ($this->parse() == true) && ($this->save() == true) ) {

return true;

} else {

// self destruct

$this = null;

I do not have

 

// self destruct

$this = null;

You could try a fresh copy of the file if you did not modify the file.

Link to comment
Share on other sites

In /admin/includes/classes/upload.php

 

Find this code (about 30 lines down):

 

// self destruct
$this = null;

Alter it to say this:

 

// self destruct
// $this = null;
unset($this);

If I suggest you edit any file(s) make a backup first - I'm not perfect and neither are you.

 

"Given enough impetus a parallelogramatically shaped projectile can egress a circular orifice."

- Me -

 

"Headers already sent" - The definitive help

 

"Cannot redeclare ..." - How to find/fix it

 

SSL Implementation Help

 

Like this post? "Like" it again over there >

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...