Plugin Directory

Changeset 1868043


Ignore:
Timestamp:
05/03/2018 10:46:25 AM (8 years ago)
Author:
cometchat
Message:

fixed issue with CometChat login auto login issue for embedded layout

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cometchat/trunk/includes/cometchat_cloud.php

    r1859636 r1868043  
    11<?php
     2
     3
     4/**
     5* createCometChatBaseData
     6* Return object
     7* @param (type) no param
     8* @return (object)
     9*/
     10function createCometChatBaseData(){
     11    global $cc_clientid;
     12    global $cc_base;
     13
     14    if(!empty($cc_base)) {
     15        wp_enqueue_script( 'cc_base', plugin_dir_url( __DIR__ ).'js/scripttag.js');
     16        wp_add_inline_script( 'cc_base', 'var cc_base = '.$cc_base.';' );
     17    }
     18}
    219
    320/**
     
    1027    global $cc_clientid;
    1128    global $cc_base;
    12 
    13     if(!empty($cc_base)) {
    14         wp_enqueue_script( 'cc_base', plugin_dir_url( __DIR__ ).'js/scripttag.js' );
    15         wp_add_inline_script( 'cc_base', 'var cc_base = '.$cc_base.';' );
    16     }
    1729
    1830    wp_enqueue_style("cc_corecss", "//fast.cometondemand.net/".$cc_clientid."x_x".substr(md5($cc_clientid),0,5).".css");
     
    212224}
    213225
     226add_action('wp_head', 'createCometChatBaseData',1);
    214227add_action('wp_head', 'getCometChatCloudDockedLayoutCode');
    215228add_action('init','cometchatUserDetails');
Note: See TracChangeset for help on using the changeset viewer.