• 60
 added a discussion  to  , cmt

Dear developers,

As I was experimenting with the code, I tried to replicate another function that is in BxDolCmts.js whereby the codes for the replicated function can be seen below.

BxDolCmts.prototype.cmt2 = function(e, iCmtId) {

    var $this = this;

    var oParams = $this._getDefaultActions();


    oParams['action'] = 'Hide';

    oParams['Cmt'] = iCmtId; (



        function(oData) {

            var fContinue = function() {

                if(oData && != undefined) {


                    $('' +'hide', $this._sAnimationEffect, $this._iAnimationSpeed, function() {

                        var oCounter = $(this).parent('ul.cmts').siblings('.cmt-cont').find('.cmt-actions a.cmt-comment-replies span');


                            oCounter.html(oCounter.html() - 1);






            $this._loadingInContent(e, false);

            if(oData && oData.msg != undefined)


                bx_alert(oData.msg, fContinue);  








I found out that, in the bold portion of the code, even when I have returned an error message the page still refreshes automatically instead of just showing the bx_alert and don't refresh at all. I would like to achieve the behavior of just displaying the the alert and do not want any refreshing of the page when there is an alert been displayed due to an error. May I know how may I achieve that, as it is currently refreshing every time I clicked the button that has been linked to this functions. Even when I have commented the logic applied in the onclick function and cleared all cache, as long as the button is pressed it is refreshing the page.

  • 127

UNA - Social Media Software Framework