Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Nothing...nothing at all. Please help!!!

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Installation and Setup
View previous topic :: View next topic  
Author Message
bloatedfish
Smarty n00b


Joined: 08 Feb 2004
Posts: 2

PostPosted: Sun Feb 08, 2004 5:44 pm    Post subject: Nothing...nothing at all. Please help!!! Reply with quote

I think smarty is great. I got it to work once, but I moved some stuff around and now it no work. I get nothing but a blank page.

Why does smarty not give you any debuging? This seems totally illogical and I'm sure turns lots of people off to the product. It really needs to spit out some sort of debugging when the install is incorrect. Like "Hey! Stupid! You forgot to create the templates directory, or the path you gave me is wrong!".

I have all logging turned on in php.ini, and still i get nothing! This is very frustating. I there away to overcome this?

Anyway, here is my setup.php

Code:

<?
// load Smarty library
require('Smarty.class.php');
require('lib/ConnectionManager.php');

// The setup.php file is a good place to load
// required application library files, and you
// can do that right here. An example:
// require('guestbook/guestbook.lib.php');

class Smarty_ProjectManager extends Smarty {

    var $connectionManager;
    var $hostname = "localhost";
    var $database = "bates_inc_com";
    var $password = "passwd";
    var $user = "user";
   
    function Smarty_WeddingPlanner() {

         // Class Constructor. These automatically get set with each new instance.
       
      $this->Smarty();

      $this->template_dir = '/home/award/public_html/smarty/project_manager/templates';
      $this->compile_dir = '/opt/smarty/customer_manager/templates_c';
      $this->config_dir = '/home/award/public_html/smarty/project_manager/configs';
      $this->cache_dir = '/opt/smarty/customer_manager/cache';
      
      $this->caching = false;
      
      $this->assign('databaseServer', 'localhost');
      $this->assign('username', 'user');
      $this->assign('password', 'password');
      
      $this->assign('database', ProjectManager);
      
      $this->assign('app_name','Apwebware Project Manager');
      $this->debugging = true;

        $this->connectionManager = new ConnectionManager($this->hostname, $this->database, $this->user, $this->password);
   }
   
}


and my index.php
Code:

<?

include ("setup.php");

$smarty = new Smarty_ProjectManager();

@$db = $smarty->connectionManager->getConnection();

$query = "select * from definitions";
$result = mysql_query($query, $db);

$rows = array();

while($row = mysql_fetch_array($result))
{
    array_push($rows, $row);
}

$smarty->assign("rows", $rows);

$smarty->display("home.tpl");

?>


It does not mater what template I specify, nothing works. and the template_c and cache dirs have 777 permissions. templates and configs are a+r. So, the permisssion, as I understand are good to go. No?

Someone please help!!!
Back to top
View user's profile Send private message
bloatedfish
Smarty n00b


Joined: 08 Feb 2004
Posts: 2

PostPosted: Sun Feb 08, 2004 6:49 pm    Post subject: Fixed Reply with quote

Whoops! Check out the constructor above! Embarassed

WeddingPlanner != ProjectManager

That's what I get for cut and paste!

Obviously correcting that mistake solved the problem.

This is like debugging ant Mr. Green
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Smarty Forum Index -> Installation and Setup All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP