Topic Closed

Hello,

I developped a website locally with gpeasy 1.7.1. I've just uploaded the files to the server (OVH) and checked for the files integrity and comparison.

The logo and another image don't appear on the website (present on each page normally), because of "index.php".

They only appear on the Special_Galleries page (2 images for 2 (sub-)galleries), not on the pages corresponding to each (sub-)gallery. I see that they don't appear certainly because they have the name of the folder in which the gpeasy files where on the local server added to the paths of the images.

My .htaccess file seems correct (I made gpeasy change it for the server as my files are now directly in /www), but strangely the permalink parameters panel in the admin still shows "Use /index.php" instead of "Hide /index.php". And I still have index.php in my website addresses.

"SetEnv PHP_VER 5 SetEnv REGISTER_GLOBALS 0 # BEGIN gpEasy <IfModule mod_rewrite.c>     <IfModule mod_env.c>     SetEnv gp_rewrite On     </IfModule>     RewriteEngine On     RewriteBase "/"     RewriteRule ^index\.php$ - [L]     RewriteCond %{REQUEST_FILENAME} !-f     RewriteCond %{REQUEST_FILENAME} !-d     RewriteRule . "/index.php" [L] </IfModule> # END gpEasy"

 

Also the index.php file contains : "<?php   //define('gpdebug',true); //define('gp_indexphp',false); //define('gptesting',true); require_once('./include/main.php');"

Isn't something missing at the end? EDIT: like "?>"?

EDIT: should 'gp_indexphp' be on "true"? EDIT: It seems that not.

EDIT: I suppose that in the config.php file I have to change  "$config['dirPrefix'] = '/[nameofthefolderonthelocalserver]';" with "$config['dirPrefix'] = '/';". But it doesn't seem to change anything.

Thanks in advance for your help.

Chris

 

Edited: 10 years ago#1491

Josh S.
2K Posts
295K Downloads
16 Themes
18 Plugins

Ok, I'll start with the easiest:

Isn't something missing at the end? EDIT: like "?>"?

It's actually not needed. The only reason to use it would be if we wanted to output some html from that file, something like: <?php ...php_code_here... ?> <div>Some_HTML</div>

 

My .htaccess file seems correct....

You were on the right track with setting 'gp_indexphp' to true, but it might be in vain. And since you've already tried that it sounds like it's not working because your server does not have the rewrite module installed. It's nearly impossible to accurately check for the rewrite module in php but you should be able to find out from your host if it's installed or not. Sometimes it's listed in the output of phpinfo().

 

I see that they don't appear certainly because they have the name of the folder in which the gpeasy files where on the local server added to the paths of the images.

Absolutely, the paths were correct when they were on your local installation, say something like http://localhost/gpEasy. An image path would have been something like /gpEasy/data/_uploaded/image/image.jpg...  The new domain is something like http://example.com/ and the image path is no longer valid.

Unfortunately, the only way to fix this is to change those image paths. You could do this within gpEasy, but if you have a lot of images it could take some time. You could also edit those paths in a text editor on your computer. Many text editors have a "Find in Files" search where you could find all instances of /gpEasy/data/_uploaded... , change them to /data/_uploaded... then upload the edited files. (Definitely not ideal and I hope to have the import / export tools working soon in such a way that this won't be a problem).

How'd I do? Let me know if I missed something or if I can do more

10 years ago#1494

Thanks for your reply.

I've changed the paths of the images. It was quite logical where I had to change them. I think I had checked these files already but didn't pay too much attention as I wanted a way to change these settings "more easily". I used the command "grep" on Ubuntu Linux.

define('gp_indexphp',false);   Having uncommented this line in index.php I've just been able to change the backend settings to Hide /index.php.

Now, I'm looking how to make appear the 2 logos on the website, as they should have appeared when I hided index.php. (Just changed the paths in the backend).

Also in config.php, it doesn't seem to make any difference but should it be   $config['dirPrefix'] = '';   OR   $config['dirPrefix'] = '/';

It seems the same for gpeasy.

NB: suggestions on securing a cms like gpeasy?

PS: what should we do with the addons directory and/or its subdirectories?

PS2: with gpeasy how can I have websiteaddress.com directed automatically to www.websiteaddress.com?

Thanks in advance.

Edited: 10 years ago#1556

Josh S.
2K Posts
295K Downloads
16 Themes
18 Plugins

Also in config.php, it doesn't seem to make any difference but should it be   $config['dirPrefix'] = '';   OR   $config['dirPrefix'] = '/';

Setting $config['dirPrefix'] won't actually affect anything, it is re-evaluated during each request so anything you put there will be overwritten. You shouldn't actually need to manually edit anything in the config.php file.

NB: suggestions on securing a cms like gpeasy?

Deleting the /include/install/install.php file wouldn't be a bad idea.

PS: what should we do with the addons directory and/or its subdirectories?

I wouldn't delete the addons directory, but you could delete everything inside of it if you're not going to use any addons.

with gpeasy how can I have websiteaddress.com directed automatically to www.websiteaddress.com?

Not with gpEasy itselft, no. That is often done with an .htaccess file. A quick search on your favorite search engine for "htaccess www redirect" will give plenty of examples.

 

Glad the image path changes worked out!

10 years ago#1563

Topic Closed

 

News

elFinder 2.1.50 in Upcoming Release
12/28/2019

A new release for Typesetter is in the works with a lot of improvements including the ... Read More

Typesetter 5.1
8/12/2017

Typesetter 5.1 is now available for download. 5.1 includes bug fixes, UI/UX improvements, ... Read More

More News

HH-Support

Company located in T├│rshavn, Faroe Islands. * Webpage Design * Consultant & Provider of a wide range of programs for visually impaired and dyslextics.

Find out more about our Provider Spotlight

Log In

  Register