The issue I am having is I use a class function and then i use lemonade-php function as well and the two seem not to like each other.
on my index.php page I have the following
require_once("system/limonade.php");
require_once("system/core.php");
$redi = new syscore();
$redi->connect($siteDBUserName,$siteDBPass,$siteDBURL,$siteDBPort,$siteDB);
include("templates/{$siteTemp}/header.tpl");
dispatch_get("/**", "main");
function main(){
if(is_dir("plugins".params(0)) && params(0) != "")
{
print "checking to see if plugin active";
}
else
{
set('post_url', params(0));
require render("templates/main/fullwidth.tpl");
return render('fullwidth');
}
}
dispatch_get("/plugins/**", "plugin");
function plugin(){
$plugin = params(0);
print $plugin;
}
run();
I know the core.php class function syscore is working cos in the header.tpl i call for the menu and it shows (you see no lemonade code there)
but when I require
set('post_url', params(0));
require render("templates/main/fullwidth.tpl");
return render('fullwidth');
it will send the post_url however I can seem to keep the $redi working, it says it can find the $redi->post() function which is in the core.php
the fullwidth.tpl file has the following
<?php
function fullwidth($vars){ extract($vars);
print h($post_url);
print_r($redi->post(h($post_url)));
}
?>
if someone could help solve this issue that would be helpful. I must be doing something wrong.
thanks
Russell Harrower