GithubHelp home page GithubHelp logo

techiediaries / angular-php-example Goto Github PK

View Code? Open in Web Editor NEW
12.0 12.0 19.0 22 KB

Angular 7/8/9 Application with PHP Back-End Example

Home Page: https://www.techiediaries.com/angular/angular-9-php-mysql-database/

PHP 31.89% JavaScript 8.06% TypeScript 51.60% HTML 5.83% CSS 2.62%

angular-php-example's People

Contributors

techiediaries avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

angular-php-example's Issues

Deployment does not build frontend\src\app

The excellent tutorial skips deployment and confused me
Finally got deployment working

Brief steps

Created 2 folders in root of web server

/awvoice for Angular

/awvoicebe for PHP

NGINX
sudo vi /etc/nginx/sites-enabled/default
location /awvoicebe {
location ~* .(php|html|htm)$ {
try_files $uri =404;
fastcgi_split_path_info ^(.+.php)(/.+)$;
fastcgi_pass unix:/var/run/php/php5.6-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}

location /awvoice {
try_files $uri $uri/ /awvoice/index.html;
}

Edited in frontend\src\app\api.service.ts
PHP_API_SERVER = "http://192.168.1.150/awvoicebe";

DELETE Method restricted in NGINX
this.httpClient.delete not allowed ; change if interested

APACHE2
sudo a2enmod rewrite

sudo vi /etc/apache2/sites-available/000-default.conf
Append
<Directory /var/www/html>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Require all granted

create /var/www/html/.htaccess
Options +FollowSymLinks
RewriteEngine On
RewriteRule ^awvoice/dashboard$ /awvoice/index.html [NC]

Hope this benefits someone!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.