The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Category toggle refresh issue

View previous topic View next topic Go down

Solved Category toggle refresh issue

Post by breatheh2o on April 9th 2013, 1:42 pm

Hoping someone can help, I followed this tutorial

http://help.forumotion.com/t102749-category-toggle

It works on my forum the only problem is when i refresh my page or navigate back to my home page any category's i have collapsed will reopen and wont stay collapsed like the ones on forumotion my forum is phpbb3 http://forzalegends.playogame.com any help on this would be appreciated as i have searched this forum found many topics on this subject i did found one where Rideem3 had re-done the coding for punbb forums but nothing for phpbb3.


breatheh2o
New Member

Posts : 10
Reputation : 1
Language : ENGLISH

Back to top Go down

Solved Re: Category toggle refresh issue

Post by breatheh2o on April 11th 2013, 1:26 am

bump

breatheh2o
New Member

Posts : 10
Reputation : 1
Language : ENGLISH

Back to top Go down

Solved Re: Category toggle refresh issue

Post by breatheh2o on April 13th 2013, 3:16 am

bump

breatheh2o
New Member

Posts : 10
Reputation : 1
Language : ENGLISH

Back to top Go down

Solved Re: Category toggle refresh issue

Post by E-Mark on April 13th 2013, 8:35 pm

Gvie this a try: (Replace the JS you put with this one)
Code:
var CopyrightNotice='Category toggle code for ESF. Copyright 2011 by Dion Designs. All Rights Reserved.';function toggleLTcategory(cid,iflag){var cat=document.getElementById(cid);var button=document.getElementById('b'+cid);if(cat.style.display=='none'){cat.style.display='block';button.className='contract';my_setcookie('_'+cid,'',true)}else{cat.style.display='none';button.className='expand';my_setcookie('_'+cid,'1',true)}}$(function(){x=$('ul.topiclist li.header').get();for(i=0;i<x.length;i++){x[i].style.position='relative';var cid='c'+String(i+1);x[i].parentNode.nextSibling.setAttribute('id',cid);x[i].parentNode.nextSibling.style.display='block';var y='<div id="b'+cid+'" class="contract" onclick="toggleLTcategory(\''+cid+'\');"></div>';x[i].innerHTML=x[i].innerHTML+y}cookies=document.cookie.split('; ');for(i in cookies){if(cookies[i].charAt(0)=='_'){cookie=cookies[i].split('=');if(cookie[1]=='1'){cid=cookie[0].substring(1);if(document.getElementById(cid)){toggleLTcategory(cid,'x')}}}}});

E-Mark
Active Poster

Male Posts : 1389
Reputation : 164
Language : English, Tagalog
Location : Republic of the Philippines

http://coding-spot.darkbb.com/

Back to top Go down

Solved Re: Category toggle refresh issue

Post by breatheh2o on April 13th 2013, 11:13 pm

awesome bro does what it say's on the tin salut Thank you bud

breatheh2o
New Member

Posts : 10
Reputation : 1
Language : ENGLISH

Back to top Go down

Solved Re: Category toggle refresh issue

Post by E-Mark on April 13th 2013, 11:14 pm

Welcome Smile.

E-Mark
Active Poster

Male Posts : 1389
Reputation : 164
Language : English, Tagalog
Location : Republic of the Philippines

http://coding-spot.darkbb.com/

Back to top Go down

Solved Re: Category toggle refresh issue

Post by SLGray on April 14th 2013, 1:20 am

Topic Solved & Locked


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 36735
Reputation : 2446
Language : English
Location : United States

http://ztwds.forumotion.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum