Removing the index.php file Codeigniter

http://www.codeigniter.com/user_guide/general/urls.html

Neu van khong dc, vào http.conf sua:

<Directory d:/Workspace/mycodeigniter.com>
AllowOverride All
Require all granted

</Directory>
<VirtualHost *:80>
ServerAdmin webmaster@mycodeigniter.com
DocumentRoot “d:/Workspace/mycodeigniter.com”
ServerName mycodeigniter.com
ServerAlias http://www.mycodeigniter.com
DirectoryIndex index.php index.html
ErrorLog “logs/mycodeigniter.com-error.log”
CustomLog “logs/mycodeigniter.com-access.log” common
</VirtualHost>

Xdebug and Sublime Text | Vaerenbergh

This blog post is about making Xdebug work together with Sublime Text (in this example version 2). By many considered a tough task. But it’s doable. Your IDE will look something like this: A couple of assumptions made before continuing: Sublime Text 2 or higher is installed.

Source: Xdebug and Sublime Text | Vaerenbergh

 

custom shortcut key:

Reference->Keybinding user:

[
{“keys”: [“ctrl+f8”], “command”: “xdebug_breakpoint”},
{“keys”: [“shift+f8”], “command”: “xdebug_conditional_breakpoint”},
{“keys”: [“ctrl+shift+f5”], “command”: “xdebug_continue”, “args”: {“command”: “run”}},
{“keys”: [“f6”], “command”: “xdebug_continue”, “args”: {“command”: “step_over”}},
{“keys”: [“f7”], “command”: “xdebug_continue”, “args”: {“command”: “step_into”}},
{“keys”: [“f5”], “command”: “xdebug_continue”, “args”: {“command”: “step_out”}},
{“keys”: [“ctrl+shift+f9”], “command”: “xdebug_session_start”},
{“keys”: [“ctrl+shift+f10”], “command”: “xdebug_session_stop”},
{“keys”: [“ctrl+shift+f11”], “command”: “xdebug_layout”, “args”: {“keymap” : true}}
]

Get all trigger in sql server

SELECT
sysobjects.name AS trigger_name
,USER_NAME(sysobjects.uid) AS trigger_owner
,s.name AS table_schema
,OBJECT_NAME(parent_obj) AS table_name
,OBJECTPROPERTY( id, ‘ExecIsUpdateTrigger’) AS isupdate
,OBJECTPROPERTY( id, ‘ExecIsDeleteTrigger’) AS isdelete
,OBJECTPROPERTY( id, ‘ExecIsInsertTrigger’) AS isinsert
,OBJECTPROPERTY( id, ‘ExecIsAfterTrigger’) AS isafter
,OBJECTPROPERTY( id, ‘ExecIsInsteadOfTrigger’) AS isinsteadof
,OBJECTPROPERTY(id, ‘ExecIsTriggerDisabled’) AS [disabled]
FROM sysobjects

INNER JOIN sysusers
ON sysobjects.uid = sysusers.uid

INNER JOIN sys.tables t
ON sysobjects.parent_obj = t.object_id

INNER JOIN sys.schemas s
ON t.schema_id = s.schema_id

WHERE sysobjects.type = ‘TR’

Create user and enable remote Mysql

1) log-in your mysql via terminal as “root” –> mysql -uroot -p
2) CREATE USER ‘gioinv’@’%’ IDENTIFIED BY ‘your-password’ ;

3)

mysql> GRANT ALL ON database.* TO user@'10.10.0.2' IDENTIFIED BY 'user-password-here';
mysql> FLUSH PRIVILEGES;
(IP can be replaced with % to allow this user to logon from any host or IP.)

If connection still fails, check “bind-address” option in /etc/my.cnf file.

bind-address option is IP address to bind to.

4: /etc/my.cnf file

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
bind-address=192.168.33.10
port = 3306
# skip-networking

[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

 

Tạo Virtual host on window

  1. File httpd.conf:

#============================================
LoadModule php5_module “C:/php-5.6.23-Win32-VC11-x64/php5apache2_4.dll”
AddHandler application/x-httpd-php .php
#configure the path to php.ini
PHPIniDir “C:/php-5.6.23-Win32-VC11-x64”

Include conf/extra/httpd-vhosts.conf

2. File httpd-vhosts.conf: xóa hết nội dung sample của file

<Directory d:/SOFTWARE/PHP/wordpress-4.5.3/wordpress>
Options Indexes FollowSymLinks
AllowOverride None
Require all granted
</Directory>

<VirtualHost *:80>
ServerAdmin webmaster@mywordpress.com
DocumentRoot “d:/SOFTWARE/PHP/wordpress-4.5.3/wordpress/”
ServerName mywordpress.com
ServerAlias http://www.mywordpress.com
#ErrorLog “logs/mywordpress.com-error.log”
#CustomLog “logs/mywordpress.com-access.log” common
</VirtualHost>

 

3. File host:

127.0.0.1           http://www.mywordpress.com