Hello,
I've been cutting and pasting "Practical Web 2.0 Applications" by Quentin Zervaas for my own application lately . And adapting the names of directories. All links work correctly, but the redirects that are caused by the inlog, outlog, register, etc. buttons on forms duplicate certain directories and then throw exceptions/errors. Instead of redirecting to, for example, www.hymenopt.com/database/account/detailscomplete , I am redirected to www.hymenopt.com/database/account/database/account/detailscomplete with an error. But under the hood, my inlog, outlog, registration or whatever has succeeded. If I retype the URL, I arrive at the correct page and have been logged in (or whatever).
I will explain some specifics below, but I would like to ask, for those with knowledge of Zend or who have read Zervaas' book, where should I be looking for my mistake?

I make use of web hosting and have no direct access to an Apache server. Instead of httpd.conf, I use the following .httaccess file:

RewriteEngine on
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteCond %{SCRIPT_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1

# PHP settings
php_value include_path .:/home/hymenopt/include:/home/hymenopt/domains/hymenopt.com/public_html/pear/PEAR:/home/hymenopt/usr/local/etc/:/home/hymenopt/usr/local/lib/pear/
php_flag magic_quotes_gpc off
php_flag register_globals off
php_flag short_open_tag on 

I have also tried:

RewriteRule .* index.php

with the same results.

My setting.ini for Zend is:

[development]

database.type       = pdo_mysql
database.hostname   = localhost
database.username   = hymenopt
database.password   = pass
database.database   = hymenopt_1

paths.base      = /home/hymenopt/domains/hymenopt.com/public_html/database/
paths.data      = /home/hymenopt/data
paths.templates = /home/hymenopt/templates
logging.file = /home/dahymenopt/data/logs/debug.log

A link such as:

<div>
      <a href="{geturl action='fetchpassword'}">Forgotten your password?</a>
</div>

works well.

A redirect such as

<form method="post" action="{geturl action='login'}">
    <fieldset>
        <input type="hidden" name="redirect" value="{$redirect|escape}" />

should log me in and lead me to the page www.hymenopt.com/database/account/login , but it sends me instead to www.hymenopt.com/database/account/database/account/login with the error 'Invalid controller specified (database)', and logs me in unannounced anyway. So the login works, but the redirect doesn't. Where do I start to look for the problem?

    Write a Reply...