Our Sponsors



Your Ads Here
Advertise with Western Studios.
www.westernstudios.net

Theme Shop
Get the best in phpnuke themes, stock photos, icons from Western Studios themes shop.
shop.westernstudios.net

PHP Nuke Subscription
The #1 php nuke subscription module.
www.westernstudios.net

PHP Nuke Downloads
The latest and best in php nuke downloads.
www.westernstudios.net

PHP Nuke Services
Need work done on your site? View our services for the best in phpnuke services.
www.westernstudios.net




Western Studios :: View topic - Theme preview module - code not same as listed?
 Forum FAQForum FAQ   SearchSearch   UsergroupsUsergroups     ProfileProfile   Log inLog in 


Theme preview module - code not same as listed?



 
Post new topic   Reply to topicprinter friendly version    Western Studios Forum Index -> Web Design


~PHP Nuke User~


Guest wrote:

I downloaded your theme preview module, and uploaded stuff where it was supposed to. Then I went into the mainfile.php as requested and looked for the section it said to replace:

Code:
function get_theme() {
    global $user, $cookie, $Default_Theme;
    static $ThemeSelSave;
    if (isset($ThemeSelSave)) return ($ThemeSelSave);
    if(is_user($user)) {
        $user2 = base64_decode($user);
        $t_cookie = explode(":", $user2);
        if($t_cookie[9]=="") $t_cookie[9]=$Default_Theme;
        if(isset($theme)) $t_cookie[9]=$theme;
        if(!$tfile=@opendir("themes/$t_cookie[9]")) {
            $ThemeSel = $Default_Theme;
        } else {
            $ThemeSel = $t_cookie[9];
        }
    } else {
        $ThemeSel = $Default_Theme;
    }
    $ThemeSelSave = $ThemeSel;
    return($ThemeSel);
}


But it wasn't there! Instead, what I found was this:

Code:
function get_theme() {

    global $user, $cookie, $Default_Theme;

    if(is_user($user)) {

   $user = addslashes($user);

   $user2 = base64_decode($user);

   $t_cookie = explode(":", $user2);

   if($t_cookie[9]=="") $t_cookie[9]=$Default_Theme;

   if(isset($theme)) $t_cookie[9]=$theme;

   if(!$tfile=@opendir("themes/$t_cookie[9]")) {

       $ThemeSel = $Default_Theme;

   } else {

       $ThemeSel = $t_cookie[9];

   }

    } else {

   $ThemeSel = $Default_Theme;

    }

    return($ThemeSel);


Is this a newer version? Can I still use this module? I'm running PHPNuke 7.5, installed through a fantastico installation by my web hosting company (hence my cluelessness).

Thanks in advance!

Posted: Sat Mar 26, 2005 2:06 pm

Western Studios

Site Admin
Site Admin
~PHP Nuke User~

Platinum Subscriber

Posts: 3309
Staff
Next Group: 1691 posts
admin(Mark) wrote:

Hi, it is a previous version but i have gotten it to work with 7.5. Make a backup of your mainfile.php then replace that function_get_theme with the one from the block. It should work, if not, just replace the original mainfile.php and i'll take a look at it for you.

Posted: Sat Mar 26, 2005 2:20 pm

Western Studios

Dedicated Users
Dedicated Users
~PHP Nuke User~


Posts: 167
Next Group: 333 posts
Jabba wrote:

Try this preview theme block.
http://lorkan.com/modules.php?name=Downloads&d_op=viewdownloaddetails&lid=56&ttitle=Theme_Preview_v.1.0
Works great on my site and is simple to install.

Posted: Sat Mar 26, 2005 2:23 pm

Western Studios

Site Admin
Site Admin
~PHP Nuke User~

Platinum Subscriber

Posts: 3309
Staff
Next Group: 1691 posts
admin(Mark) wrote:

It's the same as the one on this site. Created by Viperal for everyone.

Posted: Thu Mar 31, 2005 8:37 pm

Post new topic   Reply to topic    Western Studios Forum Index -> Web Design All times are GMT - 5 Hours
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


Related topics
 Topics   Replies   Author   Views   Last Post 
No new posts PHP paste bin added 0 admin 768 Wed Mar 23, 2005 6:47 pm
admin View latest post
No new posts PHP Nuke klips 0 admin 608 Fri Mar 18, 2005 6:52 pm
admin View latest post
No new posts Paypal success.php 1 Jabba 783 Fri Mar 04, 2005 7:00 pm
admin View latest post
No new posts Testing PHP tags 2 admin 765 Thu Mar 03, 2005 6:06 pm
admin View latest post
No new posts PHP Nuke Icons 0 admin 813 Mon Aug 23, 2004 4:05 pm
admin View latest post
 
Forums ©