mirror of
https://github.com/e107inc/e107.git
synced 2025-08-05 14:17:49 +02:00
JS API fix - expand by element id was broken
This commit is contained in:
@@ -8,8 +8,8 @@
|
|||||||
* e107 Javascript API
|
* e107 Javascript API
|
||||||
*
|
*
|
||||||
* $Source: /cvs_backup/e107_0.8/e107_files/jslib/e107.js.php,v $
|
* $Source: /cvs_backup/e107_0.8/e107_files/jslib/e107.js.php,v $
|
||||||
* $Revision: 1.4 $
|
* $Revision: 1.5 $
|
||||||
* $Date: 2008-11-17 17:43:57 $
|
* $Date: 2008-11-19 12:19:51 $
|
||||||
* $Author: secretr $
|
* $Author: secretr $
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
@@ -780,7 +780,11 @@ Object.extend(e107Helper, {
|
|||||||
* This method will be rewritten after the core is cleaned up. After this point
|
* This method will be rewritten after the core is cleaned up. After this point
|
||||||
* the target element will be auto-hidden (no need of class="e-hideme")
|
* the target element will be auto-hidden (no need of class="e-hideme")
|
||||||
*/
|
*/
|
||||||
if(Object.isElement(el) && ($(el).readAttribute('href')) || $(el).nodeName.toLowerCase() == 'a' || $(el).readAttribute('type').toLowerCase() == 'input') {
|
if(false === Object.isString(el) || (
|
||||||
|
($(el) && $(el).nodeName.toLowerCase() == 'a' && $(el).readAttribute('href'))
|
||||||
|
||
|
||||||
|
($(el) && $(el).readAttribute('type') && $(el).readAttribute('type').toLowerCase() == 'input')
|
||||||
|
)) {
|
||||||
eltoggle = (function(el) {
|
eltoggle = (function(el) {
|
||||||
return Try.these(
|
return Try.these(
|
||||||
function() { var ret= $(el.readAttribute('href').match(/#(\w.+)$/)[1]); if(ret) { return ret; } throw 'Error';}, //This will be the only valid case in the near future
|
function() { var ret= $(el.readAttribute('href').match(/#(\w.+)$/)[1]); if(ret) { return ret; } throw 'Error';}, //This will be the only valid case in the near future
|
||||||
|
Reference in New Issue
Block a user