[wp-trac] [WordPress Trac] #40573: Problem with wp_guess_url() during installation

WordPress Trac noreply at wordpress.org
Wed May 3 05:14:15 UTC 2017


#40573: Problem with wp_guess_url() during installation
-------------------------------+------------------------------
 Reporter:  pavelevap          |       Owner:
     Type:  defect (bug)       |      Status:  new
 Priority:  normal             |   Milestone:  Awaiting Review
Component:  General            |     Version:  trunk
 Severity:  normal             |  Resolution:
 Keywords:  reporter-feedback  |     Focuses:
-------------------------------+------------------------------
Changes (by dd32):

 * keywords:   => reporter-feedback


Comment:

 Replying to [ticket:40573 pavelevap]:
 > `$script_filename_dir . '/'` == `$abspath_fix` ==
 `/data/web/virtuals/160423/virtual/www/domains/domain.cz/`
 >
 > But `$_SERVER['PHP_SELF']` is `/domains/domain.cz/index.php`

 It looks like your host has an invalid value in `PHP_SELF` - based on your
 description of the URLs it should only contain `/index.php` according to
 the PHP Documentation:
 http://php.net/manual/en/reserved.variables.server.php#refsect1-reserved.variables
 .server-indices

 Ideally this should be brought to the attention of the web-host before
 WordPress attempts any form of work around here, as it's common practice
 for other PHP scripts to use something similar to `<form action="<?php
 echo $_SERVER['PHP_SELF']; ?>">` (please don't do that kids, I'm fairly
 sure that'll introduce security implications)

 Have you contacted your web-host about this yet? What did they say?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/40573#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list