Search found 187 matches

by scottgcampbell
Tue May 03, 2016 2:03 pm
Forum: PHP
Topic: Toolkit Failure
Replies: 3
Views: 2765

Re: Toolkit Failure

Have you tried moving the Group parm below the size? That is the way they are defined in the program. Scott $param[] = $this->Toolkit->AddParameterZoned('both', 5, 0, 'Store #', 'STORE', str_pad($this->getStore(), 5, '0', STR_PAD_LEFT)); $param[] = $this->Toolkit->AddParameterZoned('both', 6, 0, 'St...
by scottgcampbell
Mon May 02, 2016 6:28 pm
Forum: New Toolkit
Topic: RTVNETA with CLCommandWithOutput()
Replies: 2
Views: 2998

Re: RTVNETA with CLCommandWithOutput()

Not sure where you are adding your function but getJobAttributes is in ToolkitService.php, so you would have to add it there or that would be the likely cause of the 500 error. If you want to do it without modifying ToolkitService.php you could use: $cmdString = 'RTVNETA SYSNAME(?)'; // Send command...
by scottgcampbell
Thu Apr 28, 2016 4:03 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

Can you post your code (both interested to see and it makes it easier to test/debug)? What I do is: 1 - Use QSYRUSRI to check invalid attempts so the user doesn't disable themselves, also checks for non-existent users 2 - Check users password by calling an RPG program that calls QSYGETPH and checks ...
by scottgcampbell
Fri Apr 22, 2016 8:31 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

Sorry, don't do that from PHP, I just call an RPG program that checks a few things and then calls it. In the RPG though I have them defined as 10a D CHGPWD PR EXTPGM('QSYCHGPW') D USER 10 D OLDP 10 D NEWP 10 D ERRDS 15 D CurrPwdSiz 10I 0 D PWDCCSID 10I 0 D NewPwdSiz 10I 0 D NWPDCCSID 10I 0 So those ...
by scottgcampbell
Fri Apr 22, 2016 7:31 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

We do password reset/change using QSYCHGPW in an RPGLE program called from PHP, but to do a reset (*NOPWD for the current password) you first have to switch to a user profile with *SECADM.

Scott
by scottgcampbell
Fri Apr 22, 2016 5:16 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

Thankfully I can help with that one :) (I'd feel pretty bad if I couldn't after that) I usually use this to check invalid attempts to prevent people from *DISABLING them selves, but it will work for what you want to do: Replace USERPROFILEHERE with a valid user profile. <?php require 'ToolkitService...
by scottgcampbell
Thu Apr 21, 2016 4:21 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

You would need to provide more details for anyone to help.
There are a lot of different types databases so depending on the type of database involved the answer will likely change, and be more helpful and accurate.

Scott
by scottgcampbell
Thu Apr 21, 2016 3:54 pm
Forum: PHP
Topic: Detecting Soon to Expire Password
Replies: 13
Views: 5960

Re: Detecting Soon to Expire Password

You would need to know the dates the users password will expire and the current date and compare them.
You don't mention how you are authenticating "users" so it is impossible to say how you might determine when the users password will expire.
by scottgcampbell
Tue Apr 12, 2016 5:52 pm
Forum: PHP
Topic: Logout session
Replies: 2
Views: 3126

Re: Logout session

by scottgcampbell
Thu Mar 17, 2016 2:20 pm
Forum: Zend Server for IBM i
Topic: Slow PHP performance gengeneral
Replies: 4
Views: 4182

Re: Slow PHP performance gengeneral

The performance would be slow because it has to start an entire PHP stack. But could also be an under powered/old server. I did some tests on our dev and production servers date;/usr/local/zendsvr6/bin/php-cli -r 'echo "test\n";';date Dev - 4 seconds Thu Mar 17 06:51:07 Mountain Daylight Time 2016 t...