Page 1 of 1

ExpandCollapse tag with 1.4.1 not working

Posted: Mon Aug 18, 2008 11:47 am
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Aug 25, 2008 2:31 am
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Aug 25, 2008 7:40 am
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 3:22 am
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!

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 10:44 am
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 3:46 pm
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 6:19 pm
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 8:47 pm
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Mon Sep 08, 2008 9:31 pm
by alby
mel wrote: src="http://localhost/cmsmstesting/lib/helparea.js"
.........
href="/labneuro/fr/labo/publications/#abstract"
Path of js is correct?

Alby

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Tue Sep 09, 2008 12:50 am
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

Re: ExpandCollapse tag with 1.4.1 not working

Posted: Wed Sep 10, 2008 7:40 am
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