computerbob Posted June 7, 2009 Share Posted June 7, 2009 Maybe this is just a pipe dream, but what I want to do is have multiple domain sale site all using the WHMCS. Since they will all be under the same company, I have WHMCS installed in domain-a.com/billing/whmcs and it is working fine. I now want to have domain-B.com, domain-C.com and so on as landing page. I have created multiple WHMCS templetes, one for each site. Now my problem is calling them so they display in each of the domains. I think I have been able to get the ?systdl=template call on the end of a URL. This seem to work a little. But when I click on a link with the WHMCS template I called it displays the default templete with it header/footer and left side menu panel. So maybe I just trying to do something that can't be done. I just don't know. I also know this seem to be a incomplete explaination. I have tried to put into words what my mind thinks I want to do. I have been using WHMCS for over a year now and like it a lot. So if someone would like to start up a dialog on this, that would be great. I"m also looking for any coding examples I can get. The doc on the WHMCS site are OK, but lack examples. Here is one from the knowledgebase.tpl. I tried to put the ?systpl=template on the href line but it doesn't seem to do anything. {foreach key=num item=kbcat from=$kbcats} <td width="33%" valign="top"><img src="images/folder.gif" border="0" align="middle" alt="" /> <strong><a href="{if $seof riendlyurls}knowledgebase/{$kbcat.id}/{$kbcat.urlfriendlyname}{else}knowledgebase.php?action=displaycat&catid={$kbca t.id}{/if}?systpl=test1">{$kbcat.name}</a></strong> ({$kbcat.numarticles})<br /> {$kbcat.description} Bob Levin 0 Quote Link to comment Share on other sites More sharing options...
robb3369 Posted June 7, 2009 Share Posted June 7, 2009 How about adding something like this to your .htaccess file: RewriteCond %{HTTP_HOST} ^alt-hosting.com [NC] RewriteRule ^(.*)$ http://real-hosting.com/$1?systpl=alternate [QSA,L,R=301] This should allow the alt-hosting.com URL to be redirected to the real-hosting.com site, but with the "alternate" template being loaded... everything else should be the same. 0 Quote Link to comment Share on other sites More sharing options...
computerbob Posted June 7, 2009 Author Share Posted June 7, 2009 That is a very interesting idea. I have tried it but I dont' think it working right. I will have to troubleshoot that. But I have been working on this almost non-stop. I think I need a break for a while. Here is what I have done. Created a page. Put a iframe on it pointing to the WHMCS with the ?systpl="test2". Display the page and it look fine in both IE-8 and Firefox. Using Firefox if you click any link it will display the correct template (test2) every time you click a link in the iframe. That is what I think I'm looking for. I didnt' have to modify anything inside any of the template to make this work. Just used the systpl="test2" on the iframe src url. But in IE it doesn't When you click a link in the iframe it reverts back to the default Template in WHMCS. Take a look. I will be leaving this page up for a while. http://afforablehosting.com/2.html Bob Levin 0 Quote Link to comment Share on other sites More sharing options...
computerbob Posted June 8, 2009 Author Share Posted June 8, 2009 Doing more investagating on this and find that the when using IE it doesn't work right. Firefox it does work right. When calling WHMCS using the systpl=template on the end of the URL in a IFrame, a cookie is supose to be set. It doens't get set because IE doesn't trust the IFrame url. If you look at the status line on the IE Browser you will see the little eye for Privacy Report. The URL for the IFrame are listed under Microsoft IE Restricted website. Becasue the cookie doesnt' get set, the template selected with the systpl=template doesn't work and you end up using what ever is the default WHMCS template. So far I haven't found a way to fix this yet. I'm open to any and all ideas at this time. Bob Levin 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.