If you want to use something that already exists, the secure pages module can do this and any other paths you need secured.<br><br><a href="http://drupal.org/project/securepages">http://drupal.org/project/securepages</a><br>
<br>Blessings<br><br><div class="gmail_quote">On Fri, Jul 31, 2009 at 10:47 AM, Metzler, David <span dir="ltr"><<a href="mailto:metzlerd@evergreen.edu">metzlerd@evergreen.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Expansion on this idea.<br>
<br>
I don't think you'll get setting.php to have $user->uid context will<br>
you? Doesn't it load too early?<br>
<br>
If I'm right, write a module with hook_init (as Earnie says) have it<br>
set cookie then do the base_url based on whether $cookie is site.<br>
<br>
I would at least try contacting secure pages maintainer to see if you<br>
can get a patch submitted there as this seems like a feature that would<br>
be useful to that module.<br>
<br>
Dave<br>
<div><div></div><div class="h5"><br>
<br>
-----Original Message-----<br>
From: <a href="mailto:support-bounces@drupal.org">support-bounces@drupal.org</a> [mailto:<a href="mailto:support-bounces@drupal.org">support-bounces@drupal.org</a>] On<br>
Behalf Of Earnie Boyd<br>
Sent: Friday, July 31, 2009 5:57 AM<br>
To: <a href="mailto:support@drupal.org">support@drupal.org</a><br>
Subject: Re: [support] ssl + login best practice<br>
<br>
Quoting Geoff O'Callaghan <<a href="mailto:geoffocallaghan@gmail.com">geoffocallaghan@gmail.com</a>>:<br>
<br>
> Hi All,<br>
><br>
> Running D6. What's the best practice for setting up a site where<br>
> content is delivered by http *until* the user logs on and from then on<br>
<br>
> I want all content to be via https.<br>
><br>
<br>
Ideas only here; none of them tested. A hook_init in a custom module.<br>
Some code in settings.php to modify the $base_url if the $user->uid !=<br>
0. A mod_rewrite pattern and rule.<br>
<br>
--<br>
Earnie<br>
-- <a href="http://r-feed.com/" target="_blank">http://r-feed.com/</a> -- <a href="http://for-my-kids.com/" target="_blank">http://for-my-kids.com/</a><br>
-- <a href="http://www.4offer.biz/" target="_blank">http://www.4offer.biz/</a> -- <a href="http://give-me-an-offer.com/" target="_blank">http://give-me-an-offer.com/</a><br>
<br>
<br>
--<br>
[ Drupal support list | <a href="http://lists.drupal.org/" target="_blank">http://lists.drupal.org/</a> ]<br>
--<br>
[ Drupal support list | <a href="http://lists.drupal.org/" target="_blank">http://lists.drupal.org/</a> ]<br>
</div></div></blockquote></div><br>