Jump to content

apacheguy

Members
  • Content Count

    108
  • Joined

  • Last visited

Community Reputation

0 Neutral

About apacheguy

  • Rank
    Advanced Member

Contact Methods

  • Website URL
    http://eric.praske.com

Profile Information

  • Gender
    Not Telling
  1. Hi all, I recently transitioned to Apache 2.4 from 2.2. I'm looking to take advantage of mod_authz_dbd to replace my Basic Auth scheme I had in place before. Per the docs on this module (http://httpd.apache.org/docs/trunk/mod/mod_authz_dbd.html), I can execute a custom statement to log a user in like this: Trouble is, I want it to log the user IP address. Apache supposedly supports calling ENV VARS from with httpd.conf, but for some reason the following code does not work: It inserts %{REMOTE_ADDR} instead of the actual ip address value. Any idea how I can get this to work?
  2. apacheguy

    Images/Text not scaling to screen width

    Brilliant! I just made a few minor changes to your code, but it is finally where I want it to be. Your code had the images in 1 column with 3 rows, but I wanted that switched to 3 columns and 1 row. Here is the resulting CSS: <style media="screen" type="text/css"> /* <!-- */ body{ margin: auto; width: 100%; padding: auto; } #container{ width: 100%; height: auto; margin: auto; } #grid{ padding: 100px; margin: auto; } .grid-element{ width: 33%; display: inline-block; margin: auto; } a.clickable-div { display: block; height: 100%; width: 100%; text-decoration: none; } .img { height:auto; width:inherit; max-height:50%; max-width:50%; } .button { color: #900; font-weight: bold; font-size: 150%; text-transform: uppercase; display: block; width: 50%; } /* --> */ </style>
  3. Ok, first off CSS is definitely not my strong suit so bear with me here. This is my code: <style media="screen" type="text/css"> /* <!-- */ .clear{ clear:both; } #grid{ width: 100%; } .grid-element{ width:33%; float:left; } a.clickable-div { display: block; height: 100%; width: 100%; text-decoration: none; } .img { height:auto; width:inherit; max-height:100%; max-width:100%; } .button { color: #900; font-weight: bold; font-size: 150%; text-transform: uppercase; display: block; width: 50%; } /* --> */ </style> <div id="grid"><div class="grid-element" align="center"> <img src="images/light_offline.png" class="img"> <p><h1>Hue Lamp 1 </h1></div><div class="grid-element" align="center"> <a href="action.php?light=2&state=false"> <img src="images/light_off.png" class="img"></a> <p><h1>Hue Lamp 2 </h1></div><div class="grid-element" align="center"> <a href="action.php?light=3&state=false"> <img src="images/light_off.png" class="img"></a> <p><h1>Hue Lamp 3 </h1></div></div><p> <div align="center"> <form method="POST" action="action.php"> <input type="hidden" name="scene" value="02b12e930-off-0"> <input type="submit" value="Scene 1" class="button"> </form> <p><form method="POST" action="action.php"> <input type="hidden" name="off"> <input type="submit" value="All Off" class="button"> </form> </div> This is the browser output. A couple things are wrong: 1. Why aren't the images scaling so they are all the same size? I assigned the same CSS class to each of the images but they are all appearing differently. The original images are all the same size. 2. Why are my buttons in the far right corner? I want to have them centered below the images so as to prevent the horizontal scroll bar, which I hate.
×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.