Redirect
Redirect
I have a problem,
i send my dns records of my server to a domain that hosting to another server.
But when it click the domain contenido types a problem:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/cms/front_content.php on line 204
The client name is psb and i change the name also in administration->client.
What i did wrong???
Best Regards
Ilias
i send my dns records of my server to a domain that hosting to another server.
But when it click the domain contenido types a problem:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/cms/front_content.php on line 204
The client name is psb and i change the name also in administration->client.
What i did wrong???
Best Regards
Ilias
Re: Redirect
Could it be that the new server is running an old PHP version (i.e. PHP 4.x) which doesn't support chaining method calls?
The offending line is (unless something was changed from the standard)
and won't run in PHP4.
The offending line is (unless something was changed from the standard)
Code: Alles auswählen
Contenido_Url::getInstance()->getUrlBuilder()->setHttpBasePath($cfgClient[$client]['htmlpath']['frontend']);
Re: Redirect
Thanks for your quick reply, but i have php 5.2.
Propably something else is the problem.
Propably something else is the problem.
-
- Beiträge: 4316
- Registriert: Do 30. Jun 2005, 22:56
- Wohnort: Eltmann, Unterfranken, Bayern
- Hat sich bedankt: 6 Mal
- Danksagung erhalten: 4 Mal
- Kontaktdaten:
Re: Redirect
Hi ilias
you may check the following points
you may check the following points
- Are there folders contenido/classes/Url and contenido/classes/UrlBuilder with some php classfiles in your web?
- Are there the following entries at the end of contenido/includes/startup.php?
Code: Alles auswählen
// Initialize UrlBuilder, configuration is set in /contenido/includes/config.misc.php cInclude('classes', 'Url/Contenido_Url.class.php'); cInclude('classes', 'UrlBuilder/Contenido_UrlBuilderConfig.class.php'); Contenido_UrlBuilderConfig::setConfig($cfg['url_builder']);
- Are there any other errors in contenido logs?
ConLite 3.0.0-dev, alternatives und stabiles Update von Contenido 4.8.x unter PHP 8.x - Download und Repo auf Gitport.de
phpBO Search Advanced - das Suchwort-Plugin für CONTENIDO 4.9
Mein Entwickler-Blog
phpBO Search Advanced - das Suchwort-Plugin für CONTENIDO 4.9
Mein Entwickler-Blog
Re: Redirect
dear oldperl
i check everything that you said:
1-step : i have the folders
2-step: The entries at the end of contenido/includes/startup.php existe
3-step: no error logs
Anything else for help???
Thanks everybody for answering in my problem
Best Regards
ilias
i check everything that you said:
1-step : i have the folders
2-step: The entries at the end of contenido/includes/startup.php existe
3-step: no error logs
Anything else for help???
Thanks everybody for answering in my problem
Best Regards
ilias
-
- Beiträge: 4316
- Registriert: Do 30. Jun 2005, 22:56
- Wohnort: Eltmann, Unterfranken, Bayern
- Hat sich bedankt: 6 Mal
- Danksagung erhalten: 4 Mal
- Kontaktdaten:
Re: Redirect
Hello ilias,
ok, let's try if the class exists. Try the following, change the code in front_content.php near line 200 like this
Now call the front_content.php in your browser and check what is printed out.
regards Ortwin
ok, let's try if the class exists. Try the following, change the code in front_content.php near line 200 like this
Code: Alles auswählen
print "Class ".(class_exists(Contenido_Url))?"exists":"does not exist";
// update urlbuilder set http base path
Contenido_Url::getInstance()->getUrlBuilder()->setHttpBasePath($cfgClient[$client]['htmlpath']['frontend']);
regards Ortwin
ConLite 3.0.0-dev, alternatives und stabiles Update von Contenido 4.8.x unter PHP 8.x - Download und Repo auf Gitport.de
phpBO Search Advanced - das Suchwort-Plugin für CONTENIDO 4.9
Mein Entwickler-Blog
phpBO Search Advanced - das Suchwort-Plugin für CONTENIDO 4.9
Mein Entwickler-Blog
Re: Redirect
Dear Oldperl
i put the code as you told me (show it below)
But it show the below error:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/psb/front_content.php on line 203
For your information the directory that exists the client is /psb
i put the code as you told me (show it below)
Code: Alles auswählen
// Initialize client
if (!isset($client)) {
//load_client defined in frontend/config.php
$client = $load_client;
}
print "Class ".(class_exists(Contenido_Url))?"exists":"does not exist";
// update urlbuilder set http base path
Contenido_Url::getInstance()->getUrlBuilder()->setHttpBasePath($cfgClient[$client]['htmlpath']['frontend']);
// Initialize language
if (!isset($lang)) {
But it show the below error:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/psb/front_content.php on line 203
For your information the directory that exists the client is /psb
Re: Redirect
Please modify the code like the following:
and if the error persists, this should show which of the method calls exactly triggers the error. Though I'm still rather convinced that, from the error message you get, your php version is 4.x. Could it be that you're running different versions as php-cli (command line) interpreter and in your webserver?
Code: Alles auswählen
// Initialize client
if (!isset($client)) {
//load_client defined in frontend/config.php
$client = $load_client;
}
// update urlbuilder set http base path
$inst = Contenido_Url::getInstance();
$builder = $inst->getUrlBuilder();
$builder->setHttpBasePath($cfgClient[$client]['htmlpath']['frontend']);
// Initialize language
if (!isset($lang)) {
Re: Redirect
dear thepoet
i made the changes and now it shows:
Parse error: syntax error, unexpected '/' in /var/www/web46/html/contenido-neu/psb/front_content.php on line 195
that means //initialize client
can it solve??
i made the changes and now it shows:
Parse error: syntax error, unexpected '/' in /var/www/web46/html/contenido-neu/psb/front_content.php on line 195
that means //initialize client
can it solve??
Re: Redirect
Looks like an error (maybe a new one introduced when changing the file) in a line before 195. Check if the code line above it is missing the closing semicolon.
Re: Redirect
Ok my friends,
in attach file you'll see all the code of the front_content.
May be you;ll see somtehing that i cannot find.
in attach file you'll see all the code of the front_content.
May be you;ll see somtehing that i cannot find.
- Dateianhänge
-
- front_content.rar
- front_content
- (8.75 KiB) 127-mal heruntergeladen
-
- Beiträge: 3626
- Registriert: Di 12. Okt 2004, 20:00
- Wohnort: Voerde (Niederrhein)
- Kontaktdaten:
Re: Redirect
Code: Alles auswählen
/ Initialize client
Code: Alles auswählen
// Initialize client
Re: Redirect
Yes, you are right
but now it has new mistake in:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/psb/front_content.php on line 297
that means
and special
Thanks in advance and for your quick reply to solve my problem
Best Regards
Ilias
but now it has new mistake in:
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/psb/front_content.php on line 297
that means
Code: Alles auswählen
// error page
$aParams = array (
'client' => $client, 'idcat' => $errsite_idcat[$client], 'idart' => $errsite_idart[$client],
'lang' => $lang, 'error'=> '1'
);
$errsite = 'Location: ' . Contenido_Url::getInstance()->buildRedirect($aParams);
Code: Alles auswählen
$errsite = 'Location: ' . Contenido_Url::getInstance()->buildRedirect($aParams);
Best Regards
Ilias
Re: Redirect
Ich beschaeftige mich zur Zeit mit dieser Installation, insofern will ich mich mal mit meiner Muttersprache zu Wort melden, vielleicht schaffen wir dann irgendwie eine Loesung. Ich stehe vor einem voelligen Raetsel.
Das Contenido wurde urspruenglich auf domain.de installiert. Dann wurden Mandanten eingerichtet und weitere Domains auf das Verzeichnis gelegt. Ein Mandant liegt im Ordner /psb/
Der Aufruf bringt keinen Fehler:
domain.de/psb/
Nehme ich jedoch die 2. Domain
domain2.de
kommt der Fehler
Die Domain domain2.de liegt auf dem Mandantenverzeichnis und es wird sauber auf die front_content.php weitergeleitet.
Der Server nutzt PHP5.
Ich wuerde einen Fehler im Code ausschliessen, da ja der 1. Abruf fehlerlos arbeitet. Offenbar kann die neue Domain nicht verarbeitet werden. con_code und con_inuse wurden bereits geleert. Die Mandanteneinstellungen sind angepasst.
Je oefter ich drueber nachdenke, um so mehr denke ich, dass es die griechische Sprache des Mandanten sein koennte (anderer Zeichensatz). Aber dann muesste bei beiden Domains der Fehler auftreten, oder?
Das Contenido wurde urspruenglich auf domain.de installiert. Dann wurden Mandanten eingerichtet und weitere Domains auf das Verzeichnis gelegt. Ein Mandant liegt im Ordner /psb/
Der Aufruf bringt keinen Fehler:
domain.de/psb/
Nehme ich jedoch die 2. Domain
domain2.de
kommt der Fehler
Code: Alles auswählen
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /var/www/web46/html/contenido-neu/psb/front_content.php on line 203
Der Server nutzt PHP5.
Ich wuerde einen Fehler im Code ausschliessen, da ja der 1. Abruf fehlerlos arbeitet. Offenbar kann die neue Domain nicht verarbeitet werden. con_code und con_inuse wurden bereits geleert. Die Mandanteneinstellungen sind angepasst.
Je oefter ich drueber nachdenke, um so mehr denke ich, dass es die griechische Sprache des Mandanten sein koennte (anderer Zeichensatz). Aber dann muesste bei beiden Domains der Fehler auftreten, oder?
-
- Beiträge: 3626
- Registriert: Di 12. Okt 2004, 20:00
- Wohnort: Voerde (Niederrhein)
- Kontaktdaten:
Re: Redirect
Da es sich um zwei verschiedene Domains handelt, können auch unterschiedliche PHP-Versionen im Einsatz sein. Vielleicht kann das mal überprüft werden, indem im Mandantenverzeichnis eine Datei "config.local.php" abgelegt wird mit folgendem Inhalt:
Code: Alles auswählen
<?php
echo PHP_VERSION;
?>