View Issue Details

IDProjectCategoryView StatusLast Update
0009043mantisbtinstallationpublic2008-08-11 09:41
Reporterprzemek7bc Assigned Tojreese  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Versiongit trunk 
Fixed in Version1.2.0a2 
Summary0009043: Invalid link to login page after installation (bug + patch)
Description

"Continue" link on the installation page is created using helper_mantis_url() which uses short_path configuration key to generate a valid URL.

There are two problems:

  1. short_path is not set by the installer
  2. when config can not be written, the link would always invalid.

Next to that link, there is a link to ../manage_proj_create_page.php without any helper functions. This patch removes the functions and make set a relative link for "continue".

TagsNo tags attached.
Attached Files
mantis-login-link.patch (562 bytes)   
Index: admin/install.php
===================================================================
--- admin/install.php	(wersja 5156)
+++ admin/install.php	(kopia robocza)
@@ -970,7 +970,7 @@
 ?>
 <p>Install was successful.</p>
 <?php if ( $f_db_exists ) { ?>
-<p><a href="<?php echo helper_mantis_url( 'login_page.php' ); ?>">Continue</a> to log into Mantis</p>
+<p><a href="../login_page.php">Continue</a> to log into Mantis</p>
 <?php } else { ?>
 <p>Please log in as the administrator and <a href="../manage_proj_create_page.php">create</a> your first project.
 
mantis-login-link.patch (562 bytes)   

Relationships

related to 0009266 closedgrangeway webpath to the mantis installation is calculated wrong, if mantis is installed in the root directory of a webserver 

Activities

jreese

jreese

2008-04-08 13:23

reporter   ~0017576

In the case of short_path not being set in the configuration file, Mantis makes an attempt to find the correct short_path to use, and in most cases, this will succeed. The only cases where it doesn't is when Mantis is hosted in a symlinked path, and in this case, we can't rely on ../xyz relative links either.

Perhaps the most "correct" solution would be to offer the ability to set a few "critical" configuration elements an install time, when we are already creating config_inc.php (or setting directly in the db if possible). I would definitely prefer this solution, as there are other things that would be useful to set during install, such as the admin's username/password/emails, server email configurations, etc.

giallu

giallu

2008-05-14 13:32

reporter   ~0017832

erm... I don't know what "most cases" covers, but I think I have a fairly common setup ( /mantis12 is an alias to /var/www/mantisbt) and the code looks broken (short path is set to /mantis12/admin/ when called from /admin/install.php).

I think we should really fix its logic, or maybe just point the link to "../login_page.php" which seems to work fine

jreese

jreese

2008-07-14 14:26

reporter   ~0018513

Reverted to hardcoded link in trunk, SVN r5413. We at least need to make things work for the time being...

Related Changesets

MantisBT: master 3d592d9f

2008-07-14 14:23

jreese


Details Diff
Fix 0009043: Revert to hardcoded login page link after installation.

git-svn-id: http://mantisbt.svn.sourceforge.net/svnroot/mantisbt/trunk@5413 <a class="text" href="/?p=mantisbt.git;a=object;h=f5dc347c">f5dc347c</a>-c33d-0410-90a0-b07cc1902cb9
Affected Issues
0009043
mod - admin/install.php Diff File