You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.markdown
+23-9Lines changed: 23 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -53,22 +53,36 @@ Installation
53
53
54
54
* Install your favourite mix of PHP and web server
55
55
* Install MySQL server
56
-
* Clone the project to some folder
56
+
* Clone the project to some folder of your choice.
57
+
* Alternatively, for composer fans: add a repository m in the repositories section of your composer.json:
58
+
<pre>
59
+
{
60
+
"type": "git",
61
+
"url": "https://github.com/path-to-this-repo.git"
62
+
}
63
+
</pre>
64
+
And then add the requirement `"xhprof/xhgui": "dev-master"` to your composer.json, then `composer update`.
57
65
* Map the sub folder `xhprof_html` to be accessible over HTTP
58
-
* Move `xhprof_lib/config.sample.php` to `xhprof_lib/config.php`
66
+
* You can do it with an Alias directive or (if symlinks are enabled) by just symlinking `xhprof_html` to any location within your document root.
67
+
* Copy `xhprof_lib/config.sample.php` to `xhprof_lib/config.php`
68
+
* Alternatively, you can copy the config.php to any place you like, and then specify the location of the config file in your ENV, in a PHP constant, or via Apache / Nginx Env variable (see below)
59
69
* Edit `xhprof_lib/config.php`
60
-
* Update the SQL server configuration
61
-
* Update the URL of the service (should point to `xhprof_html` over HTTP)
62
-
* Update the `dot_binary` configuration - otherwise no call graphs!
63
-
* Update the `controlIPs` variable to enable access.
70
+
* Update the SQL server configuration
71
+
* Update the URL of the service (should point to `xhprof_html` over HTTP)
72
+
* Update the `dot_binary` configuration - otherwise no call graphs!
73
+
* Update the `controlIPs` variable to enable access.
64
74
* For a development machine you can set this to `false` to disable IP checks.
65
75
* Import the DB schema (it is just 1 table)
66
76
* See the SQL at [xhprof_runs.php](https://github.com/toomasr/xhprof/blob/master/xhprof_lib/utils/xhprof_runs.php#L109)
67
77
* Add a PHP configuration to enable the profiling
68
-
* If using Apache you can edit your virtual host configuration
* (optional) Add `SetEnv ENV_XHPROF_CONFIG /absolute/path/to/config.php` to your apache config to set location of config file for that host
81
+
* (optional) If you include the header.php manually, you can define the location of the config file via define('XHPROF_CONFIG','/absolute/path/to/config.php');
82
+
* (optional) Within a shell script, you can export `XHPROF_CONFIG=/absolute/path/to/config.php` to specify location of config file
70
83
* Visit http://your-server/xhprof/xhprof_html/ and be amazed!
71
-
* To get profiler information showing up there visit your page with a `GET` variable `_profile=1`.
84
+
* To get profiler information showing up there visit your page with a `GET` variable `_profile=1`.
85
+
This will enable it (via cookie) until you disable it by adding the parameter `_profile=0` to any url (or removing the _profile cookie manually)
0 commit comments