微信小程序

  • 请创建两个页面,通过按钮来相互切换,并附上代码及运行结果截图;

|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| 二、实验步骤与结果(给出对应的代码或运行结果截图) |---|---------------------------------------------------------------------------------------------------|---|---------------------------------------------------------------------------------------------------| | | | | | | | | | | |-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | 三、问题总结与体会 | | demo-1.wxml <!--pages/demo-1/demo-1.wxml--> <view class="box1">页面二</view> <view class="box2"><navigator url="../index/index">返回上一页 </navigator></view> demo-1.wxss /* pages/demo-1/demo-1.wxss */ .box1{ margin-top: 100rpx; text-align: center; } .box2{ background-color: #eee; height: 100rpx; width: 350rpx; text-align: center; line-height: 100rpx; font-size: 42rpx; font-weight: bolder; margin: 0 auto; position: relative; top: 600rpx; } index.wxml <!--index.wxml--> <view class="box1">页面一</view> <view class="box2"><navigator url="../demo-1/demo-1"> 下一页</navigator></view> index.wxss .box1{ margin-top: 100rpx; text-align: center; } .box2{ background-color: #eee; height: 100rpx; width: 350rpx; text-align: center; line-height: 100rpx; font-size: 42rpx; font-weight: bolder; margin: 0 auto; position: relative; top: 600rpx; } app.json { "pages": [ "pages/index/index", "pages/logs/logs", "pages/demo-1/demo-1" ], "window": { "navigationBarTextStyle": "black", "navigationBarTitleText": "Weixin", "navigationBarBackgroundColor": "#ffffff" }, "style": "v2", "componentFramework": "glass-easel", "lazyCodeLoading": "requiredComponents" } | |

相关推荐
好赞科技8 小时前
2026年最佳健身小程序推荐榜单,帮你解锁智能运动新体验
大数据·微信小程序
azhou的代码园8 小时前
基于SpringBoot+Vue的家教小程序
vue.js·spring boot·小程序·毕业设计·家教小程序
Hello--_--World8 小时前
小程序面试题
小程序
AI行业应用研究9 小时前
会务小程序开发成本高?不如看看这个低代码解决方案
大数据·低代码·小程序
好赞科技10 小时前
026年五大汽车保养预约小程序推荐榜单,让养车更轻松省心
大数据·微信小程序
azhou的代码园12 小时前
基于微信小程序的图片识别科普系统的设计与实现
vue.js·spring boot·微信小程序·小程序·毕业设计·科普·图片识别
木风未来12 小时前
四川 UI 与数字视觉设计机构排名:政企定制服务实力榜单
ui·小程序·可视化大屏
焦糖玛奇朵婷14 小时前
终于搞清楚了,扭蛋机小程序这么厉害❗
java·服务器·前端·程序人生·小程序
求学中--15 小时前
状态管理一文通:@State、@Prop、@Link、@Provide/Consume全解析
人工智能·小程序·uni-app·wpf·harmonyos
求学中--15 小时前
ArkUI组件库完全指南:从基础组件到自定义装饰器
低代码·华为·小程序·uni-app·harmonyos