I mistakenly added all profiles to admin profile. whenever i login it always direct me to portal user web page. How do regain my admin menu to work with? Please anyone who can urgently help?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Displays a popup welcome message, once per session at maximum
until the user unchecks the "Display welcome at startup"
@param WebPage $oP The current web page for the display
@return void
*/
function DisplayWelcomePopup(WebPage $oP)
{
if (!isset($_SESSION['welcome']))
{
// Check, only once per session, if the popup should be displayed...
// If the user did not already ask for hiding it forever
$bPopup = appUserPreferences::GetPref('welcome_popup', true);
if ($bPopup)
{
$sTemplate = @file_get_contents('../application/templates/welcome_popup.html');
if ($sTemplate !== false)
{
$oTemplate = new DisplayTemplate($sTemplate);
$oP->add("
Please Denis can you help me with UI.php file content to do comparison with mine. Where I find $sLoginMessage = LoginWebPage::DoLogin(); is run_querry.php file. I am at a lost please do help me. it is highly critical.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi, I am having this same problem and have tried what Denis suggests but I still get the user portal appearing and no chance to modify the admin profile. Is there anything else I can try?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I mistakenly added all profiles to admin profile. whenever i login it always direct me to portal user web page. How do regain my admin menu to work with? Please anyone who can urgently help?
Hmm,
Quick and dirty fix:
Backup the file pages/UI.php
Edit the file pages/UI.php, locate the line:
(around line 294, depending on your version of iTop)
Change it to:
Connect to iTop, and change your profile and save.
Revert the file UI.php to its original version.
Thanks
How do i locate this file 'pages/UI.php"
On the server, where you installed iTop, look for the subidrectory "pages" then the file "UI.php".
thanks
I can find the line to edit. Below is the file as seen in the configuration
root@helpdesk:/var/www/itop/pages# vi UI.php
// bottom: Displays the ticket details BEFORE the actions
$oP->add('
$oObj->DisplayBareProperties($oP);
$oP->add('
}
$oP->add("
$oP->add("<form id="user-content-\"apply_stimulus\"" method="\"post\"" onsubmit="\"return" onsubmit('apply_stimulus');\"="">\n");
$oP->add("
$oP->details($aDetails);
$oP->add("
$oP->add("<input type="\"hidden\"" name="\"class\"" value="\"$sClass\"">\n");
$oP->add("<input type="\"hidden\"" name="\"operation\"" value="\"bulk_apply_stimulus\"">\n");
$oP->add("<input type="\"hidden\"" name="\"preview_mode\"" value="\"1\"">\n");
$oP->add("<input type="\"hidden\"" name="\"filter\"" value="\"$sFilter\"">\n");
$oP->add("<input type="\"hidden\"" name="\"stimulus\"" value="\"$sStimulus\"">\n");
$oP->add("<input type="\"hidden\"" name="\"state\"" value="\"$sState\"">\n");
$oP->add("<input type="\"hidden\"" name="\"transaction_id\"" value="\"".utils::GetNewTransactionId()."\"">\n");
$oP->add($oAppContext->GetForForm());
$oP->add("<input type="\"hidden\"" name="\"selectObject\"" value="\"".implode(',',$aSelectObject)."\"">\n");
$in page of iTop
*
*/
/**
- Displays a popup welcome message, once per session at maximum
- until the user unchecks the "Display welcome at startup"
- @param WebPage $oP The current web page for the display
- @return void
");
</form>*/
function DisplayWelcomePopup(WebPage $oP)
{
if (!isset($_SESSION['welcome']))
{
// Check, only once per session, if the popup should be displayed...
// If the user did not already ask for hiding it forever
$bPopup = appUserPreferences::GetPref('welcome_popup', true);
if ($bPopup)
{
$sTemplate = @file_get_contents('../application/templates/welcome_popup.html');
if ($sTemplate !== false)
{
$oTemplate = new DisplayTemplate($sTemplate);
$oP->add("
$oTemplate->Render($oP, array());
$oP->add("
<input type="\"checkbox\"" checked="" id="\"display_welcome_popup\"/"><label for="\"display_welcome_popup\""> ".Dict::S('UI:DisplayThisMessageAtStartup')."</label>
\n");$oP->add("
<input type="\"button\"" value="\"".Dict::S('UI:Button:Ok')."\"" onclick="\"$('#welcome_popup').dialog('close');\"/">\n");
sURL = "./UI.php?operation=search&filter=".urlencode($sFilter)."&".$oAppContext->GetForLink();
Please Denis can you help me with UI.php file content to do comparison with mine. Where I find $sLoginMessage = LoginWebPage::DoLogin(); is run_querry.php file. I am at a lost please do help me. it is highly critical.
Hi Denis,
Where I can UI.php are listed below but the actual line you refered me to cannot be seen in these php files. What do I do please?
/root/web/pages/UI.php
/var/www/itop/pages/UI.php
/var/www/html/itop/pages/UI.php
Which version of iTop are you using? The code is slightly different depending on the version.
iTop version 2.3.0-beta-2777 built on 2016-05-26 17:05:13
Data model: 2.3.0
MySQL: 5.5.49-0ubuntu0.14.04.1
PHP: 5.5.9-1ubuntu4.17
Denis, thanks very much, I have to re install the itop since that is only option left for me.
Hi, I am having this same problem and have tried what Denis suggests but I still get the user portal appearing and no chance to modify the admin profile. Is there anything else I can try?
delete portal user profile.