ios - Firebase Auth,从不同类获取文本字段值

标签 ios swift firebase firebase-authentication

我在我的应用中使用 Firebase 电子邮件身份验证,我有 2 个不同的 View Controller 用于注册过程,第一个 View Controller 要求提供 Firebase 的电子邮件,第二个 View Controller 要求密码。如何针对 firebase 代码进行设置?

if let phoneEmail = phoneEmailTextField.text, let createdpassword = createdPasswordTextField {

            Auth.auth().createUser(withEmail: phoneEmail, password: createdpassword, completion: { (user, error) in

我在第一个 View Controller (类1)中有文本字段“phoneEmailTextField”,在第二个 View Controller (类2)中有文本字段“createdPasswordTextField”。如何将文本字段“createdPasswordTextField”从第二个 View Controller (类 2)链接回第一个 View Controller (类 1)以便执行 Firebase 函数?

最佳答案

使用segue将邮件文本字段的数据从第一个 View Controller 传递到第二个 View Controller 。简短地,搜索segue、导航 Controller 推送的工作原理。

关于ios - Firebase Auth,从不同类获取文本字段值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47686437/

相关文章:

swift - 在顶部 TableView 中对降序排列的日期进行排序

ios - 位置管理器无法在 iOS 中获得速度

android - FIrebase 归因中的 (not-set) 是什么意思?

javascript - 如何在 JavaScript 中从 firebase 实时数据库读取用户名?

ios - NSPredicate 忽略字符串中的数字 [拼音]

android - Android 的快速对话框之类的框架?

ios - 缩放时 UIScrollView subview 居中

ios - navigationBar 的自定义 barTintColor

ios - VoiceOver:PageViewController 中的 View Controller 宣布错误的页码

java - 为什么 Firebase 会默默地将我的长整型转换为整数?