How to deploy vue-codeigniter separated logic app on shared hosting? - codeigniter

let me explain the situation.
I have two front-end apps build with vue, one for client and other for admin.
And I build rest api with CodeIgniter.
As you see I have a separated logic here.
When I run build for the two apps and upload them along with the rest api to the server.
It will not run !

There is No logic to Deploy Codeigniter
Simply deploy it.

Related

Ways to test Nuxt.js frontend and Laravel Backend

I am looking for ways to test both Laravel API and Nuxt.js (frontend) at the same time.
A simple case where I want to test is the contact form. I can use jest to test that I submited the form and confirmation message appeared and I can test the api that when receiving certain data it returns ok but what would be the correct way for an integration test of the two?
For example if I want to test that by submitting the form the data are stored in the database?
I think the way to go is Laravel Dusk. Is this right? Can it be used for testing Nuxt.js? If so, how would I do that?
I have two different repositories, and in my laravel travic ci i git clone the nuxt.js and build it.
Can I just target the nuxt url with dusk? Or are there any other alternatives?

Get responses form a specific Google Form PHP / Laravel

I try to access to a Google Form but the API is in Google Apps Scripts. So we can't access it with a PHP script.
I'm using Laravel and this package could do the job but it's not compatible anymore :
https://github.com/akaramires/laravel-googleforms
How can I execute a Google Apps Script to get responses (with files uploaded by user) in a specific Google Form ?
https://developers.google.com/apps-script/reference/forms/form-response
Any ideas ?
Regards
There are two possible ways that you could do this:
Consider deploying the Script as a Web App. In particular, have a look at the section Deploying a script as a web app. Deploying scripts in this way allows you to do GET or POST requests to execute the code inside Google Scripts on demand.
Look at using the App Scripts API. I've previously used this API to build multiple Google Forms rather than building each one manually.

Consuming Laravel Passport API with javascript (React + Axios) from another application

I have managed to make run Laravel 5.4 and implemented the API Authentication (Passport).
What I would try to achieve is to make this as my API server and build React applications that would interact on this API.
Does this mean I have to make routes on routes\api.php?
Let's say I have a React app name requestform on development and running on http://127.0.0.1:8080. How will I consume an api route with axios or jquery?
I can't seem to make the correct keyword to search on google and all the samples I can get are the ones that the API and the javascript application is on the same domain.
This post may have been answered by now. But if not then...
I think you are in the right track..
Does this mean I have to make routes on routes\api.php?
Yes. Your API routes will depend on this file.
Let's say I have a React app name requestform on development and running on http://127.0.0.1:8080. How will I consume an api route with axios or jquery?
Make sure your API Server is running, say it's on http://server.dev, you can consume the API in another app by http://server.dev/api/[your-routes].
I can't seem to make the correct keyword to search on google and all the samples I can get are the ones that the API and the javascript application is on the same domain.
This is a matter of what front-end programming you know. You can use any javascript knowledge to consume your own API with the same domain. There is already a Vue integration packaged in Laravel 5.4+ or just plain vanilla javascript or jQuery.

Laravel: Understanding which api framework to choose

Our company is about to start a real estate project and have decided to go with the laravel 5.3 framework. The first phase is to write the apis and then these apis will be consumed by the mobile team and the frontend team to build the official mobile app and the web portal respectively.
Now I am confused whether to use laravel's built-in Resource controllers (as instructed in this tutorial http://www.programmableweb.com/news/how-to-build-restful-apis-using-php-and-laravel/how-to/2014/08/13) or use the Dingo Api framework.
Could you please help me which one should I go for and why as per the requirements i mentioned above?
Thanks in advance
Since, Laravel 5.3 comes with Passport (for api authentication), I would suggest you to use Resource controller, which is very simple and easy to work with, and also it create a meaningful end points
Route::resource('post','PostController');
GET /post/{post}
POST /post
EDIT /post/{post}/edit
DELETE /post/{post}

Can I have multiple web api dlls in the same site?

I have a need to provide a variety of Web APIs on a single site/url. My intent is to have API #1 in a project with API #2 in a separate project so that if I make changes to API #2 I can deploy without messing with API #1. I've done some tests and this seems to work but what happens if there are conflicting routes in each project?
Is there another way to accomplish the same thing?

Resources