Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2010-11-09 12:52:22

the_ghost
Plugin Author
From: Minsk, The Republic of Belarus
Registered: 2007-07-26
Posts: 907
Website

How do I can use new var "ihu" for hosting images at s subdomain?

Hi!

I’ve found in config-dist.php this line:

# define('ihu', 'http://static.example.com/');

I found also, that if this line is untouched or missed in config.php, than ihu=hu. It’s ok. Also i can create a subdomain at almost any hosting.

But the question is – how can I manage images in Content – Images, so, that changes apply to my images subdomain? The first way i can see – is to create some cron-like script, which will copy images from site.com/images to subdomain.site.com – but this is not txpish way :)

Other way, is to create some symbol link that will point subdomain.site.com to site.com/images

Are there other ways and which one did you choose?

Thanks!

I think, this discussion should be add to FAQ, after we will find best solution. It’s very useful and handy tool to speed site.


Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?

Offline

#2 2010-11-09 12:59:00

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,942
Website GitHub

Re: How do I can use new var "ihu" for hosting images at s subdomain?


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#3 2010-11-09 15:20:42

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,376
Website GitHub Mastodon

Re: How do I can use new var "ihu" for hosting images at s subdomain?

You can jump through all kind of hoops if you want to. But the most simple solution is to define a “mirror domain” as they call it (DNS CNAME record) for your main domain.

Offline

Board footer

Powered by FluxBB