0

Is it possible to have an entire path from a drupal 7 site , eg. /externalpaths which will go to an outside application, yet still have the same domain name in the url, so that it looks like you have not left the drupal site ?

0

There are two basic ways to accomplish this without resorting to iframes, you can either read the external application in with file_get_contents() and return it, but why take up a php process to accomplish this? A better way would be if you can enable mod_proxy or equivalent for your webserver.

http://httpd.apache.org/docs/current/mod/mod_proxy.html is the basic documentation for Mod Proxy. This is not always a good solution, however, if you can't modify the webserver settings or for when the external site is not returning correctly, it is often harder to determine where the issue lies.

If you enable a generic mod_proxy setting you can enable the rules in .htaccess with the P flag. See http://httpd.apache.org/docs/current/rewrite/flags.html

1
  • thanks I didnt specify in my question that what I wanted was how to do this without iframes. – user16839 Nov 18 '14 at 19:08
2

You should be able to do that relatively easily with full HTML mode using an <iframe src='desiredurl'></iframe>. You will most likely want to do some custom styling/template editing to make it look good.

Whether that is a good soluton for you depends a bit on how you want it to look etc. Do note taht security restrictions can break it - and make custom scripting/styling problematic as well inside the iframe. I'd suggest reading the Mozilla Dev Network's iframe page.

1

You can use the iframe page module to embed the external site to the Drupal site.

2
  • does that work even in androids? – user16839 Nov 18 '14 at 16:22
  • Iframe tag work from Android 4.0+ only. Lower versions does not support iframe tags. – Bakiya Nov 18 '14 at 17:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy