Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problem with Custom Permalink: Error 404
#1
Hey,
I´ve still Problems with GS ...


what I´m doing wrong, what I´ve forgot?
  • install GS 3.1.2 and I18N 3.0.5.
  • Establish two hierachical sites, wellcome and contenta, in english and german.
  • add i18 into template Innovation to get_header() and get_navigation() and get_component()
  • set Custom Permalink Structure: %nondefaultlanguage%/%parent%/%slug%.html, using Fancy URLs
  • add to the htaccess that:
Code:
RewriteBase /onlinestuff/GetSimple/

RewriteRule ^/?$ en/ [R,L]   # optional
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(fr|de)/(.*?/)?([A-Za-z0-9-]+)/?$ index.php?id=$3&lang=$1 [QSA,L]
RewriteRule ^(fr|de)/?$ index.php?lang=$1 [QSA,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*?/)?([A-Za-z0-9-]+)/?$ index.php?id=$2&lang=en [QSA,L]
(at least I don´t know the htaccess commands ...)


If I insert to /admin/inc/basic.php, at the beginning of function find_url(), that:
Code:
if ($parent=='index') $parent='';
it doesn´t work with %nondefaultlanguage% anymore.
But I will anyway give an Error 404


With this config, I get these non-working URLs:

http://localhost/onlinestuff/GetSimple/.html > no access, Error 403
http://localhost/onlinestuff/GetSimple/index/contenta.html > Error 404

http://localhost/onlinestuff/GetSimple/de/.html > Error 404
http://localhost/onlinestuff/GetSimple/de/index/contenta.html > Error 404



with Custom Permalink: %nondefaultlanguage%/%parent%/%slug%/
I got
http://localhost/onlinestuff/GetSimple/index/contenta/ > Error 404
http://localhost/onlinestuff/GetSimple/de/ > Error 404
http://localhost/onlinestuff/GetSimple/de/index/contenta/ > Error 404



What can I do???
Thanks a lot for help,
regards, B.
Reply
#2
now its running - a bit, with:


all sites without lang. are "de"
fancy URLs
%nondefaultlanguage%/%slug%/


---- header.inc.php ----
Code:
<?php get_i18n_navigation(get_page_slug(FALSE),0,10); ?>
...


-------- htaccess ------
Code:
...
# only include the language for languages other than the default    
# RewriteRule ^/?$ de/ [R,L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# RewriteRule ^(fr|en)/(.*?/)?([A-Za-z0-9_-]+)\.html$     index.php?id=$3&lang=$1 [QSA,L]
RewriteRule ^(fr|en)/(.*?/)?([A-Za-z0-9-_]+)/?$ index.php?id=$3&lang=$1 [QSA,L]
RewriteRule ^(fr|en)/?$ index.php?lang=$1 [QSA,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# RewriteRule ^(.*?/)?([A-Za-z0-9_-]+)\.html$     index.php?id=$2&lang=de [QSA,L]
RewriteRule ^(.*?/)?([A-Za-z0-9-_]+)/?$ index.php?id=$2&lang=de [QSA,L]





as I mentioned a .html, like
%nondefaultlanguage%/%slug%.html
doesn´t work - because I don´t know, how to set the "index"-string in front of the .html for the start-site:
thats wrong: http://domain.tld/GetSimple/.html
but index.html would be work.






&btw:
offline, on localhost, there must be something different, maybe with my apache-conf.,
because, only the start-site runs:
http://localhost/onlinestuff/GetSimple/
and the others, I still get Error 404:
http://localhost/onlinestuff/GetSimple/content/
http://localhost/onlinestuff/GetSimple/en/
http://localhost/onlinestuff/GetSimple/en/content/




&btw:
does somebody know, where the {menu-manager} from in18 is?
On a former installation (I18N 2.5.6), I see {menu-manager} in the right menu,
but now, in a further intallation, its not there anymore.


best, B.
Reply




Users browsing this thread: 2 Guest(s)