trackpads
12-19-2004, 10:00 PM
First, let me say that this is my first hack and I appreciate any and all feedback. I want to acknowledge the idea which was given to me by using atroll's Additional Navbar hack. If you use this please click install on his aswell:
https://vborg.vbsupport.ru/showthread.php?t=65198
>>>---------------------------->
Software needed:
VB 3.03 (may work on others, didnt test)
PhotoPost 4.8.5
>>>---------------------------->
What it does & why:
On my site I have a standard navigation system set up on the site and while I loved the new integration that comes with PP 4.8.5 I wanted to keep the gallery with its own seperate identity without losing the integration features like style sheets and others. So using atrolls hack as a guide I create both a seperate VB Header and Navbar for the Gallery.
You can see it in action here:
My Forum: http://www.trackpad.com/forum
My Gallery: http://www.trackpads.com/gallery
>>>---------------------------->
Here is how you do it:
Step 1 - Create/Edit New Templates
You will need to create 2 new templates in your VB style(s) that you use. First thing is to open your current header & navbar templates and copy the information as a basis for your new ones. Save them in txt files or wherever for the moment.
A. Create a new template called headerg and paste the information from the original header. Make any gallery specific modifcations that you want. You can always come back later through and edit the file.
B. Create a new template called navbarg and paste the information from the original navbar. Make any gallery specific modifcations that you want. You can always come back later through and edit the file.
When this step is complete you should have 2 new custom templates called headerg & navbarg.
C. Edit your phpinclude_start template and add the following anywhere in the file:
eval('$navbarg = "' . fetch_template('navbarg') . '";');
eval('$headerg = "' . fetch_template('headerg') . '";');
>>>---------------------------->
Step 2 - File Edits
VB File Edits:
A. Since the template is uncached you will have an extra query on each page. To fix, open global.php and FIND:
// misc useful
ADD BELOW:
'navbarg',
'headerg',
Photopost File Edits:
A. Open the file header-inc.php and FIND:
eval('$navbar = "' . fetch_template('navbar') . '";');
And REPLACE with the following:
eval('$navbarg = "' . fetch_template('navbarg') . '";');
B. In the same file FIND:
{ppheader}
</head>
<body onload="editInit();">
$header
$navbar
<div align="center">
And REPLACE with:
{ppheader}
</head>
<body onload="editInit();">
$headerg
$navbarg
<div align="center">
C. AGAIN in the same file FIND:
{ppheader}
</head>
<body onload="editInit();">
$header
$navbar
<div align="center">
And AGAIN REPLACE with:
{ppheader}
</head>
<body onload="editInit();">
$headerg
$navbarg
<div align="center">
D. In the same file FIND:
{ppheader}
</head>
<body>
$header
$navbar
<div align="center">
And AGAIN REPLACE with:
{ppheader}
</head>
<body>
$headerg
$navbarg
<div align="center">
>>>---------------------------->
Finally. Save all files and upload to the server. REMEMBER, always make a backup incase something is wrong so you can just re-upload the original without de-hacking the file.
Again, no screenshots are attached. Just look at the differences on my forum and gallery. If you have any questions please ask, I am no expert though but I will try to help you. Please clickty click install if you like and use. It will make my day :) :)
https://vborg.vbsupport.ru/showthread.php?t=65198
>>>---------------------------->
Software needed:
VB 3.03 (may work on others, didnt test)
PhotoPost 4.8.5
>>>---------------------------->
What it does & why:
On my site I have a standard navigation system set up on the site and while I loved the new integration that comes with PP 4.8.5 I wanted to keep the gallery with its own seperate identity without losing the integration features like style sheets and others. So using atrolls hack as a guide I create both a seperate VB Header and Navbar for the Gallery.
You can see it in action here:
My Forum: http://www.trackpad.com/forum
My Gallery: http://www.trackpads.com/gallery
>>>---------------------------->
Here is how you do it:
Step 1 - Create/Edit New Templates
You will need to create 2 new templates in your VB style(s) that you use. First thing is to open your current header & navbar templates and copy the information as a basis for your new ones. Save them in txt files or wherever for the moment.
A. Create a new template called headerg and paste the information from the original header. Make any gallery specific modifcations that you want. You can always come back later through and edit the file.
B. Create a new template called navbarg and paste the information from the original navbar. Make any gallery specific modifcations that you want. You can always come back later through and edit the file.
When this step is complete you should have 2 new custom templates called headerg & navbarg.
C. Edit your phpinclude_start template and add the following anywhere in the file:
eval('$navbarg = "' . fetch_template('navbarg') . '";');
eval('$headerg = "' . fetch_template('headerg') . '";');
>>>---------------------------->
Step 2 - File Edits
VB File Edits:
A. Since the template is uncached you will have an extra query on each page. To fix, open global.php and FIND:
// misc useful
ADD BELOW:
'navbarg',
'headerg',
Photopost File Edits:
A. Open the file header-inc.php and FIND:
eval('$navbar = "' . fetch_template('navbar') . '";');
And REPLACE with the following:
eval('$navbarg = "' . fetch_template('navbarg') . '";');
B. In the same file FIND:
{ppheader}
</head>
<body onload="editInit();">
$header
$navbar
<div align="center">
And REPLACE with:
{ppheader}
</head>
<body onload="editInit();">
$headerg
$navbarg
<div align="center">
C. AGAIN in the same file FIND:
{ppheader}
</head>
<body onload="editInit();">
$header
$navbar
<div align="center">
And AGAIN REPLACE with:
{ppheader}
</head>
<body onload="editInit();">
$headerg
$navbarg
<div align="center">
D. In the same file FIND:
{ppheader}
</head>
<body>
$header
$navbar
<div align="center">
And AGAIN REPLACE with:
{ppheader}
</head>
<body>
$headerg
$navbarg
<div align="center">
>>>---------------------------->
Finally. Save all files and upload to the server. REMEMBER, always make a backup incase something is wrong so you can just re-upload the original without de-hacking the file.
Again, no screenshots are attached. Just look at the differences on my forum and gallery. If you have any questions please ask, I am no expert though but I will try to help you. Please clickty click install if you like and use. It will make my day :) :)