setthreadtitle

Set the thread title

&reftitle.description; `bool` `setthreadtitle` `string` `title`

Sets the thread title.

&reftitle.parameters;

`title`

- The title to use as the thread title.

&reftitle.returnvalues;

&return.success;

&reftitle.examples;

### `setthreadtitle` example

Running the example below will change the thread title (visible with `ps c` for example).

    <?php
    setthreadtitle("myscript");
    ?>

&example.outputs.similar;

    $ ps c
      PID TTY      STAT   TIME COMMAND
     1178 pts/3    S      0:00 myscript

&reftitle.seealso;

- `pcntl_fork`
- `setproctitle`