Jump to content


Photo

Header.php


  • Please log in to reply
7 replies to this topic

#1 jetblab

jetblab

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 02 December 2008 - 10:02 PM

Hello, Have just recently purchased Avactis and am starting the tedious process of customizing the store. Lot of questions... 1) What is the fastest most efficient way of doing this? Do I have to manually update all the templates? What if I make a slight change or modification to my template? Do I have to go back and change ALL of them? 2) Is it possible to include a php call for a header.php file and then just have to change that one file if I have a update? I must be missing the manual for customizing...I'm sure it's on this site somewhere. Any ideas? Thanks for all your help.

#2 jetblab

jetblab

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 08 December 2008 - 11:56 PM

Hello,

Have just recently purchased Avactis and am starting the tedious process of customizing the store. Lot of questions...

1) What is the fastest most efficient way of doing this? Do I have to manually update all the templates? What if I make a slight change or modification to my template? Do I have to go back and change ALL of them?

2) Is it possible to include a php call for a header.php file and then just have to change that one file if I have a update?

I must be missing the manual for customizing...I'm sure it's on this site somewhere. Any ideas?

Thanks for all your help.



I'll answer my own question. Yes, this is possible and I have incorporated this "feature" into my site whereby if I want to change my logo, tagline, or my horizontal navbar (or anything else), it gets the code from a header.tpl.html template place in the storefront-files/includes folder.

This does make me a little nervous that over a week, this post went unanswered by any forum admins. I hope that isn't a sign of things to come...

#3 Marco

Marco

    Avactis Team Member

  • Administrators
  • PipPipPipPipPip
  • 308 posts

Posted 09 December 2008 - 07:57 AM

Sorry for that, we're just so busy with the upcoming release...

The main thing everybody should understand: it's all just HTML with PHP tags. There's nothing special with it. Edit, rewrite, include, split and any other way change these files according to your preferences.

The other most important thing is avactis-layouts/storefront-layout.ini—be sure it's correct.

#4 TestZero

TestZero

    Newbie

  • Members
  • Pip
  • 2 posts

Posted 05 February 2009 - 08:18 PM

I'll answer my own question. Yes, this is possible and I have incorporated this "feature" into my site whereby if I want to change my logo, tagline, or my horizontal navbar (or anything else), it gets the code from a header.tpl.html template place in the storefront-files/includes folder.


Hello,
I have wondered about this too. Where do you put the reference/link to the header.tpl.html file so the cart has access to it? And, how do you keep the flower store header from being the default?

There is no clear tutorial on how to change the site appearance...

Thanks,
TZ

#5 Albert

Albert

    Novice

  • Members
  • PipPip
  • 15 posts

Posted 02 May 2009 - 09:30 PM

I am very much confused about all this thing about website, but reading a lot i am also pick up and little by little I starter learning how to put up a website. Thanks you for ideas and inputs.

#6 Linda

Linda

    Avactis Integrator

  • Members
  • PipPipPipPipPip
  • 396 posts

Posted 05 May 2009 - 12:47 AM

Hi Everyone,

Marco is correct anything can be added anywhere in your design.
Making your own include is actually very simple.

It simply needs to be whatever the code was that you would normally put into your document.

I actually do this with CSS rather than an include if it only calls an image.

Here is an example:
This is my tag for my header image in the index template

<div class="Header-png"></div> <!-- Header Image -->

Here is the CSS for that tag in my style.css

div.Header-png {
position: absolute;
z-index:-2;
top: 0;
left: 0;
width: 898px;
height: 200px;
background-image: url('images/Header.png');
background-repeat: no-repeat;
background-position: left top;
}

In the future if you want to change the image you simply make a new image and exchange it and viola you have a new header.

For those of you who want to make an include?
Lets take a different piece of code where your header image is called.

<div align="left"><img src="images/text-hed.gif" width="500" height="60" alt="header image" border="0"></div>
<br /><br />
<div class="tnav" align="right">
<?php include('storefront-files/includes/main_menu2.tpl.html'); ?>
</div>
<hr>
<br />

Copy the red bit of code into an empty document:


<div align="left"><img src="images/text-hed.gif" width="500" height="60" alt="header image" border="0"></div>

name and save it say ... header.tpl.html ... upload to your storefront-files/include/ ... directory

Then where the tag was above in your doc code you will now replace with the php that will call that tpl.html like this:

<?php include('storefront-files/includes/header.tpl.html'); ?>
<br /><br />
<div class="tnav" align="right">
<?php include('storefront-files/includes/main_menu2.tpl.html'); ?>
</div>
<hr>
<br />

Not that hard once you get the hang of it all.
CSS and includes make your whole website changes very manageable from easy access locations.

Linda :)
I can't is an excuse for mediocrity.

#7 Jodes

Jodes

    Novice

  • Members
  • PipPip
  • 34 posts

Posted 03 December 2010 - 06:43 AM

Is this code still the same with the current version of Avactis? V2.0 I ask because I wouldn't mind giving it a go (setting up what you've explained above). But wanted to check first before playing around with any files.

#8 Oleg

Oleg

    Avactis Team Member

  • Administrators
  • PipPipPipPipPipPip
  • 510 posts

Posted 06 January 2011 - 07:47 AM

Is this code still the same with the current version of Avactis? V2.0

I ask because I wouldn't mind giving it a go (setting up what you've explained above). But wanted to check first before playing around with any files.


It is even easy now in Avactis 2.0.

Use visual layout editor (Page Manager) to modify blocks. You can add own PHP code there and even create your own blocks.

More details: http://docs.avactis....age_manager.htm