Jump to content

Creating Custom Pages within WHMCS Template Doesn't seem to work!


Recommended Posts



I'm trying to do this with template which has already made external pages which link to WHMCS and its WHMCS Template.


I've copied the source of page called sharedhosting.php to sharedhosting2.php both files point to the same template file


Here is my problem when you load the files it looks different one seems to load in the whmcs wapper and the other which come's with the template doesn't.





$pagetitle = 'Shared Hosting';
$pageicon = "images/support/clientarea.gif";
$breadcrumbnav = '<a href="index.php">'.$_LANG['globalsystemname'].'</a>';
$breadcrumbnav .= ' > <a href="sharedhosting.php">Shared Hosting</a>'; 


if ($_SESSION['uid']) {
 # User is Logged In - put any code you like here

# To assign variables in Smarty use the following syntax.
# This can then be used as {$variablename} in the template

$smartyvalues["variablename"] = $value; 

# Define the template filename to be used without the .tpl extension

$templatefile = "sharedhosting"; 












Why do i have WHMCS Menu's in the 2nd file, I want it to look like the first file with no WHMCS Wapper

Link to comment
Share on other sites

It's because this particular template needs an additional modification. The header and footer both have sections (divs and html) that are displayed with an "if". So in your header.tpl you should have something like this:


{if $filename eq 'index' or $filename eq 'sharedhosting'}


And the very first line of your footer.tpl should be like this one:

{if $filename eq 'index' or $filename eq 'sharedhosting'}


To solve your problems try to make this:

{if $filename eq 'index' or $filename eq 'sharedhosting' or $filename eq 'sharedhosting2'}


{if $filename eq 'index' or $filename eq 'sharedhosting' or $filename eq 'sharedhosting2'}

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.

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