Drupal 8 Download File From Url

0 views
Skip to first unread message

Karla Pearcy

unread,
Jul 22, 2024, 2:53:00 PM7/22/24
to picnefimi

I have drupal installed as the root of my main domain. But I have now added some subdomain/add-on domains to that account (which do not use the main domain name), and the drupal mods to the .htaccess file makes these subdomains unusable. I have confirmed this by removing the .htaccess file and it works as expected.

drupal 8 download file from url


Download Filehttps://fancli.com/2zFQ4H



I realise that with some tweaking I could probably get these sites to work in harmony, but I dont want to have to edit the .htaccess for each new add-on domain... but I would still like to know how to do it for the interim. Somehow work out what lines are drupal specific and tell them to ignore my add-on domains, or some other way... HELP

I know it is not as simple as moving the files from the root of public to a sub folder, what other edits would be needed? ie, obviously some edits to the .htaccess files, but what about db settings? I'm sure from my Drupal 4 days there is a reference to the location in there somewhere 9but that was so long ago)...

I'm trying to do the same thing.. I moved my files to the new directory but I'm having trouble with the "clear the DB cache tables" part. Is this something that is done from within Drupal or directly with mysql, I'm using a 3rd party host and I don't see any options to do this in their cpanel.

EDIT: Just to clarify, my external web application is not consuming any data from Drupal what-so-ever. All I want to do is POST the "copied" search form to the Drupal engine and have it render the search results as if you had searched directly from the Drupal site. It seems like the Services module is used to streamline data to external web applications, and that is not the workflow here at all.

EXAMPLE: Say I have my Rails application sitting at and my Drupal site sitting at There is a search form at the root of my Rails application that is pretty much a copy paste of the browser code you'd see as if you had looked at the Drupal site source of the search form. It's just a simple text box with a submit button. When I submit that form from the Rails site, I want it to POST the data to the Drupal site and have the returned results be the exact same as if I had searched from the Drupal site directly (I said this already but it doesn't hurt to re-iterate), leaving the URL bar now saying

OK well, Ive moved the drupal folder to windows and imported the .SQL file into a blank .SQL file. And it is working in that my homepage now shows up. However if I click on any url links it goes to the phpmyadmin page. Here is the url in firefox when I click on a link that displays the phpmyadmin page:

Among the variables Drupal sets is the temp directory. I'm not sure why, but when registering CSS files, file_create_path identified the requested 'css' directory as being within the '/tmp' directory, which on the Windows server obviously does not exist. This caused drupal_build_css_cache to serve the file from the root '/css' directory, rather than the '/site/mysite/themes/mytheme/files/css' directory as it should have.

Currently I'm testing out/configuring drupal on my site in a subdirectory, while my old site stays in the root of my html directory.
Is there an easy way to move drupal so the index is in the /home/me/html directory, while all the other files stay in /home/me/html/drupal?

I'm not really sure what you're trying to say. If you mean that the front page appears at / and the second node appears at /drupal/node/2, I don't think you can do it. Frankly, I don't see why you would want to do it.

Currently I'm using wordpress.
My wordpress index file is at and all of the config files and such are in the wordpress directory.
I'm a fan of clean directory structures.
I'd like to do a similar thing with drupal.
So, the drupal index.php page would be in /home/me/html and it would reference /home/me/html/drupal
If that doesn't work, I can just move the entire directory contents up one directory right?

If I presently have Drupal 4.6 set up with /home/me/html/drupal/index.php and I want to move index.php to /home/me/html/index.php and leave all the other Drupal files in /home/me/html/drupal to maintain a "neat" html directory what adjustment to what file will accomplish this.

With WordPress the adjustment is very straightforward to move the index.php at /home/me/html/wordpress/index.php to /home/me/html/index.php with the remainder of the WordPress files remaining at /home/me/html/wordpress. You just adjust the index.php with the move from ./wp-blog-header.php to ./wordpress/wp-blog-header.php.

Yeah, you know, I like Drupal a lot. I downloaded it to a test directory on my website and poked around it a bit, trying to get the hang of it. Before I knew it, I'd converted my entire old site over to the drupal I had in my subdirectory.

My site worked like 10 minutes after that and started crumbling. Weird errors, strange layout, things disappearing or showing up wrong..it was a mess. I wound up having to wipe the whole thing out and start from scratch. It was a real chore (and a testament to how much I like this software) but Im 95% back up to speed now. Still a few things to add. Anyways, when I ran into problems I came here and searched high and low for help on transferring from one directory to the root directory and couldn't find anything...til now and now Ive already re worked everything.

I have transfered a number of sites over and over again. To and from subdirectories and site roots. If you have a backup of your database, then you should be able to restore it. I suggest reading th ebest practices link in my sig.

I had a site where I hadn't switched the domain over yet. I was working out of www.provider.com/mydomain/ for a while and then I transferred the host name and created a subdomain for my drupal install (test.mydomain.com).

When I went to view the site at test.mydomain.com, a story I added displayed but no theme and no menu and no error message. Weird. I searched around drupal.org and found this thread, but my issue seemed different so I opened up drupal's database and started looking for hardcoded paths.

It seems that some modules and themes store path information that is site specific thus making it more complicated to move an installation from directory to another. When I changed provider.com to test.mydomain.com everything started working just fine.

I can see how this could be a problem with changing site names. The alternative for more flexibility is to install all modules and themes under "drupal/modules" and "drupal/themes" and enabe the ones you want for each site. The price is a little clutter, of course.

hi,
i moved my site from subdir create to the root. how come the links for the old configuration works, for instance; www.example.com/subdir/?q=node/39. but the interesting thing is it does only work both for ?q= not the clean urls. how can i fix this?

This is a very old question, and from all that I have read I believe it is not possible to install Drupal in a subdirectory and access it as if it was the web root without displaying the subdirectory -- except if you can do (1) below.

Works fine for me with Drupal 5.1
I have Drupal in a subdirectory and with an .htaccess in the root folder I can access it as if it were in the root -- at www.example.com instead of www.example.com/drupal.
Details in the other thread.

Multisites work by comparing the requested URL with the names of the settings directories under /sites.
This apache rewrite adds "/drupal" to the requested URL.
If the multisites identification does not conflict with that, it might be ok. It may take some testing.

Well, I'm assuming the installation is in "/drupal". If you have it in /drupal5, then it would need to be changed accordingly. Or perhaps you have RewriteBase defined which then changes the URL content.

Since the URL doesn't exist, check to see if it exists in the Drupal directory - if so, use it. Had to play some games here to split up the URL and insert "drupal" in the middle. The DOCUMENT_ROOT may not accurately reflect the actual file path - especially if aliases have been used. You may need to use the actual path to the drupal directory instead:

Hello, I too have had some difficulty moving my drupal installation from mysite.com/drupal to mysite.com. I've spent many hours troubleshooting and just being frustrated. Now that I have it fixed, I'd like to share some tips.

One thing I would recommend is to switch to a default drupal theme if you are having trouble. I switched to garland and it started working. I switched back to my custom theme and it was working, but only on the admin page I was on. The front page still wouldn't work at all, just a blank white screen.

I'm using cpmfetch ( ) to extract some images from my coppermine photo gallery for display on the front page. I hadn't updated the link in the cpmfetch block. This one problem somehow prevented my entire front page from displaying at all. Fixed that and it works perfectly now.

So, to sum it up, yes, the posts here are correct that you only need to change settings.php and .htaccess to move a basic drupal installation. But if that doesn't work for you check the "other stuff" you have added to your page. Just a simple broken link can obviously cause some major unexpected problems.

I guess sooner or later a lot of us end up having this problem.
Everything has been installed in www.example.com/drupal in stead of www.example.com. However, to publish your site you want everything in www.example.com
How to get this done?

Now, when I installed Drupal for the first time, the install program within DirectAdmin suggested to install in the subdirectory /drupal.
I could have used the root, /, but as I got a warning (newbee.....) I followed the suggestion of installing in /drupal.
Also, in DirectAdmin is something one can use for redirection of url's, so I thought I could use that in the future.... (boy, I was quite wrong there. More about that later).
In my case the root, /, is shown in the filesystem of DirectAdmin as the file ..../public_html; but I will refer to root or / in the rest of this posting.

760c119bf3
Reply all
Reply to author
Forward
0 new messages