New page in Admin

valpenguin

No avatar

2007-03-30 16:49

I want to read the output of function phpinfo() in new page on Admin area.

» Quick.Cart v2.x

gilgalad

No avatar

2007-03-30 17:27

Can i edit this entry?

valpenguin

No avatar

2007-04-03 10:44

What? I want to know like creating one page, in admin, for read the output of function phpinfo().

ZSiGO

No avatar

2007-04-03 11:49

create actions_admin/phpinfo.php


<?
ob_start
();                                                                                                       
phpinfo();                                                                                                        
$info ob_get_contents();                                                                                        
ob_end_clean();                                                                                                   
$content .= $tpl->tbHtml'phpinfo.tpl''HEAD' );
$content .= preg_replace('%^.*<body>(.*)</body>.*$%ms''$1'$info);
?>


create templates/admin/phpinfo.tpl


<!-- BEGIN HEAD -->
<
style type="text/css"><!--
pre {margin0pxfont-familymonospace;}
table {border-collapsecollapse;}
.
center {text-aligncenter;}
.
center table margin-leftautomargin-rightautotext-alignleft;}
.
center th text-aligncenter !important; }
tdth border1px solid #000000; font-size: 100%; vertical-align: baseline;}
h1 {font-size150%;}
h2 {font-size125%;}
.
{text-alignleft;}
.
{background-color#ccccff; font-weight: bold; color: #000000;}
.{background-color#9999cc; font-weight: bold; color: #000000;}
.{background-color#cccccc; color: #000000;}
{color#666666; background-color: #cccccc;}
img {floatrightborder0px;}
hr {width600pxbackground-color#cccccc; border: 0px; height: 1px; color: #000000;}
//--></style>
<!-- END HEAD -->


edit templates/admin/page.tpl
after


<div id="tools" class="menu" onmouseover="menuMouseover( event );">


add


<class="menuItem" href="?p=phpinfo"><span class="menuItemText">PHP Info</span></a>

valpenguin

No avatar

2007-04-03 15:34

I try, thank. This code work fine on QC 1.4?

qwerty@de.hu

No avatar

2007-05-08 13:31

I want to add some menus with subcategory in admin.I want to add a Seo category to check my page rank, to see my web position, ....
I have the seo scripts but hoe can i add it to admin menu?

Thanks

merci

No avatar

2007-05-09 10:29

qwerty@de.hu - you should edit templates/admin/page.tpl and after this:

<div class="menuBar">

is the code with links in admin, add there your link and links to subcategories are few lines further, it starts with

<div id="products" class="menu" onmouseover="menuMouseover( event );">


create your links similary.

qwerty@de.hu

No avatar

2007-05-10 11:07

hmmm.
I have added :
" <a class="menuButton" href="?p=seoList" onmouseover="return buttonClick(event,'seo'); buttonMouseover(event,'seo');">$lang[seo]</a>"
...and for subcategory i added

" <!-- Seo -->
<div id="seo" class="menu" onmouseover="menuMouseover( event );">
<a class="menuItem" href="seo/pagerank/index.php"><span class="menuItemText">$lang[pagerank]</span></a>
</div>"

... but the menu dose not apera in admin.. i have added the new language text in language file... what is wrong?.. i want a category named Seo and under it 3-4 subcategories.I want the pages to be opened in the same window as the admin... just like adding a product or a category

merci

No avatar

2007-05-10 13:00

qwerty@de.hu - I have tested your code and in my admin menu appears new link Seo with subcategory Pagerank, so maybe you make mistake while adding to language file.
For example I have added to lang/pl.php this code:

$lang['seo'] = 'Seo';
$lang['pagerank'] = 'Pagerank';

qwerty@de.hu

No avatar

2007-05-10 18:11

aha..it was from language ..thank you "merci" ... but now if i click on the menu pagerank it is displayed in a new window, i want to show the page under the menu from admin bar... like adding categories or adding a product..

merci

No avatar

2007-05-11 09:35

qwerty@de.hu - it is displayed in the same window, but without the menu above your content, so you should in actions_admin/other.php create for example

elseif( $a == 'Seo' ){
  
$content .= $tpl->tbHtml'pagerank.tpl''PAGERANK' );
}


then you should create templates/admin/pagerank.tpl file with block PAGERANK and in this block insert <iframe> with link to your script. Of course you have to change also your link in templates/admin/page.tpl

Back to top
about us | contact