关于css:如何在离子中心对齐的标题上添加图标? | 珊瑚贝

How I can add an icon on header with center align in ionic?


如何在我的 ionic 应用程序中在标题上添加一个”ion-ios-arrow-up”图标,中心对齐,就像我下面的概念一样?

这是我的 HTML 模板:

1
2
3
4
5
6
<ion-view cache-view=“false” view-title=“Historical HPP”>
    <ion-nav-bar class=“nav-title-slide-ios7 bar-assertive” ng-click=“click()”></ion-nav-bar>
 <ion-content class=“has-header”>
Hello
  </ion-content>
</ion-view>

之前谢谢

  • 你可以编辑这个:play.ionic.io/app/ac4063d18c09 并显示当前输出吗?
  • @ManojKumar:这个代码笔类似于我上面的 HTML 模板。


只需将标题绑定到 $scope 变量

1
<ion-view title=“{{title}}”>

在你的控制器中

1
$scope.title =“Historical HPP <i class=’ion-arrow-up-c’>”;

在这里编写代码。这是你要找的吗?


来源:https://www.codenong.com/31228246/

微信公众号
手机浏览(小程序)

Warning: get_headers(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57

Warning: get_headers(): Failed to enable crypto in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57

Warning: get_headers(https://static.shanhubei.com/qrcode/qrcode_viewid_9032.jpg): failed to open stream: operation failed in /mydata/web/wwwshanhubei/web/wp-content/themes/shanhuke/single.php on line 57
0
分享到:
没有账号? 忘记密码?