Closing a module with a nice little x in the top corner - Joomla! Forum - community, help and support
hello everyone, title says all. i'm looking way close module/module position little x button in top corner, , make disappear (kinda how can close donate signs come on wikipedia @ end of year). appreciated.
my initial thought...
[1] clone view file module , rename alternative layout. edit new file (the alternative layout).
[2] wrap module's display in <div> id.
[3] add code inserts javascript page. javascript, when invoked, adds display:none item of id added. (javascript code added page through function jfactory::getdocument()->addscriptdeclaration($js_code);)
[4] add 'x' display (positioned want it) , wrap anchor tag calls javascript when clicked.
[5] modules should display 'x', select alternative layout. if other module types require 'x', need repeat these steps.
so in summary, module displays does, displays 'x' added, , when user clicks on 'x', <div> contains module's html reset no longer display.
[1] clone view file module , rename alternative layout. edit new file (the alternative layout).
[2] wrap module's display in <div> id.
[3] add code inserts javascript page. javascript, when invoked, adds display:none item of id added. (javascript code added page through function jfactory::getdocument()->addscriptdeclaration($js_code);)
[4] add 'x' display (positioned want it) , wrap anchor tag calls javascript when clicked.
[5] modules should display 'x', select alternative layout. if other module types require 'x', need repeat these steps.
so in summary, module displays does, displays 'x' added, , when user clicks on 'x', <div> contains module's html reset no longer display.
Comments
Post a Comment