How to publish a directory from Joomla - joomla

I have a website created using joomla 3.0 (bitnami on amazon aws). I want to publish few files (html) from the website and was wondering how to do it ? Ideally I want to keep those htmls under /opt/bitnami/apps/joomla/htdocs/storage/matrix.html and then access it from my site using url : /storage/matrix.html
Any clues ?

I found the solution myself after trying out a few things. What I did was created a new directory called storage under htdocs (of my joomla installation) and then also copied a htaccess.txt file inside it (from another public folder). And that's it ! This directory is now public and I can access it like I wanted !

Related

Configuring Laravel project in DirectAdmin server

I'm a newbie to Laravel projects but I need to have one accessible over the internet so I tried using DirectAdmin but whenever I go to my domain I get an index (pictures attached).
I renamed the Laravel 'public' folder to 'public_html', is that correct? Here is my file structure.
Here is what I get when I go to my assigned domain which isn't my website at all.
The webpage should look something like this
I also found a laravel app using Softaculous linked here (https://panel.freehosting.com:2222/CMD_PLUGINS/softaculous/index.raw?act=software&soft=419). Am I required to use this app?
At first, you need to learn about the laravel directory structure. You don't need to change the laravel public folder to public_html. I am not sure how the DirectAdmin server works. but if you see a laravel directory instead of serving an application it's might be a path-related issue in your server. your domain should serve your application public folder.
I just found a tutorial for the DirectAdmin server with laravel. that might help.

Laravel, Using a cPanel shared hosting if possible?

I have a shared hosting with bluehost.com... can I just put my project on that.. like upload public files to public_html and others to root directory and backup MySQL DB and upload it to my shared hosting then edit my .env file... will this actually work with Laravel?
I searched most online resources and it requires ssh access to deploy, but the way I explained should not require that right?
I mean this way you don't have to go throw terminal access right?
I used to do that with WordPress when I want to set everything locally then upload it and edit URLs from the dashboard and stuff...
Yes it would work.
But you have to ensure one thing that, in your cpanel your domain point to the /public folder of laravel project.
Normally cPanel points the http requests to public_html folder, but laravel start from its public folder. You can achieve this by two way.
By pointing your server to straight to public folder
Copying the index.php to the public_html, in that case you have to edit index.php to run the laravel project properly. And I don't recommend this step. Step 1 is lot more easier.

transferring joomla from subdomain to main domain

i have my my website like abc.com/dev now i want to transfer it to abc.com,
what minimal changes should i do to make it work .
My website is in joomla is there way that i just move folder to main folder and add db setting.
Please guide i am new to joomla
Just Drag and drop your folders from your subdomain folder to root folder through FTP.
Then only changes you need to do is in your 'configuration.php' file located at the root folder. If your DB is not changed then do not change any of its setting. Just change the path of 'LOGS and TMP' folders in config file to the root path that are :
$log_path, $tmp_path
And I hope your site will work perfectly as it was working before.

Upload my Yii2 Project to CPanel

I have developed my Yii2 application locally and zipped the file and uploaded to CPanel under File Manager -> Public_html -> data. Now how can I access my application through the web? What is the url for my project? Should I do another installation? Please help me I'm stuck here.
Your projects are accessed trough the web folder. You have to point your Document Root of your domain to that folder.
If you cant make it work, you need to add your directory structure to the question.

How to Deploy Laravel 5 on shared cPanel hosting

I've been successful in deploying Laravel 4 applications on shared hosts by simply editing the paths here at /bootstrap/paths.php.
However, Laravel 5 does not have that file. How does Laravel 5 manage paths? I have access to the root directory with public_html. I can upload all the files to root and public directories, but confused where to look for the paths to be maintained?
Laravel 5 is smart enough to detect all it's path. I was missing some of the files during upload. :)
What I did was upload all the files as it is structured and the content of public folder was uploaded into the www directory, that's it!
You can play with creating new Application() in bootstrap/app.php. Its constructor takes argument which tells where is rest of the application related to public/index.php
Currently app.php has
$app = new Illuminate\Foundation\Application(
realpath(__DIR__.'/../')
);
Change the /../ to something else if rest of the application folders for example in ../laravel/ compared to index.html
If you have cPanel in your shared hosting you can try these easier methods before trying to move the Laravel's public folder:
Often you also have an SSH access when you have cPanel on shared hostings, so you can replace the www folder (i.e. the website document root) with a symbolic link to [app]/public, then deploy your Laravel app inside the [app] folder.
If you are deploying on a subdomain, e.g. [app].example.com, usually with cPanel you can choose the document root, then you can simply set it to [app]/public.
I think the two methods above are both easier and safer than moving the public folder. I would keep this as the last option.
Take a look here for some more info: http://blog.netgloo.com/2016/01/29/deploy-laravel-application-on-shared-hosting/

Resources