Перейти к основному содержанию
Искать инструменты
Тема

Сохранено только на этом устройстве.

Русский

PHP Compiler

v1.0.0 Сервер

Write, run, and debug PHP online with real interpreter output, multi-file projects, stdin, and starter examples. No install, no sign-up — results in seconds.

Оцените первым Online Compiler
Использовать PHP Compiler сейчас
  • Регистрация не требуется
  • Бесплатно в использовании

Добавлено Поддерживается Parsepad

Краткий обзор

  • Where does my code run?
  • Can I run scripts that read input?
  • Does it support multiple files?
На этой странице
PHP Compiler

Рабочая область в реальном времени

Запуск Готово
[--:--:--] INFO Консоль готова. Запустите инструмент, чтобы увидеть активность.
Готово
Используется управляемый помощник Parsepad

Спросите что угодно об PHP Compiler

Вставьте входные данные выше и задайте вопрос или используйте быстрое действие.

ИИ-ответы об этом инструменте. Контекст рабочей области прикрепляется только если вы его включите.

Руководство

О PHP Compiler

Write and run PHP in your browser against a real interpreter. The Monaco editor gives you PHP syntax highlighting, find-and-replace, and formatting; the file explorer lets you build small multi-file scripts with require and include; and the standard-input panel feeds fgets(STDIN) so interactive scripts work too. Pick a starter template or paste your own code and see the actual interpreter output — including real notices, warnings, and fatal errors when something breaks.

Best Fit

  • Try a PHP function or language feature quickly without configuring a local server.
  • Reproduce a small bug across two or three files and share the exact repro.
  • Run a CLI-style script that reads input and read its output inline.

How to use the PHP Compiler

  1. Start from an example or write your own script in the editor.
  2. Add files in the explorer if your script spans more than one file.
  3. If your code calls fgets(STDIN), open the Input panel and add one line per read.
  4. Press Run (or Ctrl+Enter) to execute; read the output and any diagnostics below.
  5. Copy the code, or download it — multi-file projects download as a zip.

What the PHP Compiler helps with

  • Real PHP execution surfaces genuine notices, warnings, and fatal errors.
  • Multi-file scripts with a file explorer, tabs, and search across files.
  • Standard-input support so interactive CLI scripts run as intended.
  • Quality-of-life editing: format, find and replace, word wrap, minimap toggle.

Examples

Hello World

Input

<?php
echo "Hello, World!\n";

Output

Hello, World!

Reading input with stdin

Input

<?php
$name = trim(fgets(STDIN));
printf("Hi %s, your name has %d letters.\n", $name, strlen($name));
Input panel:
Ada

Output

Hi Ada, your name has 3 letters.

Frequently Asked Questions

Where does my code run?

Your code is sent to the Parsepad backend, executed by a real PHP interpreter in a sandbox, and the output is returned to your browser. Unlike a purely client-side tool, running requires a network round-trip — that is what lets it report genuine interpreter diagnostics.

Can I run scripts that read input?

Yes. Open the Input panel in the status bar and enter one line for each read your script makes. The lines are fed to standard input in order when you run.

Does it support multiple files?

Yes. Use the file explorer to add .php files and pull them in with require or include. When you download a multi-file project it is packaged as a zip so the structure is preserved.

Which PHP version is used?

A current stable PHP release. Language features from recent versions generally work; long-running operations and platform-specific extensions are limited by the execution sandbox.

Инструкции

Как пользоваться PHP Compiler

  1. Add input

    Start from an example or write your own script in the editor.

  2. Run tool

    Add files in the explorer if your script spans more than one file.

  3. Review output

    If your code calls fgets(STDIN), open the Input panel and add one line per read.

  4. Continue workflow

    Press Run (or Ctrl+Enter) to execute; read the output and any diagnostics below.

  5. Wrap up

    Copy the code, or download it — multi-file projects download as a zip.

Вопросы

Частые вопросы о PHP Compiler

Where does my code run?
Your code is sent to the Parsepad backend, executed by a real PHP interpreter in a sandbox, and the output is returned to your browser. Unlike a purely client-side tool, running requires a network round-trip — that is what lets it report genuine interpreter diagnostics.
Can I run scripts that read input?
Yes. Open the Input panel in the status bar and enter one line for each read your script makes. The lines are fed to standard input in order when you run.
Does it support multiple files?
Yes. Use the file explorer to add .php files and pull them in with require or include. When you download a multi-file project it is packaged as a zip so the structure is preserved.
Which PHP version is used?
A current stable PHP release. Language features from recent versions generally work; long-running operations and platform-specific extensions are limited by the execution sandbox.