Don't wanna be here? Send us removal request.
Text
Configure PHP mail() with GMAIL
Gmail
Enable access to less secure APP on yout account
Sendmail
Download sendmail
After downloading, extract to C:\php\lib\sendmail
Edit the file sendmail.ini with this values:
[sendmail] smtp_server=smtp.gmail.com smtp_port=465 smtp_ssl=ssl default_domain=localhost error_logfile=error.log debug_logfile=debug.log auth_username= enter your gmail account here auth_password= enter the password for that account here ; pop3_server= ; pop3_username= ; pop3_password= ; force_sender= ; force_recipient= hostname=localhost
PHP
Edit in file php.ini this values and uncomment this extensions:
[mail function]
...
sendmail_path = "C:\php\lib\sendmail\sendmail.exe -t -i"
...
extension=openssl extension=sockets
Apache
Uncomment the LoadModule SSL in file httpd.conf:
LoadModule ssl_module modules/mod_ssl.so
font
0 notes
Text
Installing PHP and Apache manually on Windows 10
PHP
Download PHP (Windows downloads)
Extract to C:/php
Open Control Panel > System > Advanced > Environment Variables
Double Click in Path on second box
Click in New and add C:\php
Confirm everything!
For test, open cmd and type this: php -v
Result:
PHP 7.2.7 (cli) (built: Jun 19 2018 23:14:45) ( ZTS MSVC15 (Visual C++ 2017) x64 ) Copyright (c) 1997-2018 The PHP Group Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
For run the embedded server: php -S localhost:8080
Apache
Download Apache
Visual C++ Redistributable for Visual Studio 2012 may be required
Extract to C:/Apache24
Edit C:/Apache/conf/httpd.conf:
#ServerName www.example.com:80 for: ServerName localhost:80
#LoadModule rewrite_module modules/mod_rewrite.so and remove the #
Open cmd, go to C:/Apache/bin and run the command: httpd.exe -k install
Allow access
Check http://localhost
Result:
Integrate with PHP
Open C:/Apache/conf/httpd.conf
Look for a section consisting of "LoadModule" lines and add at the end:
LoadModule php7_module "C:/php/php7apache2_4.dll" AddType application/x-httpd-php .php PHPIniDir "C:/php"
Look for the line:
DirectoryIndex index.html and replace for: DirectoryIndex index.html index.php
Configure your workspace folder
Open C:/Apache/conf/httpd.conf
Look for:
Define SRVROOT "C:/Apache24" and add after: Define WKSPACE "C:/Users/YOURUSER/Documents/"
Look for:
DocumentRoot "${SRVROOT}/htdocs" <Directory "${SRVROOT}/htdocs">
and replace for:
DocumentRoot "${WKSPACE}" <Directory "${WKSPACE}">
Below this line, look for:
AllowOverride None and replace for: AllowOverride All
font e font
1 note
·
View note
Text
'router-outlet' is not a known element
Action:
When executing the command ng test
Solution:
Add in app.component.spec.ts
import {RouterTestingModule} from '@angular/router/testing';
beforeEach(async(() => { TestBed.configureTestingModule({ declarations: [ AppComponent ], imports: [ RouterTestingModule ] });
...
font
0 notes