Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7874501
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T02:49:04+00:00 2026-06-03T02:49:04+00:00

I have a problem to find out the relative path to upload the images

  • 0

I have a problem to find out the relative path to
upload the images to other directories

target directory

htdocs/dt3/tadi/adm/dim/dim_images/tadi_user_images/

source directory

htdocs/dt3/tadi/adm/cbt/uploadfile.php

uploadfile.php

<html>
    <form method="post"enctype="multipart/form-data">
        <input type="file" name="fileimg1" ><input type="submit" name="upload">
    </form>
</html>


<?php
    $dirname = "/dt3/tadi/adm/dim/dim_images/tadi_user_images/";    

    $of = $_FILES['fileimg1']['name'];
    $ext = pathinfo($of, PATHINFO_EXTENSION);

    $changename3 = time() * 24 * 60;
    $image_name3 = "timage_" . $changename3 . "." . $ext;

    $final_pathdir = $dirname . $image_name3;
    $suc = move_uploaded_file($_FILES['fileimg1']['tmp_name'], $final_pathdir);

    if ($suc > 0) 
    {
        echo "Image uploaded successfully"; 
    } 
    else 
    {
        echo "Error : " . $_FILES['filimg1']['error'];
    }
?>  

I tried out some of the paths, I didnt got any solution for that.
How can I upload images to that path?

htdocs/dt3/tadi/adm/dim/dim_images/tadi_user_images/

With relative path only.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T02:49:05+00:00Added an answer on June 3, 2026 at 2:49 am

    I believe you could do

    $dirname = dirname(__FILE__)."/../dim/dim_images/tadi_user_images/"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hope find a guru's help to figure out the next problem. I have two
I have for like 2 hours tried to find out the problem with the
i have problem . i want to find out the url form acnchor tag
I wish to find out does anyone have problem compiling JDK 7 code with
i have this problem to find a particular xml node l have post this
I have a problem which I cant seem to find answer to through searches
I have a problem with UISwipeGestureRecognizer and can't find the solution for it. I
I have this problem and i just cannot find a solution to it. I
I have a problem which i can't seem to find the solution to. I
I have a problem and search for a solution on Google but can't find

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.