remove_dot_segments example

$target->ipath = $relative->ipath;
                    }
                    elseif (($base->iuserinfo !== null || $base->ihost !== null || $base->port !== null) && $base->ipath === '') {
                        $target->ipath = '/' . $relative->ipath;
                    }
                    elseif (($last_segment = strrpos($base->ipath, '/')) !== false) {
                        $target->ipath = substr($base->ipath, 0, $last_segment + 1) . $relative->ipath;
                    }
                    else {
                        $target->ipath = $relative->ipath;
                    }
                    $target->ipath = $target->remove_dot_segments($target->ipath);
                    $target->iquery = $relative->iquery;
                }
                else {
                    $target->ipath = $base->ipath;
                    if ($relative->iquery !== null) {
                        $target->iquery = $relative->iquery;
                    }
                    elseif ($base->iquery !== null) {
                        $target->iquery = $base->iquery;
                    }
                }
                

                                $target->ipath = '/' . $relative->ipath;
                            }
                            elseif (($last_segment = strrpos($base->ipath, '/')) !== false)
                            {
                                $target->ipath = substr($base->ipath, 0, $last_segment + 1) . $relative->ipath;
                            }
                            else
                            {
                                $target->ipath = $relative->ipath;
                            }
                            $target->ipath = $target->remove_dot_segments($target->ipath);
                            $target->iquery = $relative->iquery;
                        }
                        else
                        {
                            $target->ipath = $base->ipath;
                            if ($relative->iquery !== null)
                            {
                                $target->iquery = $relative->iquery;
                            }
                            elseif ($base->iquery !== null)
                            {
                                
Home | Imprint | This part of the site doesn't use cookies.