Results 1 to 2 of 2

Thread: Templates

  1. #1
    New Pligger blubber's Avatar
    Joined
    Jun 2007
    Posts
    3
    Thanks
    Received:0
    Given: 0

    Templates

    hi again,

    i have another problem which is driving me crazy,

    does anyone know how i can switch to a different template on code level? do i just have modify and execute some .php file ? or is there any other way to change templates without having to go to the admin section and do it by hand?

    i would bethankful for any help

  2. #2
    Pligg Donor dystopia's Avatar
    Joined
    May 2007
    Posts
    14
    Thanks
    Received:0
    Given: 0
    I've never tried this, but I would experiment with this line in config.php:
    define('The_Template', $thetemp);

    If that doesn't work, you could look at the section right above it. It looks like the theme ($thetemp) is set in /libs/settings_from_db.php, but could be hardcoded in config.php. Good luck.

    // template check
    $file = dirname(__FILE__) . '/templates/' . $thetemp . "/pligg.tpl";
    if (!file_exists($file)) { $errors[]='You may have typed the template name wrong or it does not exist. Click <a href = "admin_config.php?page=Template">here</a> to fix it.'; }
    if (isset($errors)) {
    foreach ($errors as $error) {
    $output.="<p><b>Error:</b> $error</p>\n";
    }
    $thetemp = "yget";
    if (strpos($_SERVER['SCRIPT_NAME'], "admin_config.php") == 0){
    echo $output;
    }
    }

Similar Threads

  1. Templates for 1.1.1
    By macpremium in forum Questions & Comments
    Replies: 0
    Last Post: 10-01-2010, 10:54 AM
  2. What templates are these?
    By infobombs in forum Questions & Comments
    Replies: 3
    Last Post: 02-19-2009, 11:15 AM
  3. Why do all my templates show as 2 column templates
    By mogydy in forum Questions & Comments
    Replies: 5
    Last Post: 12-28-2007, 08:41 AM
  4. Pligg Templates for Sale / Custom Templates Available
    By carpathios in forum Templates for Sale
    Replies: 3
    Last Post: 11-15-2007, 07:47 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Pligg Modules and Pligg Templates from Pligg Pro Web Hosting Services by Midphase Dreamhost Web Hosting Donate to Pligg