标签:var javascrip 源码 innerhtml log cti turn form htm
可以在app.js进行配置
.config(function($stateProvider, $urlRouterProvider,$ionicConfigProvider) { $ionicConfigProvider.platform.ios.tabs.style(‘standard‘); $ionicConfigProvider.platform.ios.tabs.position(‘bottom‘); $ionicConfigProvider.platform.android.tabs.style(‘standard‘); $ionicConfigProvider.platform.android.tabs.position(‘standard‘); $ionicConfigProvider.platform.ios.navBar.alignTitle(‘center‘); $ionicConfigProvider.platform.android.navBar.alignTitle(‘center‘); $ionicConfigProvider.platform.ios.backButton.previousTitleText(‘‘).icon(‘ion-android-arrow-back‘); $ionicConfigProvider.platform.android.backButton.previousTitleText(‘‘).icon(‘ion-ios-arrow-back‘);
如果行不通,那么就去改源码 如下所示
打开lib下的ionic.bundle.js
注释掉下面这句代码:
// buttonEle.appendChild(buttonTextEle);
function hasIconClass(ele) { return /ion-|icon/.test(ele.className); } var defaultIcon = $ionicConfig.backButton.icon(); if (!hasIcon && defaultIcon && defaultIcon !== ‘none‘) { buttonEle.innerHTML = ‘<i class="icon ‘ + defaultIcon + ‘"></i> ‘ + buttonEle.innerHTML; buttonEle.className += ‘ button-clear‘; } if (!hasInnerText) { var buttonTextEle = $document[0].createElement(‘span‘); buttonTextEle.className = ‘back-text‘; if (!hasButtonText && $ionicConfig.backButton.text()) { buttonTextEle.innerHTML += ‘<span class="default-title">‘ + $ionicConfig.backButton.text() + ‘</span>‘; } if (!hasPreviousTitle && $ionicConfig.backButton.previousTitleText()) { buttonTextEle.innerHTML += ‘<span class="previous-title"></span>‘; } // buttonEle.appendChild(buttonTextEle); }
标签:var javascrip 源码 innerhtml log cti turn form htm
原文地址:http://www.cnblogs.com/luleixia/p/6919408.html