Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • augustinovp Friend
    #149304

    i have ja seleni template installed and i need to disable mootools in order to work parainvite component from simbunch… i followed the instructions from their forum, i inserted script in component.php and inserted a code in “layouts/blocks/head.php” disabled usertools but still no effect…
    i tested with other template “rhuk_milkyway” and “beez” and it works…

    tested also with JA Purity and is not working… anyway, i need it to work with ja seleni template.

    the link: http://starbisnov.ro/en/profil/pukana-drugare
    Thanks

    Anonymous Moderator
    #335546

    Hi augustinovp

    The mootools.js file is the default of joomla. You could not remove it because i will have a lot of errors in your site.

    augustinovp Friend
    #335681

    yes i agree but i wonder if i could disable mootools only when viewing that page…
    i found on their forums the folowing code wich temporary disables mootools

    [PHP] <?php
    JHTML::_( ‘behavior.mootools’ );
    $simbunch = ($option == ‘com_parainvite’ || $option == ‘com_simgallery’ || $option == ‘com_simanswers’) ? true : false;
    $document =& JFactory::getDocument();
    if ($simbunch) {
    $parameter_script = ‘scripts’;
    $headerstuff = $document->getHeadData();
    reset($headerstuff[$parameter_script]);
    foreach ($headerstuff[$parameter_script] as $key=>$value){
    if (substr_count($key, ‘mootools’) > 0)
    unset($headerstuff[$parameter_script][$key]);
    }
    $document->setHeadData( $headerstuff );
    }
    ?>
    <jdoc:include type=”head” />
    [/PHP]

    and they say to insert in index.php above JHTML::_( ‘behavior.mootools’ ); code… but is not working

    i had before ja_teline1 template and i inserted that code and it worked without problems, only now with ja_seleni i can’t figure out where to insert that code…. tried in templatedir/layouts/blocks/head.php and/or component.php but still no effect

    Anonymous Moderator
    #335899

    Hi you

    I am not sure about this issue.

    Please kindly contact with the author of component for more detail. I am sorry for not being of much help in the case.

    mmckeen Friend
    #342475

    <em>@augustinovp 168752 wrote:</em><blockquote>yes i agree but i wonder if i could disable mootools only when viewing that page…
    i found on their forums the folowing code wich temporary disables mootools

    [PHP] <?php
    JHTML::_( ‘behavior.mootools’ );
    $simbunch = ($option == ‘com_parainvite’ || $option == ‘com_simgallery’ || $option == ‘com_simanswers’) ? true : false;
    $document =& JFactory::getDocument();
    if ($simbunch) {
    $parameter_script = ‘scripts’;
    $headerstuff = $document->getHeadData();
    reset($headerstuff[$parameter_script]);
    foreach ($headerstuff[$parameter_script] as $key=>$value){
    if (substr_count($key, ‘mootools’) > 0)
    unset($headerstuff[$parameter_script][$key]);
    }
    $document->setHeadData( $headerstuff );
    }
    ?>
    <jdoc:include type=”head” />
    [/PHP]

    and they say to insert in index.php above JHTML::_( ‘behavior.mootools’ ); code… but is not working

    I had before ja_teline1 template and i inserted that code and it worked without problems, only now with ja_seleni i can’t figure out where to insert that code…. tried in templatedir/layouts/blocks/head.php and/or component.php but still no effect</blockquote>

    Were you every able to get this resolved? I have the same problem (I have SimGallery/SimAnswers/SimParainvite) so I really need a solution also. I also added a comment on Mike’s forum but he hasn’t answered yet. I may go ahead and try posting a support ticket with him but wanted to check with you to see if you solved the issue first.

    Thanks!

    augustinovp Friend
    #342479

    try this solution:

    open the file:
    /templates/<your template>/layouts/blocks/head.php

    find this code:

    [PHP] <jdoc:include type=”head” />
    <?php JHTML::_(‘behavior.mootools’); ?>[/PHP]

    replace with:

    [PHP] <?php
    JHTML::_( ‘behavior.mootools’ );
    $option = JRequest::getVar(‘option’, ”);
    $simbunch = ($option == ‘com_parainvite’ || $option == ‘com_simgallery’ || $option == ‘com_simanswers’) ? true : false;
    $document =& JFactory::getDocument();
    if ($simbunch) {
    $parameter_script = ‘scripts’;
    $headerstuff = $document->getHeadData();
    reset($headerstuff[$parameter_script]);
    foreach ($headerstuff[$parameter_script] as $key=>$value){
    if (substr_count($key, ‘mootools’) > 0)
    unset($headerstuff[$parameter_script][$key]);
    }
    $document->setHeadData( $headerstuff );
    }
    ?>
    <jdoc:include type=”head” />[/PHP]

    see if it works

    mmckeen Friend
    #342523

    I think I have located part of the problem. Your change worked (it stopped the loading for mootools) however the T3 framework uses some css styling that conflicts with css styling in the template. The SimAnswers and SimGallery dropdowns don’t work correctly and I can see things like list bullets in the formating… not sure how to fix it however… looks like some or all of it is in the addons.css file in the template

    mmckeen Friend
    #342556

    Further investigation shows that it is a problem with the .column ul li class in the templates.css file. SimGallery and SimAnswers has a dropdown list and for some reason the .column ul li class from the template is being used. It messes up the dropdown causing it not to work. I’m not sure how to rename the class…

    toymaker Friend
    #342557

    You can try making the path to your module styles more specific so it only affects your module and not the menu.

    For example:
    In your module configuration, add a module class suffix (” mymod” for example – remember to use a blank space at the begining) and then modify your style path to include that class.

    Before:

    .column ul li { bla bla bla }

    After:

    .mymod .column ul li { bla bla bla }

    This new style definition will only affect the elements that contain both classes.

    Hope it helps.

    Peace,
    Gabriel

    mmckeen Friend
    #342558

    thank you very much for the quick reply! The problem is actually with two components that are using the default template.css styling. Not sure how to go about styling the component to ignore the template.css .column class

    toymaker Friend
    #342559

    When configuring a module, you usually have the option to add a module class suffix. (see attached capture). Here you can specify a new class that will be APPENDED to the module container DIV.

    so.. here you have a proof of concept code…


    <style>
    .column ul li { color:#f00; }
    .mymodule.column ul li { color:#00f; }
    </style>

    <div class="column">
    <ul>
    <li>item 1</li>
    <li>item 2</li>
    <li>item 3</li>
    </ul>
    </div>
    <div class="column mymodule">
    <ul>
    <li>item 1</li>
    <li>item 2</li>
    <li>item 3</li>
    </ul>
    </div>

    As you can see, both share the same .column ul li structure, but by appending a new class suffix to the second module, you can apply inheritance of a new rule only to that second module.

    Peace,
    Gabriel


    1. module-class-param
    mmckeen Friend
    #342560

    Thanks again … I guess I’m not being clear about the issue. The problem isn’t with any of my modules I have on the site or the site in general. I have two additional components. One is a photogallery and the other is a question and answer component. All the modules work fine. No issue with them. It is the components that do not work correctly. I only need to fix the problem for the two components, not for any of the modules… thank you again very much for your help… 🙂

    toymaker Friend
    #342562

    Dont really follow you on the definitions. For me, in most cases, a component works on the backend and relates itself to the data in the database and several administrative tasks. On the other hand, a module represents a “view” of the component’s data inside the site.

    Please, check/mark the ADMIN/MOD HELP option and provide url link and login information in the post so I can provide further assistance to your specific scenario.

    mmckeen Friend
    #342564

    I’ll open a ticket and see if they can help … and I agree … a module is something like the login module or the poll module. A component is something like a forum, a photogallery, JomSocial, … something like that. The two components giving me the trouble are SimGallery and SimAnswers. I have contacted Mike at Simbunch for help also … thanks again!

Viewing 14 posts - 1 through 14 (of 14 total)

This topic contains 14 replies, has 4 voices, and was last updated by  mmckeen 14 years, 6 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum