noyman380/Angular-php-login-demo

语言: PHP

git: https://github.com/noyman380/Angular-php-login-demo

简单的AngularJs应用程序,它使用Slim框架来使用API​​来使用令牌登录和注册用户......
Simple AngularJs application that uses Slim framework for consuming an API to login and register users using a token …
README.md (中文)

角PHP-登录样本

这是一个为AngularJS项目使用令牌认证的示例应用程序。 该应用程序允许您添加,删除,编辑职位。

使用以下堆栈来创建后端: - 用于创建API的Slim Framework - 用于处理和创建令牌的PHP-JWT。 - Php-Login-Advanced。

查看正在进行的演示..

后端

这里重要的文件是:  index.php //此文件包含登录,注册和作业处理以及我的帐户的路由。  models / trucking.php //助手类。

Index.php包含处理客户端应用程序发送的请求的路由。 货运模型处理工作岗位的添加,删除和更新。它也处理 工作的回报。

前端

要查看身份验证的完成方式,您可以看到以下文件:  /services/authfact.js处理身份验证过程。  / account / dashboard显示了一种传递令牌以供服务器验证的方法。

本文使用googletrans自动翻译,仅供参考, 原文来自github.com

en_README.md

Angular-php-login-sample

This is a sample application that uses token authentication for an AngularJS project.
The application allows you to add, delete, edit job posts.

The following stack is used in order to create the backend:
- Slim Framework for creating the API
- PHP-JWT for processing and creating the tokens.
- Php-Login-Advanced.

View demo in progress..

Backend

The files of importance here are:
index.php // this file contains the routes to login, register, and the job handling as well as my account.
models/trucking.php // helper class.

Index.php contains the route that handles the requests sent by the client application.
The trucking model handles addition, deletion, and updating of a job post. It also handles
the returns of jobs.

Front End

To see how the authentication is done, you can see the following files:
/services/authfact.js handles the authentication process.
/account/dashboard shows one way to pass the token for the server to validate.