I have just migrated my gibbon onto a new host and a new domain. I have changed the base path and base URL in system settings and also checked that they are changed in the database.
The problem I have is that on some places, when I click on submit in a form - it changes the URL to omit the gibbon subfolder
Wordpress often places URL redirection code in it’s folder (in this case public_html) that is likely interfering with the Gibbon URLs. Wordpress needs this code to work, so removing it won’t be an option. One way to fix this is to place a snippet of code in the .htaccess file in the public_html folder to tell Wordpress to ignore the Gibbon sub-directory.
If you’re using an Apache server it can be done with the following steps (the steps will likely be different if you’re using a different server setup like nginx)
Login to your server via FTP and open the public_html folder (the same folder Wordpress is in)
Look for the .htaccess file (its a system hidden file, sometimes a setting needs turned on to see it)
Backup a copy of the .htaccess file before changing
Edit the file and add the following snippet at the bottom:
`
RewriteEngine on
#
# stuff to let through (ignore)
RewriteCond %{REQUEST_URI} "/gib1/"
RewriteRule (.*) $1 [L]
`
```
Hope this helps!
Hmm, looks like I may have been incorrect about the order of the htaccess rules. Try placing the snippet at the very top of the htaccess file before all the other lines.
Otherwise perhaps there’s other URL redirection elsewhere in the server config?
i think the problem may be in writing to the database - as I cannot make any changes anywhere on the system, when I click submit it will do the same thing. I have deleted the database and reimported it - but made no difference
i also have a separate working installation of gibbon on the same domain at: https://www.domain.com/gib2
that was a new install and the one I did first and that is working fine
May that be an issue?
They shouldn’t interfere, but that’s not to say it’s impossible. Each install has a unique guid that’s generated during install and placed in the config.php file, which keeps the session data for each install separate. If you check the config files for each install, are the database names and guids unique?
The return=error0 you’re seeing on the end of the URL is from insufficient permissions, so it appears the changes aren’t making it to the database write step, they’re being redirected back immediately. At this point it may help to try submitting a form, then check your PHP error logs right afterwards to see if there’s any error messages that may shed light on what’s happening.