Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes
Author Message
thunderbird
Hangin' Around


Joined: Jul 13, 2005
Posts: 38

PostPosted: Mon Sep 04, 2006 8:24 am Reply with quote

HI,

I have decided that I am going to chage to the look of the standard nav menu at the top (Home, your accout, download, etc). I have found a very nice DHTML nav menu that I would love to put in its place.

The big problem that I have is that the menu system needs to be placed in the head tag but in the header.html file from the theme there is no head tag.

Can someone help me out?

Thanks
 
View user's profile Send private message
gregexp
The Mouse Is Extension Of Arm


Joined: Feb 21, 2006
Posts: 1497
Location: In front of a screen....HELP! lol

PostPosted: Mon Sep 04, 2006 1:47 pm Reply with quote

check header.php in the root for head tags and theme.php too.

_________________
For those who stand shall NEVER fall and those who fall shall RISE once more!! 
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
fkelly
Former Moderator in Good Standing


Joined: Aug 30, 2005
Posts: 3312
Location: near Albany NY

PostPosted: Mon Sep 04, 2006 3:16 pm Reply with quote

Just be aware that:

1. if you modify header.php in the root then you are going to affect all themes unless you conditionally include the nav thing when the one theme you are modifying is the selected theme. No big deal if you only use one theme but it could be messy if you provide a range of themes for users to select from.

2. you'll probably have to modify header.html (where it exists cause it's not in all themes) and theme.php to take out the current navbar. If you support 10 themes you'll have to make the modifications 10 times. It can get messy.

3. if you upgrade your distribution you'll have to save off your modifications and interleave them with the themes from the upgraded distribution.

Alternatively, I suppose you could clone a current theme and modify it under a different name.

Not trying to discourage you but these are things that you will face.
 
View user's profile Send private message Visit poster's website
thunderbird
PostPosted: Mon Sep 04, 2006 3:31 pm Reply with quote

I just use one theme and don't allow theme switching.

I have tried to make the changes but with no luck. I am using transmenu but if anyone has a good nav menu that doesn't have to be loaded from the headed, please let me know.

thanks
 
Guardian2003
Site Admin


Joined: Aug 28, 2003
Posts: 6793
Location: Ha Noi, Viet Nam

PostPosted: Mon Sep 04, 2006 5:23 pm Reply with quote

I'm not sure if this fits your requirements and it isnt free but I have used this one in the past Only registered users can see links on this board! Get registered or login!
 
View user's profile Send private message Send e-mail
thunderbird
PostPosted: Mon Sep 04, 2006 6:09 pm Reply with quote

Can you tell me where to load the code into? The theme header.html doesn't had a head tag. Thats where I am stuck

Thanks
 
fkelly
PostPosted: Mon Sep 04, 2006 6:36 pm Reply with quote

In your Nuke Root directory the program header.php puts in the opening and closing head tags. In between it puts in the doctype and loads javascript files and includes any custom header files you may have and then it calls the themeheader function which is in the theme.php file of whatever theme you are using.

The themeheader function loads anything that is going into a header (but not between the head tags) and then uses the header.html to output this. Your standard navbar is in there.

If what you want to load has go between the head tags then I guess you'll have to put it in header.php. But if it takes care of the navbar then you'll have to eliminate that section from the themeheader function. Without seeing the code you are considering using I can't say any more than that. And if you are going to start hacking the standard Nuke code it behooves you to figure out where it should go yourself or else you'll never be able to support it.
 
thunderbird
PostPosted: Mon Sep 04, 2006 8:22 pm Reply with quote

OK, so I have place the code <scr~pt type="text/javascript" language="JavaScript1.2" src="stmenu.js"></scr~pt> outside the the php code in header.php in the nuke root.

The below code is what I need to replace the standard code in the header.html. I have also inceded the header.html code below. I have tried to paste the code myself but when I do the standard nav goes away but the new nav does not show up


Code:
<scr~pt type="text/javascript" language="JavaScript1.2">

<!--
stm_bm(["menu6922",650,"","blank.gif",0,"","",0,0,250,0,1000,1,0,0,"","",0,0,1,2,"default","hand",""],this);
stm_bp("p0",[0,4,0,0,2,3,0,0,100,"",-2,"",-2,50,0,0,"#999999","#FFFFF7","",3,1,1,"#000000"]);
stm_ai("p0i0",[0,"Home","","",-1,-1,0,"","_self","","","","",0,0,0,"","",0,0,0,0,1,"#FFFFF7",0,"#B5BED6",0,"","",3,3,1,1,"#FFFFF7","#000000","#000000","#000000","8pt Verdana","8pt Verdana",0,0]);
stm_aix("p0i1","p0i0",[0,"Members"]);
stm_aix("p0i2","p0i0",[0,"News"]);
stm_aix("p0i3","p0i0",[0,"Links"]);
stm_ep();
stm_em();
//-->
</scr~pt>


Code:
<center>

<table width="923" border="0" cellspacing="0" cellpadding="2" height="86">

  <tr>

    <td background="themes/BiteMe/images/head1.jpg" width="976" height="82">
    <table width="931" border="0" cellspacing="2" cellpadding="0" height="142">

        <tr>

          <td background="themes/BiteMe/images/head1.jpg" width="961" height="111">
          <table width="931" border="0" cellspacing="0" cellpadding="0" height="64">

              <tr>

                <td width="7" height="64">
                <p align="center">
                <td nowrap width="927" height="64">
               
                </td></td>

                <td width="4" height="64">&nbsp;</td>

              </tr>

            </table></td>

        </tr>

        <tr>

          <td width="961" height="27">
          <table width="930" border="0" cellspacing="0" cellpadding="0">

              <tr>

                <td width="150" height="25" background=""><table width="100%" border="0" cellspacing="0" cellpadding="2">

                    <tr>

                      <td nowrap><font class="content" color="#FFFFFF">$theuser</font></td>

                    </tr>

                  </table></td>

                <td background="" width="630">
                <table width="100%" border="0" cellspacing="0" cellpadding="2" height="30">

                    <tr>

                      <td nowrap height="26">

<div align="center"><font class="links"><font color="#FFFFFF"><strong>::</strong></font><b><font color="#FFFFFF">&nbsp;</font><a href="index.php"><font color="#FFFFFF">Home</font></a><font color="#FFFFFF">

                    &nbsp;</font></b><font color="#FFFFFF"><strong>::</strong></font><b><font color="#FFFFFF">&nbsp;
  </font> <font color="#FFFFFF">

                    &nbsp;</font></b><font color="#FFFFFF"><strong>:Biography:</strong></font><b><font color="#FFFFFF">&nbsp;
  </font> <a href="modules.php?name=Your_Account"><font color="#FFFFFF">Your

                    Account</font></a><font color="#FFFFFF"> &nbsp;</font></b><font color="#FFFFFF"><strong>::</strong></font><b><font color="#FFFFFF">&nbsp;
  </font> <a href="modules.php?name=Forums"><font color="#FFFFFF">Forums</font></a><font color="#FFFFFF">

                    &nbsp;</font></b><font color="#FFFFFF"><strong>::</strong></font></font></div></td>

                    </tr>

                  </table></td>

                <td width="150" background=""><table width="100%" border="0" cellspacing="0" cellpadding="2">

                    <tr>

                      <td nowrap>

<div align="center"><font class="content">

                          <scr~pt type="text/javascript">

<!--   // Array ofmonth Names

var monthNames = new Array( "January","February","March","April","May","June","July","August","September","October","November","December");

var now = new Date();

thisYear = now.getYear();

if(thisYear < 1900) {thisYear += 1900}; // corrections if Y2K display problem

document.write(monthNames[now.getMonth()] + " " + now.getDate() + ", " + thisYear);

// -->

  </scr~pt>

                          </font></div></td>

                    </tr>

                  </table></td>

              </tr>

            </table></td>

        </tr>

        </table></td>

  </tr>

</table>

<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center">

<tr valign="top">

  <td valign="top" width="1" bgcolor="000000">


Thanks for your help
 
Guardian2003
PostPosted: Tue Sep 05, 2006 2:21 am Reply with quote

If you are using the sothink dhtml menu creator, when creating the menu use the 'incude files' option. I cretaed a directory called 'menu' in my nuke root to hold all the files, then you only need to call one file in your footer.html - and it makes mainenace or changing our menu options oh so much easier.
Here is the code I last used so you can see how I did it.
Code:


<center>
<table width="926" border="0" cellspacing="0" cellpadding="2" height="86">

  <tr>
     <td  width="979" height="82">
     <table width="931" border="0" cellspacing="2" cellpadding="0" height="142">


  <tr>
     <td background="" width="961" height="111">
     <table width="931" border="0" cellspacing="0" cellpadding="0" height="64">

 
  <tr>
   <td width="7" height="64">
     <p align="center">
      <td nowrap width="927" height="64">
       <p align="center">
        <img border="0" src="themes/TrueBlue/images/logo.gif" width="445" height="57">
       </td>
        </td>

  <td width="4" height="64">&nbsp;</td>

    </tr>
    </table>
     </td>
      </tr>

<tr>
   <td width="961" height="27">
       <table width="932" border="0" cellspacing="0" cellpadding="0">
 <tr>
   <td width="150" height="25" background="">
      <table width="149" border="2" cellspacing="0" cellpadding="2" bordercolor="#0098E0" style="border-collapse: collapse">

<tr>
  <td nowrap width="145"><font class="content2" color="#FFFFFF">$theuser</font></td>
   </tr>
      </table>
         </td>

<td background="" width="630">
<table width="636" border="2" cellspacing="0" cellpadding="2" height="30" bordercolor="#0098E0" sty~~le="border-collapse: collapse">

<tr>
<td nowrap height="26" width="632">
<div align="center"><font class="links"><strong>.::</strong><b>&nbsp;<a href="index.php">Home</a>

&nbsp;</b><strong>::</strong><b>&nbsp; <a href="modules.php?name=Downloads">Downloads</a>
&nbsp;</b><strong>::</strong><b>&nbsp; <a href="modules.php?name=Your_Account">Your Account</a>
&nbsp;</b><strong>::</strong><b>&nbsp; <a href="modules.php?name=Forums">Forums</a>

&nbsp;</b><strong>::.</strong></font></div></td>

  </tr>
   </table>
      </td>

<td width="152" background="">
<table width="100%" border="2" cellspacing="0" cellpadding="2" bordercolor="#0098E0" st~~yle="border-collapse: collapse">

<tr>
<td nowrap>
<div align="center"><font class="content">
<scr~~ipt type="text/javascr~~ipt">

<!--   // Array ofmonth Names
var monthNames = new Array( "January","February","March","April","May","June","July","August","September","October","November","December");
var now = new Date();
thisYear = now.getYear();
if(thisYear < 1900) {thisYear += 1900}; // corrections if Y2K display problem
document.write(monthNames[now.getMonth()] + " " + now.getDate() + ", " + thisYear);
// -->

</scri~~pt></font></div></td>
   </tr>
      </table>
         </td>
            </tr>
               </table>
               
</td>
   </tr>
      </table>
      </td>
      </tr>
</table>

<!--start menu placement 
<table width="932" cellpadding="0" cellspacing="0" border="0">
<center>
<scri~~pt type="text/javascr~~ipt" language="JavaScri~~pt1.2" src="http://www.guildofsecurity.co.uk/site/menu/stmenu.js"></scri~~pt>
<script type="text/javascri~~pt" language="JavaScr~~ipt1.2" src="http://www.yoursite.com/menu/guildmenu.js"></scri~~pt>
</center>
</table>
 -end menu placement -->

<table width="100%" cellpadding="0" cellspacing="0" border="0" align="center">
<tr valign="top">
<td valign="top" width="1" bgcolor="ffffff">


As you can see, I kept the original menu in there just in case the users browser couldnt cope with the dhtml menu but the dhtml menu is actually displayed immediately under the original one.
 
thunderbird
PostPosted: Tue Sep 05, 2006 7:11 am Reply with quote

Sorry your confusing me. Whats the one file in the footer.html file?

Also I do not understand you code. I get nothing like this when I use my sothink.
 
Guardian2003
PostPosted: Tue Sep 05, 2006 7:47 am Reply with quote

When the software generates the code for you to use, it should offer several options of how that code is used, if you select the 'include files' option this will keep all the files required together in a directory of your choice so you only need to link to the files in your themes header.html like I have in my example.

If that option is not seen then perhaps it is only available in the full version software.
 
thunderbird
PostPosted: Tue Sep 05, 2006 8:39 am Reply with quote

I understand about the included file option as I do use it. I place the file in the nuke root in a folder called "js". But like I said in my last post, what file do you place in the footer and why is your code from the sothink software so different from mine?

Thanks
 
Guardian2003
PostPosted: Tue Sep 05, 2006 9:22 am Reply with quote

You don't need to place any code in the footer (unless you want the menu to appear in the footer ?? ).
The code to intialise the menu should be in header.html
I see from my code I was actually using two menus, you only need to insert
Code:
<scri~~pt type="text/javascr~~ipt" language="JavaScri~~pt1.2" src="http://www.yoursite.com/js/stmenu.js"></scri~~pt>
but I included the whole header.html file code so you could see where I had inserted it (within a centered table) but your header.html file will of course be different.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Themes

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©