<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 31/07/2016, at 13:42, John C <<a href="mailto:jc@sunshinesoftware.co.nz" class="">jc@sunshinesoftware.co.nz</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div class="WordSection1" style="page: WordSection1; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;"><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">Hi all<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class=""><o:p class=""> </o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">I have a website what will be available to the public but specific for more than one clients. The frame work of the website will be the same for each client but their images and CSS file will be different (making it look differently).<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">The plan is to have a sub-domain for each client from where it will jump to the "common" pages on the main domain. The index file on each sub.domain identifies the client and therefore define the directory path to use for the images and the CSS file.<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">I was thinking of doing this with cookies for the paths to be used in the main program, but I'm not sure it would be a good plan and if that will work properly (setting a cookie from within a sub.domain to be used in the main domain).<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class=""><o:p class=""> </o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">Any ideas or suggestions of how to do this?<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class=""><o:p class=""> </o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">Thanks a lot in advance<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class="">John C<o:p class=""></o:p></span></div><div style="margin: 0mm 0mm 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif;" class=""><span style="font-family: Arial, sans-serif;" class=""><o:p class=""> </o:p></span></div></div><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">_______________________________________________</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">NZ Borland Developers Group - Delphi mailing list</span><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Post:<span class="Apple-converted-space"> </span></span><a href="mailto:delphi@listserver.123.net.nz" style="color: purple; text-decoration: underline; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">delphi@listserver.123.net.nz</a><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Admin:<span class="Apple-converted-space"> </span></span><a href="http://delphi.org.nz/mailman/listinfo/delphi" style="color: purple; text-decoration: underline; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">http://delphi.org.nz/mailman/listinfo/delphi</a><br style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Unsubscribe: send an email to<span class="Apple-converted-space"> </span></span><a href="mailto:delphi-request@listserver.123.net.nz" style="color: purple; text-decoration: underline; font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">delphi-request@listserver.123.net.nz</a><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class=""><span class="Apple-converted-space"> </span>with Subject: unsubscribe</span></div></blockquote></div><br class=""><div class="">Hi,</div><div class=""><br class=""></div><div class="">Delphi gets the VHOST of the web server into the application code, so you could just use that. No need for “cross-site” cookies. I would personally keep the logo and CSS in the sub.domain and then simply refer to them:</div><div class=""><br class=""></div><div class=""><a href="http://sub.domain.com/" class="">http://sub.domain.com/</a> <— that is the index call right</div><div class=""><br class=""></div><div class="">Your Logo would then be at:</div><div class=""><br class=""></div><div class=""><img src=“/images/logo.png”/></div><div class=""><br class=""></div><div class="">While you CSS would be something like “/styles/main.css”</div><div class=""><br class=""></div><div class="">As for your idea of the common pages - are you planning on having a app.exe or something like that, sitting in say <a href="http://common.domain.com" class="">http://common.domain.com</a> ?</div><div class=""><br class=""></div><div class="">If so, then you need to either proxy all the requests or iframe them. There is a trick you can do with a referrer, where by you can just redirect the user from the sub.domain to common.domain and capture the referrer, but this sounds ugly….and I am not sure it will be what you want.</div><div class=""><br class=""></div><div class="">The way I am assuming you want to do it is to have 1 VHOST, with a bunch of aliases. This way you have one place where you drop your code. Then you need to look at the VHOST to serve the correct CSS/Logo. You will need to store this somewhere and then work out a way to give it to the client.</div><div class=""><br class=""></div><div class="">I am not sure if you are aware, but Delphi can serve “other” files, as long as the correct content types are set. It’s something like:</div><div class=""><br class=""></div><div class="">headers (“Content-Type: image/png”);</div><div class=""><br class=""></div><div class="">Dump the file to standard out</div><div class=""><br class=""></div><div class="">P.S. My web coding under Delphi is aged - things might have changed a lot by now, but hopefully this will give you some pointers :)</div><div class=""><br class=""></div><div class="">Cheers,</div><div class=""><br class=""></div><div class="">Pieter</div></body></html>