Page 2 of 2

Re: cannot login - PHP

Posted: Thu May 28, 2015 3:51 pm
by Celauran
Composer should be installed globally (/usr/local/bin, for example), so using that should be straightforward. Periodically (like once a month) run "composer self-update" and it will take care of itself.

I can't necessarily give specific details for installation because I don't know where you're getting the project source. Assuming it's from Git, then something like this should do:
[text][04:47 pm] [~/Sites]
$ git clone https://github.com/obfuscated/obfuscated.git ./Project-Name
Cloning into './Project-Name'...
remote: Counting objects: 350, done.
remote: Total 350 (delta 0), reused 0 (delta 0), pack-reused 350
Receiving objects: 100% (350/350), 405.69 KiB | 0 bytes/s, done.
Resolving deltas: 100% (155/155), done.
Checking connectivity... done.

[04:47 pm] [~/Sites]
$ cd Project-Name/

[04:47 pm] [~/Sites/Project-Name] [git master]
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing symfony/translation (v2.5.12)
Downloading: 100%

- Installing symfony/security-core (v2.5.12)
Downloading: 100%

[snip]

laravel/framework suggests installing doctrine/dbal (Allow renaming columns and dropping SQLite columns.)
Writing lock file
Generating autoload files
Generating optimized class loader
Compiling common classes
Compiling views

[04:49 pm] [~/Sites/Project-Name] [git master]
$[/text]

That's it. Make sure app/storage etc. is writable, update your DB credentials, and the project should run.

Re: cannot login - PHP

Posted: Fri May 29, 2015 8:49 am
by publicGenome
Hi Celauran,
I've one silly thing to ask.
Why login error cannot be found in any of the logs? I assume the failure should be logged in some file :?:

Re: cannot login - PHP

Posted: Fri May 29, 2015 9:59 am
by publicGenome
Hi Celauran,

I didn't have github code. I got code shared (on cloud-Google), downloaded it. Created folder name (PHP project) "Test_project" in Eclipse.
Copy pasted all files in this folder "Test_project". Hit Refresh. Went to folder location using terminal (bash).
run "composer self-update"
chmod -R a+rw "Test_project"

Then I proceeded as : composer install

This new project doesn't show me x or any red in on any of the folders, which I find in my other project (same files like this one). Thanks for this fix. :) :drunk:

Now, next thing: In my app->config->database.php; I've many arrays such as:
'some_name' => array(
'driver' => 'mysql',
'host' => 'localhost',
'database' => 'database_name',
'username' => 'pims_ro',
'password' => 'yVspPrPBwAJYTX6P',
'charset' => 'utf8',
'collation' => 'utf8_unicode_ci',
'prefix' => '',
),

But, I'm logging in my mysql via command line as root, and password blank.
I think, this could be an error? Such as:

'username' => 'root',
'password' => 'dont_know_hash_for_BLANK',

'password' => 'dont_know_hash_for_BLANK', This I don't know as I'm logging with no password, and mysql has its own method to encrypt password.

Let me know if I'm nearing to something good.

Many thanks, and appreciate your guidance, and time.

Best,
pG
Celauran wrote:Composer should be installed globally (/usr/local/bin, for example), so using that should be straightforward. Periodically (like once a month) run "composer self-update" and it will take care of itself.

I can't necessarily give specific details for installation because I don't know where you're getting the project source. Assuming it's from Git, then something like this should do:
[text]
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing symfony/translation (v2.5.12)
Downloading: 100%

- Installing symfony/security-core (v2.5.12)
Downloading: 100%

[snip]

laravel/framework suggests installing doctrine/dbal (Allow renaming columns and dropping SQLite columns.)
Writing lock file
Generating autoload files
Generating optimized class loader
Compiling common classes
Compiling views

$[/text]

That's it. Make sure app/storage etc. is writable, update your DB credentials, and the project should run.

Re: cannot login - PHP

Posted: Fri May 29, 2015 10:19 am
by Celauran
I recommend creating a separate non-root user for use in your projects, or one per project, and update your code accordingly.

Re: cannot login - PHP

Posted: Fri May 29, 2015 10:25 am
by publicGenome
Hi Celauran,
Thanks for your reply.
Celauran wrote:I recommend creating a separate non-root user for use in your projects, or one per project, and update your code accordingly.
I didn't get your comment quite well. Here, I do not know what I should be updating and to what? I'm sorry for being so dumb :banghead: :banghead:
For the sake of getting up this up and running, I'd keep as things are as root. All tables are created with root login.

Sorry for the inconvenience caused.

Re: cannot login - PHP

Posted: Fri May 29, 2015 11:33 am
by Celauran
Log into MySQL as root

Code: Select all

GRANT ALL PRIVILEGES ON database_name.* TO 'laravel'@'localhost' IDENTIFIED BY 'password_goes_here';
should do the trick.

You can try updating your current configuration (app/config/database.php) to use root as username and empty string as a password, but I honestly don't know if that will work.

Re: cannot login - PHP

Posted: Fri May 29, 2015 11:46 am
by publicGenome
Hi Celauran,

I'll take a break from this. I will get back on this, after ore home work on mysql, user, database name with which application is trying to log in.
Thanks for your extensive support.

Re: cannot login - PHP

Posted: Wed Oct 28, 2015 10:13 am
by publicGenome
@ Celauran:

I finally found solution to this. I had to change database password in the config file present/hidden. The database at my local are different than the original one.
It took ~5+ months though :)

Thank you.