• Online Demo
  • 30-day Free Trial

Go Back   Blesta Forums > Community > General Discussion

Reply
 
Thread Tools Display Modes
  #1  
Old 12-16-2008, 02:00 AM
jpilon jpilon is offline
Junior Member
 
Join Date: Dec 2007
Posts: 21
Default Creating a custom page for the users control panel issues

Hello,

Having some major problems creating a custom page for the users control panel off the example php file Paul sent to me today with v2.0 of blesta.

Here is what I'm trying to do:
I want to display a custom page in the right column, and all the users info appears in the left column.

I've been trying to figure it out, but here is the code I'm using in the example.php file:

security($mysqldb, "user", 3);
$pdtfile = "u-structure.pdt";
$pdt = new Template();
$pdt->set('title', "Your page title");
$pdt->set('page', "clients");
$pdtcfile = "u-main.pdt";
$pdtc = new Template();
$pdtc->set('action', true);
$pdtffile = "my_custom_page.pdt";
$pdtf = new Template();

Can you tell me what I'm doing wrong?

Thanks,
Joe
Reply With Quote
  #2  
Old 12-16-2008, 04:43 AM
jpilon jpilon is offline
Junior Member
 
Join Date: Dec 2007
Posts: 21
Default

Hello,

Figured out how to properly show the template, but I still need some help setting the data to populate the left sideboxes (user contact info, credit/invoice totals, etc).

Also, is there paypal payments pro support for v2?
Reply With Quote
  #3  
Old 12-16-2008, 05:26 AM
Paul's Avatar
Paul Paul is online now
Blesta Developer
 
Join Date: Apr 2006
Location: Wherever I go, there I am.
Posts: 1,470
Send a message via AIM to Paul Send a message via MSN to Paul
Default

Usually you'd be responsible for building those queries to select the data you want.. but their may be some internal functions available that you could tap into... though we do not have any documentation on them.

Get array of user info

PHP Code:
auserinfo($mysqldb$_SESSION['sess_uid']); 
Get array of contact info

PHP Code:
contactinfo($mysqldb$_SESSION['sess_uid']); 
Total due

PHP Code:
totaldue($mysqldb$_SESSION['sess_uid'], false); 
__________________
Paul
Misc Stuff Guy

Blesta
Professional Billing
www.blesta.com
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT. The time now is 05:16 AM.