Jump to content

dbconnect.php


vranghel

Recommended Posts

Hello everyone, I'm new here and I need help, I was using version 5 of WHMCS and updated to latest version 6.31, however some pages that used the dbconnect.php is not working (I know it was discontinued). I changed the file that used the dbconnect.php to init.php but the page is not found. Can anyone tell me how the file below should keep the init.php. Thank you.

 

<?php

 

define("CLIENTAREA",true);

 

require("dbconnect.php");

require("includes/functions.php");

require("includes/clientareafunctions.php");

 

$pagetitle = 'Hospedagem Linux';

$pageicon = "images/support/clientarea.gif";

$breadcrumbnav = '<a href="hospedagemlinux.php">'.$_LANG['globalsystemname'].'</a>';

$breadcrumbnav .= ' > <a href="hospedagemlinux.php">Hospedagem Linux</a>';

 

initialiseClientArea($pagetitle,$pageicon,$breadcrumbnav);

 

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 = "hospedagemlinux";

 

outputClientArea($templatefile);

 

?>

Link to comment
Share on other sites

http://docs.whmcs.com/Version_6.0_Release_Notes#Removal_of_Dbconnect.php

 

Removal of Dbconnect.php

 

6.0 sees the removal of the dbconnect.php file from the root WHMCS directory. This file has been deprecated since WHMCS Version 5.2 and has remained only for backwards compatibility with older modules. As of 6.0 however, any scripts which still rely on including the dbconnect.php file to function will need to be updated to instead include the init.php file. When including the init.php file, it is not necessary to include any other WHMCS files.

 

For reference, the most up-to-date code sample for creating your own custom client area pages which works in WHMCS 5.2.0 and later is available @ http://docs.whmcs.com/Creating_Pages

take a look at the Creating pages documentation too for the differences with your code.

 

http://docs.whmcs.com/Creating_Pages

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