ExpandCollapse tag with 1.4.1 not working

This is a FORK of the CMS Made Simple project and is not oficially supported in any way by the CMS Made Simple development team.
Locked
xmas3
Forum Members
Forum Members
Posts: 41
Joined: Sat Jul 28, 2007 9:22 am

ExpandCollapse tag with 1.4.1 not working

Post by xmas3 »

Hi all,
I upgraded from 131 to 141 and the ExpandCollapse tag is not working! The whole text is already expanded and it is not possible to collapse it! Any suggestions?

Thanks, Miro
mel
Forum Members
Forum Members
Posts: 147
Joined: Mon Dec 11, 2006 11:53 pm

Re: ExpandCollapse tag with 1.4.1 not working

Post by mel »

Hi,
I get same problem. Effectively, I try in both version 1.3.1 and 1.4.1 and only first one work with exact same HTML code enter in TinyMCE editor. In preview window, it collapse as it should.
I compare files, and they are quite identical (except help part) I even copy the 1.3.1 one in my 1.4.1 directory and did'nt change.
But with examination of my source, I think it's something related to path to JS. 
In 1.3.1

Code: Select all

<__script__ type="text/javascript" language="javascript" src="http://localhost/labneuro-mle/lib/helparea.js"></__script>
<a href="/labneuro-mle/fr/labo/publications/#abstract" onclick="expandcontent('abstract')" style="cursor:hand; cursor:pointer">[Résumé↓]</a><br />
          <div id="abstract" class="expand">

In 1.4.1

Code: Select all

<a href="/labneuro/fr/labo/publications/#abstract" onclick="expandcontent('abstract')" style="cursor:hand; cursor:pointer">[Résumé↓]</a><br />
	<div id="abstract" class="expand">
Note: It's normal if I have differents url, they are installed in different directory on WAMP.

Someone have a solution?
Thanks
Mel
Last edited by mel on Mon Sep 08, 2008 3:19 am, edited 1 time in total.
Version 1.6-MLE
alby

Re: ExpandCollapse tag with 1.4.1 not working

Post by alby »

mel wrote: Note: It's normal if I have differents url, they are installed in different directory on WAMP.
Someone can test on original CMSMS 1.4.1?

If url paths in javascript are correct, can be a modification in url from 1.3X to 1.4X
There is one changed only relative to homepage only:
lib/classes/class.content.inc.php (around #1315)
        if($this->mDefaultContent) {
        $url =  $config['root_url']. '/';
#        return $url;
        }
Alby
mel
Forum Members
Forum Members
Posts: 147
Joined: Mon Dec 11, 2006 11:53 pm

Re: ExpandCollapse tag with 1.4.1 not working

Post by mel »

Hi,
So it seems no one tested, so I did it on my own.
I install basic package 1.4.1 with default tables. I copy my HMTL code from containing my non-working collapse. And as you predict it, I can confirm it works in normal CMS.
What I should do now to correct it in MLE?
Thanks!
Version 1.6-MLE
alby

Re: ExpandCollapse tag with 1.4.1 not working

Post by alby »

mel wrote: So it seems no one tested, so I did it on my own.
I install basic package 1.4.1 with default tables. I copy my HMTL code from containing my non-working collapse. And as you predict it, I can confirm it works in normal CMS.
What I should do now to correct it in MLE?
I don't find differences from 1.3.1 and 1.4.1 and in my test (LAMP and FF) I can not reproduce the problem.
If you use FF, you can install firebug addon and check for error

Alby
mel
Forum Members
Forum Members
Posts: 147
Joined: Mon Dec 11, 2006 11:53 pm

Re: ExpandCollapse tag with 1.4.1 not working

Post by mel »

Hi,
I try firebug, but it's too complicated for me and I don't know what I'm looking for.
So for now, I just add the link ) directly in HTML, and it's working.
If someone find the cause or a solution, it's welcome.
Mel
Version 1.6-MLE
alby

Re: ExpandCollapse tag with 1.4.1 not working

Post by alby »

mel wrote: I try firebug, but it's too complicated for me and I don't know what I'm looking for.
So for now, I just add the link ) directly in HTML, and it's working.
If someone find the cause or a solution, it's welcome.
Active firebug and look in listcontent if bug icon is a red cross (js error)
Have you "" in original cmsms?

Alby
mel
Forum Members
Forum Members
Posts: 147
Joined: Mon Dec 11, 2006 11:53 pm

Re: ExpandCollapse tag with 1.4.1 not working

Post by mel »

No. In CMS 1.4.1, I have a this


Without adding script by hand, it was written :

Code: Select all

expandcontent is not defined
onclick(click clientX=713, clientY=196)2oQZdf%2...iqQ%3D%3D (ligne 2)
[Break on this error] expandcontent("abstract");

 function onclick(event) {
 expandcontent("abstract");
 }
But, it's "defined" (as seen is code source)

Code: Select all

<a style="cursor: pointer;" onclick="expandcontent('abstract')" href="/labneuro/fr/labo/publications/#abstract">[Résumé↓]</a>
<br/>
<div id="abstract" class="expand">

Mel
Version 1.6-MLE
alby

Re: ExpandCollapse tag with 1.4.1 not working

Post by alby »

mel wrote: src="http://localhost/cmsmstesting/lib/helparea.js"
.........
href="/labneuro/fr/labo/publications/#abstract"
Path of js is correct?

Alby
mel
Forum Members
Forum Members
Posts: 147
Joined: Mon Dec 11, 2006 11:53 pm

Re: ExpandCollapse tag with 1.4.1 not working

Post by mel »

Yes they are.
They are installed with differents names on my WAMP installation, so I can know which one is which one.
mel wrote:

Code: Select all

expandcontent is not defined
onclick(click clientX=713, clientY=196)2oQZdf%2...iqQ%3D%3D (ligne 2)
[Break on this error] expandcontent("abstract");

 function onclick(event) {
 expandcontent("abstract");
 }
But, it's "defined" (as seen is code source)

Code: Select all

<a style="cursor: pointer;" onclick="expandcontent('abstract')" href="/labneuro/fr/labo/publications/#abstract">[Résumé↓]</a>
<br/>
<div id="abstract" class="expand">
This is taken from CMS 1.4.1MLE. I forgot to mention.

Mel
Version 1.6-MLE
xmas3
Forum Members
Forum Members
Posts: 41
Joined: Sat Jul 28, 2007 9:22 am

Re: ExpandCollapse tag with 1.4.1 not working

Post by xmas3 »

Hi, I've just added the

into the head of the webpage and it works now!

I've tryied to find something more about the script but didn't found anything.

Neverthless, thanks a lot,
bye Miro
Locked

Return to “[locked] CMSMS MLE fork”