Skip to content

Stdlib: urlencode, rawurlencode, parse_url for routing #76

Description

@PurHur

Problem

Query strings are parsed in Superglobals, but link generation and routers often need urlencode / parse_url.

Goal

Add minimal URL helpers to ext/standard/.

Tasks

  • VM delegate to PHP implementations
  • JIT: call libc or embed small encoder
  • PHPT: encode query arg, parse REQUEST_URI components
  • Use in examples/003-MiniWebApp router

Acceptance criteria

echo '<a href="?name=' . urlencode($name) . '">'; compiles and runs.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:webWeb / CGI / superglobalsenhancementNew feature or requestphase-4:stdlibPhase 4 – stdlib for web apps

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions