 |
Smarty
The discussions here are for Smarty, a template engine for the PHP programming language. Dedicated server web hosting provided by Guru-host.eu. |
| View previous topic :: View next topic |
| Author |
Message |
cosmicx Smarty Rookie
Joined: 04 Jul 2012 Posts: 8
|
Posted: Wed Jul 04, 2012 1:13 am Post subject: How to combine smarty based html template files? |
|
|
hello gurus,
i am new here and just learning xhmtl/css by myself.
im trying to edit a smarty based template theme and i am having difficulties editing it.
the theme files are divided by parts, like for instance, one html file for header and footer and index.
my problem with these files comes in when i try to edit the, say for instance the header.html:
in the header file, the opening div tags for a particular div block is in here, and then the closing div tags were in the footer file.
and then in the index.html file, footer and header file is included.
now, my main inquiry is, is there a way to joined these files together so i may edit it with ease? and then separate the files again later on?
or is there any way to edit these files with ease? |
|
| Back to top |
|
mohrt Administrator
Joined: 16 Apr 2003 Posts: 7036 Location: Lincoln Nebraska, USA
|
Posted: Wed Jul 04, 2012 3:15 am Post subject: |
|
|
| try template inheritance, its far easier to manage. |
|
| Back to top |
|
cosmicx Smarty Rookie
Joined: 04 Jul 2012 Posts: 8
|
Posted: Fri Jul 06, 2012 12:45 am Post subject: |
|
|
thank you for the replay,
i'll read on that,
so you were referring to this one below?
http://www.smarty.net/inheritance
===
i tried to implement template inheritance but i got an error like this one below
THIS IMAGE |
|
| Back to top |
|
mohrt Administrator
Joined: 16 Apr 2003 Posts: 7036 Location: Lincoln Nebraska, USA
|
Posted: Fri Jul 06, 2012 1:34 am Post subject: |
|
|
| you have to use smarty 3. |
|
| Back to top |
|
cosmicx Smarty Rookie
Joined: 04 Jul 2012 Posts: 8
|
Posted: Fri Jul 06, 2012 1:44 am Post subject: |
|
|
alright...
but i have no idea on how to update the version.
my current version is 2.6.22
how do i update it to the latest version without breaking something. |
|
| Back to top |
|
mohrt Administrator
Joined: 16 Apr 2003 Posts: 7036 Location: Lincoln Nebraska, USA
|
Posted: Fri Jul 06, 2012 1:47 am Post subject: |
|
|
| read the text files that ship with smarty 3 first. and don't try it on a live site obviously... |
|
| Back to top |
|
|
|
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
|
Powered by phpBB © 2001, 2005 phpBB Group
|