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

  • Home
  • SEARCH
  • 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 6766437
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T14:49:50+00:00 2026-05-26T14:49:50+00:00

I have trouble getting the absolute path with cakephp while using a shell. Shell

  • 0

I have trouble getting the absolute path with cakephp while using a shell. Shell do not load all the files like normal www files do. So i think is a file i need to load but i don’t know which…

What have i done already

  1. I have tried echo $this->Html->image($this->Html->url('/pluginName/image.gif',true));, normally this would work but not this time… it appears as if the true is not there and a relative path is set.
  2. define(‘FULL_BASE_URL’,’http:/domain’); this one works but is not portable, i need a solution that is portable since this shell may run from different servers that have different images absolute path (same name but the domain changes.

What i need

  1. It needs to be portable.
  2. It needs to give me the full url.
  3. It has to work within a shell.

Thanks in advance

  • 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-05-26T14:49:51+00:00Added an answer on May 26, 2026 at 2:49 pm

    The problem is that there is no web request when running a shell. The generated URLs are always relative to which URL the app was invoked with. On the shell, there is no URL to be relative to, and there can’t be a default URL since the app could be invoked from any number of URLs. You’ll need to hard-code the URL to be available in the shell.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This seemed like it should be easy, but I have had trouble getting it
iI have some trouble getting sth like this to work in java: public class
I have trouble getting started with rails 3.0.0, because it just doesn't load the
I have some trouble getting the VCS of teamcity work. I'm using perforce and
I have had trouble getting web pages to load within Cassini for about a
I have trouble getting a binding done using the WPF. I have a model
I have trouble getting a custom ObjectDataSource for an asp:ListView control to work. I
It seems that I have more trouble getting standard Unix things to run on
Hi I am having trouble getting an embedded js file to work. I have
I am having trouble getting my modal view controllers to display properly. I have

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.