Gossamer Forum
Home : Products : DBMan : Customization :

move MENU to sub html_page_top

Quote Reply
move MENU to sub html_page_top
Hi i tried searching the forum to see if anyone already posted for this but did not find any.

I want to move my menu to the very top of my page within a table in the section sub html_page_top, what changes do i need to do in order the do this ?

thank you for any help.
Quote Reply
Re: [dstamos] move MENU to sub html_page_top In reply to
You can copy the menu code from sub html_footer to sub html_page_top. Once you're happy with the way the top of the page looks, remove the code from sub html_footer. It's better to test it before you actually delete anything in case you need to have the original handy. :-)


JPD
----------------------------------------------------
JPDeni's DBMan-ual
How to ask questions the smart way.
Quote Reply
Re: [JPDeni] move MENU to sub html_page_top In reply to
In Reply To:
You can copy the menu code from sub html_footer to sub html_page_top. Once you're happy with the way the top of the page looks, remove the code from sub html_footer. It's better to test it before you actually delete anything in case you need to have the original handy. :-)

Hi Jdeni,

I tried that and i get "DBMan encountered an internal error. Please enable debugging to view.". I copied the menu items inside the curly brackets only. Maybe i need to copy my code to this thread for you to see ?

Last edited by:

dstamos: Jan 17, 2006, 10:40 AM
Quote Reply
Re: [dstamos] move MENU to sub html_page_top In reply to
This is what you should be copying from sub html_footer:

Code:

print qq!<P align=center><$font>!;
print qq!| <A HREF="$db_script_link_url">Home</A> !;
print qq!| <A HREF="$db_script_link_url&add_form=1">Add</A> ! if ($per_add);
print qq!| <A HREF="$db_script_link_url&view_search=1">View</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&delete_search=1">Delete</A> ! if ($per_del);
print qq!| <A HREF="$db_script_link_url&modify_search=1">Modify</A> ! if ($per_mod);
print qq!| <A HREF="$db_script_link_url&view_records=1&$db_key=*">List All</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&admin_display=1">Admin</A> ! if ($per_admin);
print qq!| <A HREF="$db_script_link_url&logoff=1">Log Off</A> |!;
print qq!</font></p>!;


JPD
----------------------------------------------------
JPDeni's DBMan-ual
How to ask questions the smart way.
Quote Reply
Re: [JPDeni] move MENU to sub html_page_top In reply to
In Reply To:
This is what you should be copying from sub html_footer:

Code:

print qq!<P align=center><$font>!;
print qq!| <A HREF="$db_script_link_url">Home</A> !;
print qq!| <A HREF="$db_script_link_url&add_form=1">Add</A> ! if ($per_add);
print qq!| <A HREF="$db_script_link_url&view_search=1">View</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&delete_search=1">Delete</A> ! if ($per_del);
print qq!| <A HREF="$db_script_link_url&modify_search=1">Modify</A> ! if ($per_mod);
print qq!| <A HREF="$db_script_link_url&view_records=1&$db_key=*">List All</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&admin_display=1">Admin</A> ! if ($per_admin);
print qq!| <A HREF="$db_script_link_url&logoff=1">Log Off</A> |!;
print qq!</font></p>!;
JPD, thats exactly what i did.

Below is my code, i indicated where the menu would be with " *** MENU WOULD GO HERE **** ".




sub html_page_top {
# --------------------------------------------------------
# This is where you define what all of your web pages will look like.
# You can change the background color, add a background image (be sure to use the
# complete URL to your background image and not a relative URL), define the color of
# normal text and links -- all just as you would do with a regular html page.
# Be sure to leave in the first line -- &html_print_headers -- and to put your html
# formatting between "print qq|" and "|;"

&html_print_headers;

print qq|
<head>

<title>$html_title: $page_title</title>
<link rel="STYLESHEET" href="http://10.160.100.43/anime.css" type="text/css"></head>


<table align="center" border="0" cellpadding="0" cellspacing="0" width="700" height=400><tbody>
<tr>
<td class="pel-l" valign=top>

<table valign="center" bgcolor="#f5f5f5" border="0" cellpadding="0" cellspacing="0" width="100%"><tbody><tr>
<td align="left"><font class="nar">

*** MENU WOULD GO HERE ****

</font></td>
</tr><tr><td colspan="4"><img src="http://10.160.100.43/dot.gif" height="1" width="100%"></td></tr></tbody></table>
<table valign="center" bgcolor="#ffffff" border="0" cellpadding="0" cellspacing="0" width="100%" height=300><tbody><tr>

<td align="left" valign=top>
|;

}
Quote Reply
Re: [dstamos] move MENU to sub html_page_top In reply to
Just a few things to add, bolded in red below:

<table valign="center" bgcolor="#f5f5f5" border="0" cellpadding="0" cellspacing="0" width="100%"><tbody><tr>
<td align="left"><font class="nar"> |;

*** MENU WOULD GO HERE ****

print qq|</font></td>


JPD
----------------------------------------------------
JPDeni's DBMan-ual
How to ask questions the smart way.
Quote Reply
Re: [JPDeni] move MENU to sub html_page_top In reply to
jpd, that worked great for the exception that the HOME link is always there when not logged in.

is there something missing ?

<table valign="center" bgcolor="#f5f5f5" border="0" cellpadding="0" cellspacing="0" width="100%"><tbody><tr>
<td align="left"><font class="nar">|;

print qq!<P align=center><$font>!;
print qq!| <A HREF="$db_script_link_url">Home</A> !;
print qq!| <A HREF="$db_script_link_url&add_form=1">Add</A> ! if ($per_add);
print qq!| <A HREF="$db_script_link_url&view_search=1">View</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&delete_search=1">Delete</A> ! if ($per_del);
print qq!| <A HREF="$db_script_link_url&modify_search=1">Modify</A> ! if ($per_mod);
print qq!| <A HREF="$db_script_link_url&view_records=1&$db_key=*">List All</A> ! if ($per_view);
print qq!| <A HREF="$db_script_link_url&admin_display=1">Admin</A> ! if ($per_admin);
print qq!| <A HREF="$db_script_link_url&logoff=1">Log Off</A> ! unless (($db_userid eq "default") || ($db_userid eq ""));
print qq!|</p>!;

print qq|</font></td>
</tr><tr><td colspan="4"><img src="http://10.160.100.43/dot.gif" height="1" width="100%"></td></tr></tbody></table>
Quote Reply
Re: [dstamos] move MENU to sub html_page_top In reply to
Quote:
is there something missing ?

No. The Home link is always supposed to be there. It can be changed. What did you want?


JPD
----------------------------------------------------
JPDeni's DBMan-ual
How to ask questions the smart way.