Melodia

Melodia

at Home

Member Since 1 Year Ago

Cape Town

Experience Points
21,130
Total
Experience

3,870 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed
159
Lessons
Completed
Best Reply Awards
0
Best Reply
Awards
  • start-engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber-token Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer-token Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • lara-evanghelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

Level 5
21,130 XP
Jan
24
4 weeks ago
Activity icon

Replied to What Can I Do As A Course Project With Laravel And Vue

Got it. I was thinking of the University management system. I am living in South Africa and noticed that somewhat these systems always lack something. But on the other hand, lectures are quite picky and complain when we do things that according to them already exist.

During my Diploma, I had built a library system, back then in Java, and my lecturer had mentioned to not like the fact that I did something that already exists out there in many places. :(

Activity icon

Started a new Conversation What Can I Do As A Course Project With Laravel And Vue

After throwing a few years of experience in PHP I am now deciding to go back to university and finish my tertiary education with an Advanced Diploma in application development, however, I am running out of ideas regarding a course project.

Anything that I can possibly create/innovate using Laravel and Vue?

Jan
15
1 month ago
Activity icon

Replied to I Have Valet Installed, But My Foobar.test Isn't Pinging

I had the valet folder in my vendor because I forgot the global command when reinstalling it with composer. So I removed from the composer.json and ran composer update. From the laravel folder, which is where all my laravel sites are, I installed valet globally and then ran valet install.

~laravel ~laravel cd projectname ~projectname valet link foobar A [foobar] symbolic link has been created in [/Users/user/.config/valet/Sites/foobar].

When I hit the url: project1.test. I still saw the same result: The page loads for a while before it tells me that the site could not be reached.

Jan
14
1 month ago
Activity icon

Started a new Conversation I Have Valet Installed, But My Foobar.test Isn't Pinging

I am having trouble to use valet.

This is all about my brew services:

➜  project1 git:(master) ✗ brew services list
Name      Status  User Plist
dnsmasq   started root /Library/LaunchDaemons/homebrew.mxcl.dnsmasq.plist
mariadb   error   user /Users/user/Library/LaunchAgents/homebrew.mxcl.mariadb.plist
[email protected] started user /Users/user/Library/LaunchAgents/[email protected]
nginx     started root /Library/LaunchDaemons/homebrew.mxcl.nginx.plist
php       started root /Library/LaunchDaemons/homebrew.mxcl.php.plist
➜  project1 git:(master) ✗

If I type valet, it prompts me for the password and then I see the result:

➜  project1 git:(master) ✗ valet
Password:
Laravel Valet 2.8.1

Usage:
command [options] [arguments]

Options:
  -h, --help            Display this help message
  -q, --quiet           Do not output any message
  -V, --version         Display this application version
   --ansi            Force ANSI output
   --no-ansi         Disable ANSI output

...

Also, If I type valet parked, I see all my parked sites, like:

http://project1.test

But when I hit project1 url, It says that the page cant be reached.

I parked all the sites under a folder named laravel. If I try to ping foobar.test from that folder, it says the following:

ping: cannot resolve foobar.test: Unknown host

And now, I started the project using artisan serve, when I hit the url uring the IP address, I see the following errors:

Notice: Undefined index: HOME in 
/Users/user/Desktop/Sites/laravel/project1/vendor/laravel/valet/cli/includes/helpers.php on 
line 13

Notice: Undefined index: HOME in 
/Users/user/Desktop/Sites/laravel/project1/vendor/laravel/valet/cli/includes/helpers.php on 
line 17
this is the homepage:

I assume this is all has to do with valet.

How can I fix the valet issue?

Activity icon

Replied to Spatie Sitemap Generates Xml File But No Link Is Added

@snapey I have this in the route:

Route::get('map', function() {

    SitemapGenerator::create(env('APP_URL'))->writeToFile('sitemap.xml');
    return "sitemap generated";
    
});

And this is the app url in the .env file:

APP_URL=http://127.0.0.1:8000

When I hit the map url, I see the same result saying sitemap generated, when I visit the xml, I see the following

<?xml version="1.0" encoding="UTF-8"?>
    <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml">
</urlset>
Jan
13
1 month ago
Activity icon

Started a new Conversation Spatie Sitemap Generates Xml File But No Link Is Added

How do I use sitemap in laravel?

I'm trying to use spatie sitemap package but am running into a few problems. First, when I added the following code and hit the url, the sitemap file is created but not url is created:

Route::get('map', function() {

    SitemapGenerator::create('http://127.0.0.1:8000')->writeToFile('sitemap.xml');
    return "sitemap generated";
    
});

So, I decided to add them via the manual option:

Route::get('sitemap', function () {
    SitemapGenerator::create('http://127.0.0.1:8000')->getSitemap()
    ->add(Url::create('/')->setPriority(0.5))
    ->add(Url::create('/admin/{locale}/post/{post}')->setPriority(0.5))
    ->add(Url::create('/languages')->setPriority(0.5))
    ->writeToFile('sitemap.xml');
    return "Sitemap Generated";
});

and the sitemap looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml">
    <url>
        <loc>http://127.0.0.1:8000</loc>
        <lastmod>2020-01-13T16:01:24+00:00</lastmod>
        <changefreq>daily</changefreq>
        <priority>0.5</priority>
    </url>
    <url>
        <loc>http://127.0.0.1:8000/{language}/post/{post}</loc>
        <lastmod>2020-01-13T16:01:24+00:00</lastmod>
        <changefreq>daily</changefreq>
        <priority>0.5</priority>
    </url>
    <url>
        <loc>http://127.0.0.1:8000/languages</loc>
        <lastmod>2020-01-13T16:01:24+00:00</lastmod>
        <changefreq>daily</changefreq>
        <priority>0.5</priority>
    </url>
</urlset>

Question 1: any reason why the sitemap did not generate with the first code?

Question 2: How does it really work for URL with parameters? I might have multiple posts from in the database, so ideally there should be a url generated for each post.

Jan
07
1 month ago
Activity icon

Started a new Conversation How Do I Print An Inventory List Using Many To Many Relationships

I have a student and task table, and model. Created a pivot table called student_task and here is how i set up the relationship:

class Task extends Model {
    public function students() {
        return $this->belongsToMany(Student::class);
    } .  
}

class Student extends Model{
    public function tasks() {
        return $this->belongsToMany(Task::class);
    }
}

How can I print a list of all students and associated task? In a way, I would want to see the student and task name.

I tried this:

Route::get('student-tasks', function() {
    $students = Student::all();
    foreach($students->tasks as $task) {
        echo $task->name;
    }
});

When I hit the url, I get the following error:

Property [tasks] does not exist on this collection instance.

How can I print a list of all students and associated task?

Note: if I try the code below, I get a list of tasks associated to the user.

$student = Student::first();

return $student->tasks;
Dec
06
2 months ago
Activity icon

Commented on Filtering Aggregated Data

I feel you :)

Nov
27
2 months ago
Activity icon

Replied to Filter Through Array Of Objects Not Working

oops. So I guess I wouldn't have encountered this issue if I tried the code directly on my project since I use webpack to compile. Appreciate the support and definitely agree about the googling on es6-es7 for better knowledge instead of just using things :)

Activity icon

Replied to Filter Through Array Of Objects Not Working

The answer is correct. but why is it that my "this" had no access to the property?

Activity icon

Replied to Filter Through Array Of Objects Not Working

The intention is to have a filtered array yet, but if I type paste "fweffef" which does not match any condition, it still shows an array of 4 objects.

I created a fiddle for it:

https://jsfiddle.net/Wosley_Alarico/n0qgzkbo/66/

Activity icon

Started a new Conversation Filter Through Array Of Objects Not Working

I have an input field in my template that looks like this:

    <input type="text" v-model="search" @keydown="inputChanged" />

Inside my data object I have a list of users:

users: [
  { id: 1, text: "Learn JavaScript", done: false },
  { id: 2, text: "Learn", done: false },
  { id: 3, text: "Play around in JSFiddle", done: true },
  { id: 4, text: "Build something awesome", done: true }
],

How can I return objects based on what the words that a user types when searching for user through text?

My inputChanged method looks like this:

 inputChanged(){
  var filtered = this.users.filter(function (user) {
    return user.text.match(this.search)
  });

If I console log the filtered variable and type any letter, it logs the users' array, which is incorrect.

Activity icon

Replied to Laravel 6 From Scratch, Installation Issues.

My advice, uninstall everything you've installed and check this tutorial from Jeffrey. I personally set up local environments several times and noticed that after installing brew, zsh and php, it automatically switches to the latest version.

https://laracasts.com/series/setup-a-mac-dev-machine-from-scratch

Nov
15
3 months ago
Activity icon

Replied to My Laravel Command Does Not Work After I Restart My Terminal

Yes, my zsh was set to start as default during the installation, and I am managing to use the laravel commands at any time after restarting the terminal or the machine itself.

Activity icon

Replied to My Laravel Command Does Not Work After I Restart My Terminal

The source command fixed the issue

Activity icon

Started a new Conversation My Laravel Command Does Not Work After I Restart My Terminal

I just followed the laravel installation process and got everything to work fine, however, after restarting my terminal(oh-my-zsh), if I try to run laravel new projectname, I see this error:

zsh: command not found: laravel

However, if I run composer global show, I see valet and installer are indeed installed:

laravel/installer                        v2.2.1  Laravel application installer.
laravel/valet                            v2.5.2  A more enjoyable local development experience for Mac.

I also tried adding this:

echo 'export PATH="$PATH:$HOME/.composer/vendor/bin"' >> ~/.zshrc

and I can see it if I visit my zshrc file

How can I indeed have laravel installer globally and run the laravel commands at any time?

Nov
06
3 months ago
Activity icon

Replied to Eloquent Create And Axios Vuejs Post Request Does Not Save File And Save Other Records With Error

Yes, you are right, and I also accept your suggestion. And my final refactored code looks like this:

public function createProjectTask(Request $request, Project $project) {
    $task = Task::create($request->except(['file']));

    if($request->hasFile('file')){
        $fileName = $request->file->getClientOriginalName();
        $request->file->move(public_path("tasks/{$task->id}"), $fileName);
        $task->fill(['file' => $fileName]);
    }
    return $task;
}
Activity icon

Started a new Conversation Eloquent Create And Axios Vuejs Post Request Does Not Save File And Save Other Records With Error

My route looks like this:

Route::post('task/project/{project}/save', '[email protected]');

The method in the controller looks like the following:

public function createProjectTask(Request $request, Project $project) {
    $input = $request->all();
    $task = Task::create([
        'project_id' => $request->project_id,
        'owner_id' => '3',
        'name' => $request->name,
        'description' => $request->description,
        'summary' => $request->summary,
        'duration' => $request->duration,
    ]);
    if(empty($input['file'])) {
        $fileName = $request->file->getClientOriginalName();
        $request->file->move(public_path("tasks/{$task->id}"), $fileName);
        $task->fill(['file' => $fileName]);
    }
    return $task;
}

I use axios to execute the post request inside a vuex action and it looks the following from the vue side:

In the vue template, I have the function that gets the file data in case a file is selected, and then I have the submission of the form:

onFileChange(e) {
    this.task.file = e.target.files[0]
},

formSubmit(e){
    e.preventDefault()

    var formData = new FormData();
    formData.append('project_id', this.projectId)
    formData.append('name', this.task.name)
    formData.append('description', this.task.description)
    formData.append('summary', this.task.summary)
    formData.append('duration', this.task.duration)   
    
    if(this.task.file != ''){
        formData.append('file', this.task.file)
    }

    const taskData = {
        formData: formData,
        projectId: this.projectId
    }

    this.$store.dispatch('addProjectTask', taskData)

}

addProjectTask is the action and looks like the following:

addProjectTask({commit}, taskData) {
    axios.post('/task/project/' + taskData.projectId + '/save', taskData.formData)
    .then(res => {
        console.log(res.data)
        console.log("New task added")
    })
    .catch(err => console.log(err))
}

I noticed two things: 1 - the file is not saved at all. 2 - i try to save the data without an image, in the console, i get a 500 internal server error, but if i visit the database, the record actually gets added.

How can I save the records with or without image and not have the internal server error?

Nov
04
3 months ago
Activity icon

Started a new Conversation I Get An Error When I Try To Access A Property Of A Nested Object

My request in the vue side looks like this:

axios.get('/api/project/' + this.$route.params.id)
.then(res => {
    this.project = res.data
})
.catch( err => console.log(err))

If I console.log "this.project" I get the project with its related owner details, like so:

project: {
    id: 1
    name:
    owner: {
        name: 'my name comes here'
    }
}

In the template, I want to display the owner, as well as the the name of the project and I do it like this:

 <p>{{ project.owner.name }} | {{ project.name }}</p>

The owner name shows, however, I notice the following error/warning in the console:

[Vue warn]: Error in render: "TypeError: Cannot read property 'name' of undefined"

If I remove the "project.owner.name", the error disappears.

Why does it show the owner name but it says undefined at the same time? The same is happening for all other properties that are nested inside other objects.

Nov
02
3 months ago
Activity icon

Started a new Conversation How Can I Download A File In Laravel And Vuejs

I initially created a route that allows a user to download a specific file, which works perfectly fine.

Route::get('project/{project}/download', '[email protected]'); 

public function downloadFile(Project $project){
    return response()->download(public_path() . "/upload/WhatsApp Image 2019-10-31 at 19.57.15.jpeg");
}

When I hit the url, the download happens.

How can I do the same via vuejs?

I tried using that end point inside the component but it doesn't download the file.

The component looks like this:

<template>
    <button @click="download" class="btn btn-primary">Download file</button>
</template>

<script>
    export default {
        methods: {
            download(){
            axios({
                    url: '/project/1/download',
                    method: 'GET',
                    responseType: 'blob',
                })
                .then((res) => console.log(res.data))
                .catch(err => console.log(err))
            }
        }
    }
</script>

When I hit the download button, I see the following in the console

Blob {size: 73561, type: "image/jpeg"}

and file does not download.

How can I download a file using laravel and vuejs?

Oct
27
3 months ago
Activity icon

Started a new Conversation How Can I Controller My Web Routes From Vuejs Except A Specific Prefixed Route?

I created a few resources and the controller looks like this:

Route::prefix('company')->group(function(){
    Route::resource('projects', 'ProjectController');
    Route::resource('tasks', 'TaskController');
});

So, those are the end point that I want to access on the vue.js side.

If I hit the url: site.example/compnay/tasks, I see the response.

Next, I added the following to my web routes under the intention of having my routes rather managed on the vue side:

Route::get('/{any}', '[email protected]')->where('any', '.*');

But, after adding that, if I hit site.example/compnay/tasks I no longer see the desired response I had seen previously, but the App Component content, which looks like this:

<template>
    <div class="container">
        <div class="row justify-content-center">
            <div class="col-md-8">
                <div class="card">
                    <div class="card-header">Example Component</div>

                    <div class="card-body">
                        I'm an example component.
                    </div>
                </div>
            </div>
        </div>
    </div>
</template>

<script>
    export default {
        mounted() {
            console.log('App component mounted.')
        }
    }
</script>

And this is how my app.js looks like this:

require('./bootstrap');

import Vue from 'vue'
import App from './App.vue'

Vue.component('app-component', require('./components/MainComponent.vue').default);

new Vue({
    render: h => h(App)
}).$mount('#app');

How can I controller the routes via vue.js, but still be able to see the response from all the routes under the company prefix? So if I hit site.example/company/tasks, I am able to see the json response.

Sep
14
5 months ago
Activity icon

Commented on Building The World

Brilliant!

Sep
07
5 months ago
Activity icon

Started a new Conversation My Valet Installation Does Not Pink And Brew Services Don't Run Properly

Am having a hard time to run laravel projects on a mac.

After installing homebrew, I ran the following commands:

brew update

brew install php

When I run brew services list, I see the following:

Name    Status  User   Plist
mariadb stopped
mysql   started sidney /Users/sidney/Library/LaunchAgents/homebrew.mxcl.mysql.plist
php     error   root   /Library/LaunchDaemons/homebrew.mxcl.php.plist

composer global require laravel/valet

valet install

When I try to ping: ping test, it takes a few seconds, and then I see this message:

ping: cannot resolve foobar.test: Unknown host

Troubleshooting further, I ran the following commands and saw the respective results:

Sydney-de-Sousas-Mac:~ sidney$ brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry or file an issue; just ignore this. Thanks!

Warning: Unbrewed header files were found in /usr/local/include.
If you didn't put them there on purpose they could cause problems when
building Homebrew formulae, and may need to be deleted.

Warning: You have unlinked kegs in your Cellar.
Leaving kegs unlinked can lead to build-trouble and cause brews that depend on
those kegs to fail to run properly once built. Run `brew link` on these:
  mariadb
  mysql
Sydney-de-Sousas-Mac:~ sidney$ brew link mariadb
Linking /usr/local/Cellar/mariadb/10.4.6_1... 197 symlinks created
Sydney-de-Sousas-Mac:~ sidney$ brew services list
Name    Status  User   Plist
mariadb stopped
mysql   started sidney /Users/sidney/Library/LaunchAgents/homebrew.mxcl.mysql.plist
php     error   root   /Library/LaunchDaemons/homebrew.mxcl.php.plist
Sydney-de-Sousas-Mac:~ sidney$

How do I successfully install valet and run laravel projects using it?

My system version is 10.13.6 - High Sierra

Aug
26
5 months ago
Activity icon

Started a new Conversation How Do I Format Json Data From Api Call?

My snippet looks like this:

$curl = curl_init();

curl_setopt_array($curl, array(
    CURLOPT_URL => "https://example.example.co.za/api/consumers/get?id=32223&[email protected]",
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_ENCODING => "",
    CURLOPT_MAXREDIRS => 10,
    CURLOPT_TIMEOUT => 30,
    CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
    CURLOPT_CUSTOMREQUEST => "GET",
    CURLOPT_FOLLOWLOCATION => true,
    CURLOPT_POSTFIELDS => "",
    CURLOPT_HTTPHEADER => array(
    "Accept: */*",
    "Authorization: Bearer thetoken",
    "Cache-Control: no-cache",
    "Connection: keep-alive",
    "Content-Type: application/x-www-form-urlencoded",
    "accept-encoding: gzip, deflate",
    "cache-control: no-cache",
    ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

return $response;

The response shows me an object like this:

{
    success: true,
    count: 1,
    data: [{
       id: 3429217,
       brand_id: 2323,
       first_name: "My name",
    }]
}

First: Instead of return the entire JSON, how can I return only the data inside the data key? Second: What would be the best way to do this API call?

Aug
20
6 months ago
Activity icon

Replied to I Get An Access Denied When I Try To Access My Database After Installing Valet

Right now, I closed all the terminals and re-opened. If I type "mysql", I managed get into the server, but if I try to create a database then I get access denied.

If I exit and try to enter using mysql -uroot I also get access denied as before

Activity icon

Started a new Conversation I Get An Access Denied When I Try To Access My Database After Installing Valet

Am currently migrating to mac OSX and I want to use valet for my laravel sites. So here is where I got stuck:

After installing homebrew, PHP and the rest of the requirements that valet needs, when I got to my terminal, I can't access my database.

At first, I had this:

Sydney-de-Sousas-Mac:~ sidney$ mysql -uroot
mysql: Can't read dir of '/usr/local/etc/my.cnf.d' (OS errno 2 - No such file or directory)
mysql: [ERROR] Fatal error in defaults handling. Program aborted!
Sydney-de-Sousas-Mac:~ sidney$ mysql server start
mysql: Can't read dir of '/usr/local/etc/my.cnf.d' (OS errno 2 - No such file or directory)
mysql: [ERROR] Fatal error in defaults handling. Program aborted!
Sydney-de-Sousas-Mac:~ sidney$ mysql
mysql: Can't read dir of '/usr/local/etc/my.cnf.d' (OS errno 2 - No such file or directory)
mysql: [ERROR] Fatal error in defaults handling. Program aborted!

Then I created the file it requested:

Sydney-de-Sousas-Mac:~ sidney$ mkdir /usr/local/etc/my.cnf.d

But I get access denied when I try to access my DB

Sydney-de-Sousas-Mac:~ sidney$ mysql -uroot
ERROR 1698 (28000): Access denied for user 'root'@'localhost'
Sydney-de-Sousas-Mac:~ sidney$ mysql -uroot -p
Enter password:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'

I thought that by default the password is an empty string.

How do I access my database?

Activity icon

Started a new Conversation How To Fix 302 Too Many Redirects

I have a website with multisite set to true.

I can see all the pages regardless of the language, however, If I am on the dashboard, and hover over my sites, I cant see any of the dashboards of the other languages.

After a few seconds a see an error that says too many redirects.

If I inspect the page and view the network tab, I see a 302 error.

I have this in my configuration:

define('WP_ALLOW_MULTISITE', true);
define('MULTISITE', true);
define('SUBDOMAIN_INSTALL', false); // Set to false if you selected the "Sub-directories" installation.
define('DOMAIN_CURRENT_SITE', 'localhost');
define('PATH_CURRENT_SITE', '/');
define('SITE_ID_CURRENT_SITE', 1);
define('BLOG_ID_CURRENT_SITE', 1);

/*----------------------------------------------------*/
// Authentication unique keys and salts
/*----------------------------------------------------*/
/*
 * @link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service 
 */
define('AUTH_KEY',         'i7a3cyhnq7r89qtnr87639nf70wq3tyy0w9fny089q3fyw78yn0987fcwy890');
define('SECURE_AUTH_KEY',  'io7scyo7fystyf98st86rcts6er7te67ctsert676erctse7r6ts76etv76tr');
define('LOGGED_IN_KEY',    'ij8sddufs8yf657s4c57sfrt8697rf9fn89jsu094s8uf09488us4f089yu0v');
define('NONCE_KEY',        'sdaf8yv65643v5ft68suvs9cu9p0w349u90-48u489wy98fu984f98euf9889');
define('AUTH_SALT',        '9z08jxe6h789mn8b67c8n7xm893n280n7c4mx9cn749mx89cn78438m02n9c7');
define('SECURE_AUTH_SALT', '21333333333780v465bn87b698n7ewc8n48fu848c4mncf4u84wfcum84f4cw');
define('LOGGED_IN_SALT',   'yr5bt3268mu30mu89248mufxy79ny79x9m89u2mu892dxm8u9d2xmu89dx298');
define('NONCE_SALT',       '4e6r57t8yz9u80t6y79n8b6t7rzmy890nxg8zhm0x79gnhmz280gx7989898y');

/*----------------------------------------------------*/
// Custom settings
/*----------------------------------------------------*/
define('WP_AUTO_UPDATE_CORE', false);
define('DISALLOW_FILE_EDIT', true);
define('WP_DEFAULT_THEME', 'themosis-theme');

Inside the htaccess I have this:

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]

# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) cms/ [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ cms/ [L]
RewriteRule . index.php [L]

Options -Indexes

I noticed that there a several question on the web about the same issue, which didn't resolve my issue, so I thought best to also post what I currently have in my users table:

MariaDB [theme]> select * from wp_options limit 10;
+-----------+--------------------+------------------------------+----------+
| option_id | option_name        | option_value                 | autoload |
+-----------+--------------------+------------------------------+----------+
|         1 | siteurl            | http://localhost/cms         | yes      |
|         2 | home               | http://localhost             | yes      |
|         3 | blogname           | Themename                | yes      |
|         4 | blogdescription    |                              | yes      |
|         5 | users_can_register | 0                            | yes      |
|         6 | admin_email        | [email protected] | yes      |
|         7 | start_of_week      | 1                            | yes      |
|         8 | use_balanceTags    | 0                            | yes      |
|         9 | use_smilies        | 1                            | yes      |
|        10 | require_name_email | 1                            | yes      |
+-----------+--------------------+------------------------------+----------+
10 rows in set (0.00 sec)

NOTE: The site was installed with docker, so the file structure does not look exactly the same like in regular WordPress sites.

From the root directory, my site sits under htdocs/content/themes/themename

To login to the main dashboard, I type: localhost/cms/login

MORE INFO: This is a WordPress site that uses themosis framework, which is based on Laravel, however, during all this time I am spedning to try to fix this, I noticed that this is very likely to do with the htaccess. As a matter of fact, If I inspect my network tab, I see a 302 error that fires of about 8 times.

How can I view the dashboard for the other languages?