Search
 
SCRIPT & CODE EXAMPLE
 

PHP

parent directory in php

I Hope this will help you.

echo getcwd().'<br>'; // getcwd() will return current working directory
echo dirname(getcwd(),1).'<br>';
echo dirname(getcwd(),2).'<br>';
echo dirname(getcwd(),3).'<br>';
Output :

C:wamp64wwwpublic_htmlstep
C:wamp64wwwpublic_html
C:wamp64www
C:wamp64
Comment

PREVIOUS NEXT
Code Example
Php :: array push object php 
Php :: foreach limit laravel 
Php :: php copy image from one folder to another 
Php :: How to Disable the WordPress JSON REST API Without Plugin 
Php :: wp_get_attachment_image class 
Php :: date between query in codeigniter 
Php :: get_posts category 
Php :: default port for laravel 
Php :: wordpress disable errors 
Php :: define url wordpress 
Php :: get last inserted id in php 
Php :: create session in wordpress 
Php :: magento 2 change customers password 
Php :: laravel generate slug 
Php :: php set header content type html 
Php :: php redirect if not logged in 
Php :: str_includes php 
Php :: Script timeout passed, if you want to finish import 
Php :: Add Laravel .env variable to Vue component 
Php :: display exception in blade laravel 
Php :: bcrypt laravel 
Php :: phpstan exclude line 
Php :: sum multiple fields separately in laravel 
Php :: php reset mysql array 
Php :: artisan call migrate result 
Php :: save error cakephp 2 
Php :: add like and equal in same query in laravel 
Php :: oxygen upload font 
Php :: create guid in php 
Php :: how to use sseders in laravel 
ADD CONTENT
Topic
Content
Source link
Name
2+9 =