Jump to content

CrazeD

Members
  • Posts

    136
  • Joined

  • Last visited

    Never

Everything posted by CrazeD

  1. It is in your php.ini file.
  2. THANK YOU!!! You were right, I had MultiViews in my sites-available/default, so I took them out and it worked right away. Thanks a bunch. And yes that page include was only to test my .htaccess, of course.
  3. I think the issue may lie in the fact that this is my first Linux server that I've managed. I'm sure I'm doing some noobie thing wrong. :/ I have other Windows installations and I tested my .htaccess and it works every time there. I just can't figure it out...sigh. All my conf's match that of the Windows, and I've done everything based on guides on the net. :cryface:
  4. No difference. I just don't understand how it can work once but not twice. :/ Also, just to note, I uploaded my uncompleted project (the one that works) to my webserver just to test the implementation, and it works perfectly there too. So I'm guessing it has something to do with my server setup.
  5. No, because it only behaves this way if the .htaccess file is present. If I get rid of it, my PHP works just fine. I will post my apache2.conf though just so you can check it. # # Based upon the NCSA server configuration files originally by Rob McCool. # # This is the main Apache server configuration file. It contains the # configuration directives that give the server its instructions. # See http://httpd.apache.org/docs/2.2/ for detailed information about # the directives. # # Do NOT simply read the instructions in here without understanding # what they do. They're here only as hints or reminders. If you are unsure # consult the online docs. You have been warned. # # The configuration directives are grouped into three basic sections: # 1. Directives that control the operation of the Apache server process as a # whole (the 'global environment'). # 2. Directives that define the parameters of the 'main' or 'default' server, # which responds to requests that aren't handled by a virtual host. # These directives also provide default values for the settings # of all virtual hosts. # 3. Settings for virtual hosts, which allow Web requests to be sent to # different IP addresses or hostnames and have them handled by the # same Apache server process. # # Configuration and logfile names: If the filenames you specify for many # of the server's control files begin with "/" (or "drive:/" for Win32), the # server will use that explicit path. If the filenames do *not* begin # with "/", the value of ServerRoot is prepended -- so "/var/log/apache2/foo.log" # with ServerRoot set to "" will be interpreted by the # server as "//var/log/apache2/foo.log". # ### Section 1: Global Environment # # The directives in this section affect the overall operation of Apache, # such as the number of concurrent requests it can handle or where it # can find its configuration files. # # # ServerRoot: The top of the directory tree under which the server's # configuration, error, and log files are kept. # # NOTE! If you intend to place this on an NFS (or otherwise network) # mounted filesystem then please read the LockFile documentation (available # at <URL:http://httpd.apache.org/docs-2.1/mod/mpm_common.html#lockfile>); # you will save yourself a lot of trouble. # # Do NOT add a slash at the end of the directory path. # ServerRoot "/etc/apache2" # # The accept serialization lock file MUST BE STORED ON A LOCAL DISK. # #<IfModule !mpm_winnt.c> #<IfModule !mpm_netware.c> LockFile /var/lock/apache2/accept.lock #</IfModule> #</IfModule> # # PidFile: The file in which the server should record its process # identification number when it starts. # This needs to be set in /etc/apache2/envvars # PidFile ${APACHE_PID_FILE} # # Timeout: The number of seconds before receives and sends time out. # Timeout 300 # # KeepAlive: Whether or not to allow persistent connections (more than # one request per connection). Set to "Off" to deactivate. # KeepAlive On # # MaxKeepAliveRequests: The maximum number of requests to allow # during a persistent connection. Set to 0 to allow an unlimited amount. # We recommend you leave this number high, for maximum performance. # MaxKeepAliveRequests 100 # # KeepAliveTimeout: Number of seconds to wait for the next request from the # same client on the same connection. # KeepAliveTimeout 15 ## ## Server-Pool Size Regulation (MPM specific) ## # prefork MPM # StartServers: number of server processes to start # MinSpareServers: minimum number of server processes which are kept spare # MaxSpareServers: maximum number of server processes which are kept spare # MaxClients: maximum number of server processes allowed to start # MaxRequestsPerChild: maximum number of requests a server process serves <IfModule mpm_prefork_module> StartServers 5 MinSpareServers 5 MaxSpareServers 10 MaxClients 150 MaxRequestsPerChild 0 </IfModule> # worker MPM # StartServers: initial number of server processes to start # MaxClients: maximum number of simultaneous client connections # MinSpareThreads: minimum number of worker threads which are kept spare # MaxSpareThreads: maximum number of worker threads which are kept spare # ThreadsPerChild: constant number of worker threads in each server process # MaxRequestsPerChild: maximum number of requests a server process serves <IfModule mpm_worker_module> StartServers 2 MinSpareThreads 25 MaxSpareThreads 75 ThreadLimit 64 ThreadsPerChild 25 MaxClients 150 MaxRequestsPerChild 0 </IfModule> # event MPM # StartServers: initial number of server processes to start # MaxClients: maximum number of simultaneous client connections # MinSpareThreads: minimum number of worker threads which are kept spare # MaxSpareThreads: maximum number of worker threads which are kept spare # ThreadsPerChild: constant number of worker threads in each server process # MaxRequestsPerChild: maximum number of requests a server process serves <IfModule mpm_event_module> StartServers 2 MaxClients 150 MinSpareThreads 25 MaxSpareThreads 75 ThreadLimit 64 ThreadsPerChild 25 MaxRequestsPerChild 0 </IfModule> # These need to be set in /etc/apache2/envvars User ${APACHE_RUN_USER} Group ${APACHE_RUN_GROUP} # # AccessFileName: The name of the file to look for in each directory # for additional configuration directives. See also the AllowOverride # directive. # AccessFileName .htaccess # # The following lines prevent .htaccess and .htpasswd files from being # viewed by Web clients. # <Files ~ "^\.ht"> Order allow,deny Deny from all </Files> # # DefaultType is the default MIME type the server will use for a document # if it cannot otherwise determine one, such as from filename extensions. # If your server contains mostly text or HTML documents, "text/plain" is # a good value. If most of your content is binary, such as applications # or images, you may want to use "application/octet-stream" instead to # keep browsers from trying to display binary files as though they are # text. # DefaultType text/plain # # HostnameLookups: Log the names of clients or just their IP addresses # e.g., www.apache.org (on) or 204.62.129.132 (off). # The default is off because it'd be overall better for the net if people # had to knowingly turn this feature on, since enabling it means that # each client request will result in AT LEAST one lookup request to the # nameserver. # HostnameLookups Off # ErrorLog: The location of the error log file. # If you do not specify an ErrorLog directive within a <VirtualHost> # container, error messages relating to that virtual host will be # logged here. If you *do* define an error logfile for a <VirtualHost> # container, that host's errors will be logged there and not here. # ErrorLog /var/log/apache2/error.log # # LogLevel: Control the number of messages logged to the error_log. # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. # LogLevel warn # Include module configuration: Include /etc/apache2/mods-enabled/*.load Include /etc/apache2/mods-enabled/*.conf # Include all the user configurations: Include /etc/apache2/httpd.conf # Include ports listing Include /etc/apache2/ports.conf # # The following directives define some format nicknames for use with # a CustomLog directive (see below). # If you are behind a reverse proxy, you might want to change %h into %{X-Forwarded-For}i # LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined LogFormat "%h %l %u %t \"%r\" %>s %O" common LogFormat "%{Referer}i -> %U" referer LogFormat "%{User-agent}i" agent # # Define an access log for VirtualHosts that don't define their own logfile CustomLog /var/log/apache2/other_vhosts_access.log vhost_combined # Include of directories ignores editors' and dpkg's backup files, # see README.Debian for details. # Include generic snippets of statements Include /etc/apache2/conf.d/ # Include the virtual host configurations: Include /etc/apache2/sites-enabled/ And my sites-available/default: <VirtualHost *:80> ServerAdmin webmaster@localhost DocumentRoot /var/www <Directory /> Options FollowSymLinks AllowOverride All </Directory> <Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all </Directory> ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/ <Directory "/usr/lib/cgi-bin"> AllowOverride All Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch Order allow,deny Allow from all </Directory> ErrorLog /var/log/apache2/error.log # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. LogLevel warn CustomLog /var/log/apache2/access.log combined Alias /doc/ "/usr/share/doc/" <Directory "/usr/share/doc/"> Options Indexes MultiViews FollowSymLinks AllowOverride All Order deny,allow Deny from all Allow from 127.0.0.0/255.0.0.0 ::1/128 </Directory> </VirtualHost>
  6. The file is located on the same server. I'm running Apache2 on Ubuntu 9.10. The one that works is setup like www/project/folder/.htaccess, index.php The one that doesn't work is setup like www/project2/.htaccess, index.php They both are the exact same file. With the same code in index.php. Both implementations have the same file permissions. index.php and .htaccess are 0777. Also, if the page I'm requesting contains PHP, it tries to download it. I hate stupid problems...
  7. So I have a mod_rewrite script that takes urls such as: site.com/page, and requests them as such: index.php?url=page. I then process that and include the page. It works perfectly. So I start another project, and like how it works, so I want to reuse it. Now it doesn't work. I completely replicated the way I did it the first time, but it doesn't work. Instead of going through index.php it just goes directly to page. I don't really understand how something works once, and then doesn't work again. <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ index.php?url=$1 [PT,L] </IfModule> $url = $_GET['url']; include ($url.'.php'); This is my test code to include the page. Pulling my hair out here. I've tried to recreate my successful script several times, even copying it line-by-line and I can't make it work again...
  8. Why is the center going all batshit when it drops below the side blocks?
  9. Okay, I'm starting to get really pissed off. http://i13.photobucket.com/albums/a283/crazed_rider/fluidproblem4.jpg Why is this happening? <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title> Stu Nicholls | CSSplay | Flexible equal height 3 columns </title> <meta name="Author" content="Stu Nicholls" /> <meta name="Keywords" content="style, cascading, sheets, Experiments, code, CSSplay, Stu, Nicholls, demonstrations, menus, layouts, flexible, multi-column, equal height" /> <meta name="Description" content="CSS only flexible widths with equal height columns" /> <meta http-equiv="imagetoolbar" content="no" /> <style type="text/css"> /* kill defaults */ html, body, ul, dl, li, h1, h2, h3, h4, img { margin: 0; padding: 0; } ul { list-style: none; } img { border: 0; } /* ============= */ body {font-size:76%; font-family:"trebuchet MS", verdana, arial, sans-serif; background:#f0f0f0; word-wrap:break-word;} #header {background:#a31e39;} #outer1 {float:left; width:184px; padding:5px 10px 20px 25px; background:#272727;} #outer3 {float:right; width:184px; padding:5px 25px 20px 10px; background:#272727;} #outer2 {background:#272727; padding:5px 10px 10px 20px; } #outer1, #outer2, #outer3 {padding-bottom:32767px; margin-bottom:-32767px;} #wrapper {overflow:hidden; background:#272727;} #footer {clear:both; background:#455c5a;} .content {padding:10px;} h1 {font-size:20px; margin:0; padding:10px 0; color:#fff;} h3 {font-size:18px; margin:0; padding:8px 0;} p {font-size:12px; line-height:1.5em; margin:0; padding:5px 0;} #footer p, #header p {color:#fff;} #footer a {color:#fff;} #footer a:hover {text-decoration:none;} #borderleft, #borderright { width:24px; background:url(images/borderleft.gif) repeat-y right; position:absolute; height:auto !important; min-height:100%; } #borderright { background:url(images/borderright.gif) repeat-y left; right:0px; } #banner-wrapper { background:url(images/banner_middle.gif) repeat-x; width:100%; height:118px; } #banner-left { background:url(images/banner_left.gif) no-repeat; width:246px; height:118px; float:left; } #banner-right { background:url(images/banner_right.gif) no-repeat; width:279px; height:118px; float:right; } .block-left-header { background:url(images/block_left_header.gif) no-repeat; width:184px; height:48px; } .block-left-body { background:url(images/block_left_body.gif) repeat-y; width:184px; min-height:158px; } .block-left-footer { background:url(images/block_left_footer.gif) no-repeat; width:184px; height:50px; } .block-middle-header-lc { background:url(images/block_middle_header_lc.gif) no-repeat; width:25px; height:48px; float:left; } .block-middle-header-c { background:url(images/block_middle_header_c.gif) repeat-x; height:48px; } .block-middle-header-rc { background:url(images/block_middle_header_rc.gif) no-repeat; width:25px; height:48px; float:right; } .block-middle-body-l { background:url(images/block_middle_body_l.gif) no-repeat; width:25px; min-height:158px; float:left; } .block-middle-body-c { background:#323232; min-height:158px; } .block-middle-body-r { background:url(images/block_middle_body_r.gif) no-repeat; width:25px; min-height:158px; float:right; } .block-middle-footer-lc { background:url(images/block_middle_footer_lc.gif) no-repeat; width:25px; height:50px; float:left; } .block-middle-footer-c { background:url(images/block_middle_footer_c.gif) left repeat-x; height:50px; } .block-middle-footer-rc { background:url(images/block_middle_footer_rc.gif) repeat-x; width:25px; height:50px; float:right; } .block-right-header { background:url(images/block_right_header.gif) no-repeat; width:184px; height:48px; } .block-right-body { background:url(images/block_right_body.gif) repeat-y; width:184px; min-height:158px; } .block-right-footer { background:url(images/block_right_footer.gif) no-repeat; width:184px; height:50px; } </style> <!--[if lte IE 7]> <style type="text/css"> body {word-wrap:break-word;} #outer2 {float:left; display:inline; margin-left:10px; margin-right:10px;} #wrapper {display:inline-block;} </style> <![endif]--> </head> <body><div id="borderleft"></div> <div id="borderright"></div> <div id="banner-wrapper"> <div id="banner-left"></div> <div id="banner-right"></div> </div> <div id="wrapper"> <div id="outer1"> <div class="block-left-header"></div> <div class="block-left-body"></div> <div class="block-left-footer"></div> </div> <div id="outer3"> <div class="block-right-header"></div> <div class="block-right-body"></div> <div class="block-right-footer"></div> </div> <!-- end outer3 --> <div id="outer2"> <div class="block-middle-header-lc"></div> <div class="block-middle-header-rc"></div> <div class="block-middle-header-c"></div> <div class="block-middle-body-l"></div> <div class="block-middle-body-r"></div> <div class="block-middle-body-c"> <div class="content"> blah<br />blah<br />blahblah<br />blah<br />blahblah<br />blah<br />blahblah<br />blah<br />blahblah<br />blah<br />blahblah<br />blah<br /> </div> </div> <div class="block-middle-footer-lc"></div> <div class="block-middle-footer-rc"></div> <div class="block-middle-footer-c"></div> </div> <!-- end outer2 --> </div><!-- end #wrapper --> <div id="footer"> <div class="content"> <p>Copyright ©2009 stu nicholls - cssplay.co.uk | <a href="http://www.cssplay.co.uk/comments/comments.php?comment_id=Flexible%203Cols" accesskey="C" title="Comments for this Layout">comments on these layouts</a></p> <form action="https://www.paypal.com/cgi-bin/webscr" method="post"> <div> <input type="hidden" name="cmd" value="_s-xclick" /> <input type="hidden" name="hosted_button_id" value="2928152" /> <input type="image" src="http://www.cssplay.co.uk/graphic/paypal.png" name="submit" alt="" /> <img alt="" src="https://www.paypal.com/en_GB/i/scr/pixel.gif" width="1" height="1" /> </div> </form> </div> </div> <!-- end footer --> </body> </html>
  10. Using haku's link, where do I put this huge padding and margin? I put it on "col2" and it did nothing.
  11. Using the holy grail thing, I can't make the left and right columns be 100%. They only span to the size of the content. This makes an issue because my border doesn't span the whole height.
  12. Nope, not getting paid... this is for friends. But that's okay, I didn't expect anyone to code it for me. If it wasn't a full width layout I'd be all set... I was never much good at full width.
  13. Yeah, but I haven't had a chance to dig into it yet. I was hoping this would be an easy fix and I'd be all set, hehe.
  14. But I want that div to stay 100% between the blocks.
  15. That didn't work. It just dropped the content entirely below the blocks, but it still remained full width.
  16. Ah, I forgot about that trick. That worked. However, I still have an issue. If I have content that stretches the middle div downward, after it clears the two side blocks it expands all the way. How do I fix this? Screenshot: http://i13.photobucket.com/albums/a283/crazed_rider/fluidproblem3.jpg Demo: http://crazedizzled.com/demo/bom/index.php Files: http://crazedizzled.com/demo/bom/bom.rar Thanks. EDIT: Forgot code... CSS: /* kill defaults */ html, body, ul, dl, li, h1, h2, h3, h4, img { margin: 0; padding: 0; } ul { list-style: none; } img { border: 0; } /* ============= */ html { height:100%; } body { background:#272727; } #container { width:100%; background:#272727; height:auto !important; height:100%; min-height:100%; overflow:auto; } #banner-wrapper { background:url(images/banner_middle.gif) repeat-x; width:100%; height:118px; } #banner-left { background:url(images/banner_left.gif) no-repeat; width:246px; height:118px; float:left; } #banner-right { background:url(images/banner_right.gif) no-repeat; width:279px; height:118px; float:right; } #borderleft, #borderright { width:24px; background:url(images/borderleft.gif) repeat-y right; position:absolute; height:auto !important; height:100%; min-height:100%; } #borderright { background:url(images/borderright.gif) repeat-y left; right:0px; } #mid-wrapper { margin:5px 30px 5px 30px; } #left-column { width:184px; height:100%; min-height:100%; float:left; } #middle-column { height:100%; min-height:100%; width:100%; } #right-column { width:184px; height:100%; min-height:100%; float:right; } .block-left-header { background:url(images/block_left_header.gif) no-repeat; width:184px; height:48px; } .block-left-body { background:url(images/block_left_body.gif) repeat-y; width:184px; min-height:158px; } .block-left-footer { background:url(images/block_left_footer.gif) no-repeat; width:184px; height:50px; } .block-middle-header-lc { background:url(images/block_middle_header_lc.gif) no-repeat; width:25px; height:48px; float:left; } .block-middle-header-c { background:url(images/block_middle_header_c.gif) repeat-x; width:100%; min-width:100%; height:48px; } .block-middle-header-rc { background:url(images/block_middle_header_rc.gif) no-repeat; width:25px; height:48px; float:right; } .block-middle-body-l { background:url(images/block_middle_body_l.gif) no-repeat; width:25px; min-height:158px; float:left; } .block-middle-body-c { background:#323232; width:100%; min-height:158px; } .block-middle-body-r { background:url(images/block_middle_body_r.gif) no-repeat; width:25px; min-height:158px; float:right; } .block-middle-footer-lc { background:url(images/block_middle_footer_lc.gif) no-repeat; width:25px; height:50px; float:left; } .block-middle-footer-c { background:url(images/block_middle_footer_c.gif) repeat-x; width:100%; height:50px; } .block-middle-footer-rc { background:url(images/block_middle_footer_rc.gif) repeat-x; width:25px; height:50px; float:right; } .block-right-header { background:url(images/block_right_header.gif) no-repeat; width:184px; height:48px; } .block-right-body { background:url(images/block_right_body.gif) repeat-y; width:184px; min-height:158px; } .block-right-footer { background:url(images/block_right_footer.gif) no-repeat; width:184px; height:50px; } .content { color:#fff; font-family:"Lucida Sans",Verdana,Arial,Serif; font-size:10pt; } HTML: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>[band of Misfits]</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <div id="banner-wrapper"> <div id="banner-left"></div> <div id="banner-right"></div> </div> <div id="container"> <div id="borderleft"></div> <div id="borderright"></div> <div id="mid-wrapper"> <div id="left-column"> <div class="block-left-header"></div> <div class="block-left-body"></div> <div class="block-left-footer"></div> </div> <div id="right-column"> <div class="block-right-header"></div> <div class="block-right-body"></div> <div class="block-right-footer"></div> </div> <div id="middle-column"> <div class="block-middle-header-lc"></div> <div class="block-middle-header-rc"></div> <div class="block-middle-header-c"></div> <div class="block-middle-body-l"></div> <div class="block-middle-body-r"></div> <div class="block-middle-body-c"> <div class="content"> <div style="height:500px;border:1px solid #fff;width:300px;">asdf</div> </div> </div> <div class="block-middle-footer-lc"></div> <div class="block-middle-footer-rc"></div> <div class="block-middle-footer-c"></div> </div> </div> </div> </body> </html>
  17. Demo: http://crazedizzled.com/demo/bom/index.php Files: http://crazedizzled.com/demo/bom/bom.rar Thanks.
  18. Bump. Please help, I need to get this done soon.
  19. Well I managed to get the middle header to fit beside the left block. However, I cannot get the right corner or right block to go to the right of the header. It drops below it. Picture: http://i13.photobucket.com/albums/a283/crazed_rider/fluidproblem2.jpg CSS: /* kill defaults */ html, body, ul, dl, li, h1, h2, h3, h4, img { margin: 0; padding: 0; } ul { list-style: none; } img { border: 0; } /* ============= */ html { height:100%; } body { background:#272727; } #container { width:100%; background:#272727; height:auto !important; height:100%; min-height:100%; overflow:auto; } #banner-wrapper { background:url(images/banner_middle.gif) repeat-x; width:100%; height:118px; } #banner-left { background:url(images/banner_left.gif) no-repeat; width:246px; height:118px; float:left; } #banner-right { background:url(images/banner_right.gif) no-repeat; width:279px; height:118px; float:right; } #borderleft, #borderright { width:24px; background:url(images/borderleft.gif) repeat-y right; position:absolute; height:auto !important; height:100%; min-height:100%; } #borderright { background:url(images/borderright.gif) repeat-y left; right:0px; } #mid-wrapper { margin:5px 30px 5px 30px; } #left-column { width:184px; height:100%; min-height:100%; float:left; } #middle-column { height:100%; min-height:100%; width:100%; } #right-column { width:184px; height:100%; min-height:100%; float:right; } .block-left-header { background:url(images/block_left_header.gif) no-repeat; width:184px; height:48px; } .block-left-body { background:url(images/block_left_body.gif) repeat-y; width:184px; min-height:158px; } .block-left-footer { background:url(images/block_left_footer.gif) no-repeat; width:184px; height:50px; } .block-middle-header-lc { background:url(images/block_middle_header_lc.gif) no-repeat; width:25px; height:48px; float:left; } .block-middle-header-c { background:url(images/block_middle_header_c.gif) repeat-x; width:100%; min-width:100%; height:48px; } .block-middle-header-rc { background:url(images/block_middle_header_rc.gif) no-repeat; width:25px; height:48px; float:right; } .block-right-header { background:url(images/block_right_header.gif) no-repeat; width:184px; height:48px; } .block-right-body { background:url(images/block_right_body.gif) repeat-y; width:184px; min-height:158px; } .block-right-footer { background:url(images/block_right_footer.gif) no-repeat; width:184px; height:50px; } HTML: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>[band of Misfits]</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <div id="banner-wrapper"> <div id="banner-left"></div> <div id="banner-right"></div> </div> <div id="container"> <div id="borderleft"></div> <div id="borderright"></div> <div id="mid-wrapper"> <div id="left-column"> <div class="block-left-header"></div> <div class="block-left-body"></div> <div class="block-left-footer"></div> </div> <div id="middle-column"> <div class="block-middle-header-lc"></div> <div class="block-middle-header-c"></div> <div class="block-middle-header-rc"></div> </div> <div id="right-column"> <div class="block-right-header"></div> <div class="block-right-body"></div> <div class="block-right-footer"></div> </div> </div> </div> </body> </html> Thanks.
  20. I hate full-width fluid designs, but the client insists...so... I guess I have to. Grr. Ok so, for some reason I can't make this very simple problem work. I have a full-width 3 column layout. Static left and right blocks, with a fluid middle block. The middle block is 3 pieces, a left corner, the middle part that stretches, and a right corner. My problem is that I can't make the middle be 100%, because then it drops between the side blocks and between the left and right corners. Here is a picture to illustrate: http://i13.photobucket.com/albums/a283/crazed_rider/fluidproblem.jpg CSS: /* kill defaults */ html, body, ul, dl, li, h1, h2, h3, h4, img { margin: 0; padding: 0; } ul { list-style: none; } img { border: 0; } /* ============= */ html { height:100%; } body { background:#272727; } #container { width:100%; background:#272727; height:auto !important; height:100%; min-height:100%; overflow:auto; } #banner-wrapper { background:url(images/banner_middle.gif) repeat-x; width:100%; height:118px; } #banner-left { background:url(images/banner_left.gif) no-repeat; width:246px; height:118px; float:left; } #banner-right { background:url(images/banner_right.gif) no-repeat; width:279px; height:118px; float:right; } #borderleft, #borderright { width:24px; background:url(images/borderleft.gif) repeat-y right; position:absolute; height:auto !important; height:100%; min-height:100%; } #borderright { background:url(images/borderright.gif) repeat-y left; right:0px; } #mid-wrapper { margin:5px 30px 5px 30px; } #left-column { width:184px; height:100%; min-height:100%; float:left; } #middle-column { height:100%; min-height:100%; float:left; width:100%; } #right-column { width:100%; height:100%; min-height:100%; float:left; } .block-left-header { background:url(images/block_left_header.gif) no-repeat; width:184px; height:48px; } .block-left-body { background:url(images/block_left_body.gif) repeat-y; width:184px; min-height:158px; } .block-left-footer { background:url(images/block_left_footer.gif) no-repeat; width:184px; height:50px; } .block-middle-header-lc { background:url(images/block_middle_header_lc.gif) no-repeat; width:25px; height:48px; float:left; } .block-middle-header-c { background:url(images/block_middle_header_c.gif) repeat-x; width:100%; min-width:100%; height:48px; float:left; } .block-middle-header-rc { background:url(images/block_middle_header_rc.gif) no-repeat; width:25px; height:48px; float:left; } HTML: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>[band of Misfits]</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <div id="banner-wrapper"> <div id="banner-left"></div> <div id="banner-right"></div> </div> <div id="container"> <div id="borderleft"></div> <div id="borderright"></div> <div id="mid-wrapper"> <div id="left-column"> <div class="block-left-header"></div> <div class="block-left-body"></div> <div class="block-left-footer"></div> </div> <div id="middle-column"> <div class="block-middle-header-lc"></div> <div class="block-middle-header-c"></div> <div class="block-middle-header-rc"></div> </div> </div> </div> </body> </html> Please help, I gotta get this done ASAP. Thanks.
  21. I am working on some custom forums and I'm a little stuck with this one. I can't really think of a logical way to handle how the forum dictates whether a post/reply is new to that user or not. I have tried to paw through different forum software to see how they handled the problem, but quickly grew impatient searching the dozens of files. I sort of found a couple ways, though. One was to just make all replies within a certain time frame new to everybody even if they have read it, I don't really like that option. Another is to use a database row to store viewed post ID's and then match against it and if it's not found, it must be new. The problem I see with this is that the row will quickly grow very large and I'm a little worried about performance issues once there are a lot of active users and a lot of posts. What would you guys suggest I do? Also, for the record (not sure if this is relevant information) my sessions are held in a database table. Thanks!
  22. I've been struggling with this for a while now. I can't seem to get MySQL to work with Perl on my Windows box. I get an Internal 500 error, and my log says: [Thu Apr 02 04:06:10 2009] [error] [client 192.168.0.30] Premature end of script headers: test.pl [Thu Apr 02 04:06:10 2009] [error] [client 192.168.0.30] Can't locate Mysql.pm in @INC (@INC contains: C:/WEB/PERL/site/lib C:/WEB/PERL/lib .) at C:/WEB/public_html/test.pl line 3.\r [Thu Apr 02 04:06:10 2009] [error] [client 192.168.0.30] BEGIN failed--compilation aborted at C:/WEB/public_html/test.pl line 3.\r Configuration: Windows XP SP2 Apache 2.0.63 ActiveState Perl 5.8.8 Build 822 DBD-Mysql 4.005 At first I couldn't even find the DBD-Mysql file, but I finally found a repository that had it and installed it with PPM. It says version 4.005 is installed, and it can verify it. My Perl script: #!C:\WEB\PERL\bin\perl.exe use Mysql; print "Content-type: text/html\n\n"; $host = 'localhost'; $user = 'root'; $pass = 'root'; $dbname = 'test'; $db = Mysql->connect($host,$dbname,$user,$pass); if ($db) { print "works..."; } So, what am I doing wrong?
  23. Aha! I knew there was a much easier way! Thanks a ton.
  24. I'm making a bar review site for a client, and he wants an advanced bar search feature. He wants to search by name, zipcode, city, music, music genre, and bar type. He wants only the results that match all the criteria to be returned. IE: If name, zipcode, and music are selected, only the results that return true for all three values will be returned. I'm having trouble matching the results from the search criteria. My code is very long and repetitive (you'll see why in a minute) so rather than posting it all, I'll paraphrase it. I don't have an error in my code, but rather in my logic. Right now, I have each option running its own SQL and then making an array with the bar ID's it finds. Then, I do an if statement to see if the array containing the ID's returned by the name array is empty. If not, I then do if statements to see if the rest of the options are empty and then do if statements to see if the contents of the other option's arrays are in the name array. If the name array is empty, I go to the next criteria and repeat this until all the options are covered. This is probably extremely confusing so I'll post the first if so you get the idea. if (!empty ($nameBarsID)) { if (!empty ($zipcodeBarsID) || !empty ($cityBarsID) || !empty ($typeBarsID) || !empty ($musicBarsID) || (!empty ($musicBarsID) && !empty ($genreBarsID))) { if (!empty ($zipcodeBarsID)) { foreach ($zipcodeBarsID as $val) { if (in_array ($val,$nameBarsID)) { $barsID[] = $val; } } } if (!empty ($cityBarsID)) { foreach ($cityBarsID as $val) { if (in_array ($val,$nameBarsID)) { $barsID[] = $val; } } } if (!empty ($typeBarsID)) { foreach ($typeBarsID as $val) { if (in_array ($val,$nameBarsID)) { $barsID[] = $val; } } } if (!empty ($musicBarsID)) { foreach ($musicBarsID as $val) { if (in_array ($val,$nameBarsID)) { $barsID[] = $val; } } } if (!empty ($musicBarsID) && !empty ($genreBarsID)) { foreach ($genreBarsID as $val) { if (in_array ($val,$nameBarsID)) { $barsID[] = $val; } } } } else { foreach ($nameBarsID as $val) { $barsID[] = $val; } } } elseif (!empty ($zipcodeBarsID)) { // and so on until all options are covered Now at first I thought it worked alright, but then I realized that I'm only comparing each array to the beginning array, and not with each other. So, if I search by name, zipcode, and music, I'm only returning rows that have matching zipcode, and matching music, but not matching zipcode AND matching music (in the same row). So, without making my code 5000 lines long, how can I accomplish this in an easier way? Sorry if this is really confusing, I explained it as best I could. Thanks.
×
×
  • Create New...

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.