Jump to content

How to edit the copy of a template page


neairheart

Recommended Posts

Hello, for my website I need a page very similar to the contact us page that the template already provides so I figured that I would simply make a copy of that page and edit the copy to suit my needs. So I copied both the php and tlp files for the contact page and renamed them both and I did update the tlp file to reflect the name change of the php file. However when I edit this copied version it does not change no matter what I do to it. even if I delete the whole thing the page just appears as normal when I refresh.

Link to comment
Share on other sites

  • WHMCS Technical Analyst

It is not possible to edit the contact.php page to use a different template file, but you can customise the contact.tpl template file directly. Another option if you need the default contact form and your custom one would be to look for a query string parameter inside the template, and based on that, render the form differently, for example:

 

{if $smarty.get.showform eq "quote"}
Quote form goes here
{else}
Default form goes here
{/if}

 

The Smarty docs on accessing request variables are here: http://www.smarty.net/docs/en/language.variables.smarty.tpl#language.variables.smarty.request

 

-Eddy

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated