collapsing blocks problem in theme CZ-1 CpgNuke

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   collapsing blocks problem in theme CZ-1 CpgNuke
wargoth
CZ Newbie
wargoth has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Feb 14, 2005
0.00 posts per day
Posts: 3
Points: 77
   
I have installed the CZ-1 theme on my CPGNuke site, and have noticed that the collapsing blocks don't work in firefox, or any other browser other than IE for that matter.... Anyone else run into this and have a fix? Have no issues with other themes in firefox, just this one...



Back to top Reply with quote
#2   re: collapsing blocks problem in theme CZ-1 CpgNuke
Taut
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif california.gif
Occupation: Entrepreneur
Gender: Female
Fav. Sports Team: SF Giants
Status: Offline
Joined: May 27, 2003
0.70 posts per day
Posts: 5530
Points: 481,695
   
Try this:

- Open your theme.php (for ex. "themes\CZ1\theme.php")
- in file goto "function themeheader() {" and add the following to your
<body> tag:

  onLoad=\"doblocks('themes/CZ1/images/');\"


- function themesidebox($title, $content) needs some more advanced editing
add just below "function themesidebox($title, $content) {"
$bid = str_replace(" ", "", $title);

add BEFORE or AFTER "$title":


    ."<img id=\"pic$bid\" src=\"themes/CZ1/images/minus.gif\" onclick=\"xyzswitch('$bid');\">\n"
        ."<s cript language=\"JavaS cript\" type=\"text/javas cript\">\n<!--\n"
        ."var blockopen=GetCookie('block".$bid."'); \n"
        ."if (blockopen != null) {\n"
        ."  blockarrayint += 1;\n"
        ."  blockarray[blockarrayint] = \"".$bid."\";\n"
        ."}\n"
        ."//-->\n</s cript>\n"



add BEFORE $content:

    ."<div id=\"pe$bid\" style=\"display:show;\">\n"

add AFTER $content:

    ."</div>\n"
    ."<div id=\"ph$bid\" style=\"display:none;\"> </div>\n";


That came from the cpg files. You can also compare the theme.php and or blocks.html that came with the pre-installed theme for cpg


Back to top Reply with quote
#3   re: collapsing blocks problem in theme CZ-1 CpgNuke
wargoth
CZ Newbie
wargoth has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Feb 14, 2005
0.00 posts per day
Posts: 3
Points: 77
   
well, all of that is in there... split between the theme. php files and the blocks. php...

the only part which varies... is the final \n's in the last 2 snipits of code.. iif they are present, they trash the whole theme.

I am not a very code oriented person, but I do get that for some reason the lack of the ending \n 's breaks the javascript, which IE ignores, but more HTML complient browsers error out on...

The content of the blocks disappears, but they do not collapse.

and as I said, it is something specific to this theme alone... I think it has something to do with the way function theme sidebox is a call to include block.php....

please help....



Back to top Reply with quote
#4   re: collapsing blocks problem in theme CZ-1 CpgNuke
Taut
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif california.gif
Occupation: Entrepreneur
Gender: Female
Fav. Sports Team: SF Giants
Status: Offline
Joined: May 27, 2003
0.70 posts per day
Posts: 5530
Points: 481,695
   
I read from CPG that there was a bug in the earlier ported themes. I tried to port one of my existing theme since I don't use the collapse blocks feature of CPG and the code they gave above did not work fully.

You mentioned other themes you have, are those ported themes or themes made specifically for CPG? Can you attach one of the theme.php files for me to see please.



Back to top Reply with quote
#5   re: collapsing blocks problem in theme CZ-1 CpgNuke
wargoth
CZ Newbie
wargoth has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: Feb 14, 2005
0.00 posts per day
Posts: 3
Points: 77
   
This is the Theme.php from ConCept, just on of the many that work with no problems... it is CPG 8.2c I am using. This them doesn't seem to call to blocks. php though... Sadly I rather drive with themes.



Attached Files
theme.zip (3.94 KB, Downloaded: 5244 Time(s))


Back to top Reply with quote
#6   Re: re: collapsing blocks problem in theme CZ-1 CpgNuke
Taut
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif california.gif
Occupation: Entrepreneur
Gender: Female
Fav. Sports Team: SF Giants
Status: Offline
Joined: May 27, 2003
0.70 posts per day
Posts: 5530
Points: 481,695
   
Ok got it. Not all themes call the blocks file. Different theme makers use different coding. Give me till this weekend to sort something out as I am swamped with extra work.



Back to top Reply with quote
#7   re: collapsing blocks problem in theme CZ-1 CpgNuke
Taut
PayPal Donation
CZ Revered Member
 Codezwiz Site Donator
usa.gif california.gif
Occupation: Entrepreneur
Gender: Female
Fav. Sports Team: SF Giants
Status: Offline
Joined: May 27, 2003
0.70 posts per day
Posts: 5530
Points: 481,695
   
sorry for the delay. Please re-download the theme. There were a few changes that were made.



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

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
You cannot attach files in this forum
You cannot download files in this forum