ZenphotoCMS Forum
incorrect url to admin page - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: General support (https://forum.zenphoto.org/forum-4.html)
+--- Thread: incorrect url to admin page (/thread-19.html)



incorrect url to admin page - rsilletti - 20-09-2005

I installed Zenphoto localhost. I can make most of it work, but some of the urls are wrong. The most obvious example is the admin link from the home page.
The home page is at http://localhost/zen/
The admin link at the bottom of the page resolves to http://localhost/zen/admin/ , to reach the admin page manually the url is http://localhost/zen/zen/admin.php, from there most things seem to operate well.




incorrect url to admin page - rsilletti - 20-09-2005

A little extra info:
mod_rewrite is set to false.




incorrect url to admin page - rsilletti - 20-09-2005

Quick fix here is in:
/template-functions.php line 184

  • printLink(WEBPATH.'/admin/', $text, $title, $class, $id);
  • printLink(WEBPATH.'/zenphoto/admin.php', $text, $title, $class, $id);

But if your not using mod_rewrite more needs to happen.
The bug has been reported.




incorrect url to admin page - trisweb - 21-09-2005

Yep, that is true. Thanks for the bug report. Lots of problems without mod_rewrite at the moment.




incorrect url to admin page - rsilletti - 22-09-2005

Can't get .htaccess to work for my life. 500 server errors. I'm trying to install in the root directory. RewriteBase should not need a value.
Do you have a breakdown of what permissions for directories should be.

current .htaccess looks like this:

RewriteEngine On

!!! Change this to the absolute path !!!


RewriteBase


RewriteRule ^zen/(.)$ - [L]
RewriteRule ^tests/(.
)$ - [L]
RewriteRule ^admin$ admin/ [R]
RewriteRule ^admin/?$ zen/admin.php [QSA,L]
RewriteRule ^admin/admin.css$ zen/admin.css [R,L]
RewriteRule ^admin/admin.js$ zen/admin.js [R,L]

RewriteRule ^page/([0-9]+)/?$ index.php?page=$1 [QSA,L]
RewriteRule ^([^/.]+)/?$ index.php?album=$1 [QSA,L]
RewriteRule ^([^/.]+)/page/([0-9]+)/?$ index.php?album=$1&page=$2 [QSA,L]
RewriteRule ^([^/.]+)/image/(thumb|[0-9]{1,4})/([^/\]+)$ zen/i.php?a=$1&i=$3&s=$2 [QSA,L]
RewriteRule ^([^/.]+)/image/([^/\]+)$ albums/$1/$2
RewriteRule ^([^/.]+)/([^/\]+)$ index.php?album=$1&image=$2 [QSA,L]




incorrect url to admin page - trisweb - 22-09-2005

You gotta have that RewriteBase set to the path from the root of your server.

Also, mod_rewrite only works with Apache. Looks like you've got IIS on localhost, so no dice. I'll get a bugfix out which fixes bugs when mod_rewrite is off.




incorrect url to admin page - rsilletti - 23-09-2005

Nope, using Apache - server errors had to do with the way I'm using my Mac to handle .htaccess files, haven't quite figured out what yet. In any case, i have a site up and running at

http://codevillain.com

RewriteBase /

works in .htaccess

And it looks like fun so far, Thanks




incorrect url to admin page - rsilletti - 23-09-2005

Went poking around after upload my first photo and creating my first gallery. Only made one attempt at the upload and everything seemed to work fine.
The database image table looked like this , the extra rows are persistent as you upload more images, and the admin page returns 4 photos in the gallery when there is only one.




incorrect url to admin page - trisweb - 23-09-2005

Don't worry about that They're just extraneous entries for some weird reason. Feel free to delete them.




incorrect url to admin page - Fonz - 30-09-2005

If you don't want to use mod_rewrite, you will have to :

1- like already says :
/template-functions.php line 184

  • printLink(WEBPATH.'/admin/', $text, $title, $class, $id);
  • printLink(WEBPATH.'/zenphoto/admin.php', $text, $title, $class, $id);

2- Search and replace all :
/admin/?
by /zen/admin.php?
in zen/admin.php




incorrect url to admin page - trisweb - 30-09-2005

Shoot I still didn't fix those?? Next release and soon. Sorry about that.