Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Post New Thread Reply

Register GFY Rules Calendar Mark Forums Read
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed.

 
Thread Tools
Old 09-25-2009, 11:45 AM   #1
thagreek
Confirmed User
 
Join Date: Dec 2006
Posts: 463
ATX and lighttpd

Does anyone use ATX with lighttpd?
I cannot make the in.cgi work on the index page because lighttpd does not have virtual() in php.
Has anyone found a way around this?
__________________
ICQ: 335034

For sale: oojz.com / upbot.com / iMarijuana.com / toughmarketing.com / playfulencounter.com (website included)

Misc.: 2x ATX2 licenses ($50 each)

thagreek is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 11:53 AM   #2
hjnet
Confirmed User
 
Join Date: May 2002
Location: European Union
Posts: 3,815
A plain SSI Include doesn't work either?
hjnet is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 11:59 AM   #3
ProG
Confirmed User
 
Join Date: Apr 2009
Posts: 1,319
Maybe this will help

http://redmine.lighttpd.net/wiki/lighttpd/Docs:ModCGI
__________________
History will be kind to me for I intend to write it.
ProG is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 12:13 PM   #4
thagreek
Confirmed User
 
Join Date: Dec 2006
Posts: 463
cgi itself works, it's just the virtual function is missing from php and does not work in ssi.
I really wanted to run lighttpd and I think it's stupid to run apache just for something like this. Either I will have to figure out a work around or move to apache.
__________________
ICQ: 335034

For sale: oojz.com / upbot.com / iMarijuana.com / toughmarketing.com / playfulencounter.com (website included)

Misc.: 2x ATX2 licenses ($50 each)

thagreek is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 12:38 PM   #5
ProG
Confirmed User
 
Join Date: Apr 2009
Posts: 1,319
You could try this..

http://www.modwest.com/help/kb5-212.html
__________________
History will be kind to me for I intend to write it.
ProG is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 12:39 PM   #6
Klen
 
Klen's Avatar
 
Industry Role:
Join Date: Aug 2006
Location: Little Vienna
Posts: 32,235
You can always proxy lighthttpd to apache.
Klen is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 02:38 PM   #7
thagreek
Confirmed User
 
Join Date: Dec 2006
Posts: 463
Quote:
Originally Posted by ProG View Post
Yeah I have found everything like that and tried them all.

Nothing works. It is hard searching for this issue because the only thing that really comes up is lighttpd virtual host issues.

If it's even possible, I will figure it out and when I do I will post for others.

Thanks for the replies.
__________________
ICQ: 335034

For sale: oojz.com / upbot.com / iMarijuana.com / toughmarketing.com / playfulencounter.com (website included)

Misc.: 2x ATX2 licenses ($50 each)

thagreek is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-25-2009, 06:40 PM   #8
thagreek
Confirmed User
 
Join Date: Dec 2006
Posts: 463
<?php
# Change this to the full path of in.cgi
$CGISCRIPT="/full/path/cgi-bin/a2/in.cgi";
putenv('REQUEST_METHOD=GET');
if(isset($_SERVER['QUERY_STRING'])) putenv('QUERY_STRING='.$_SERVER['QUERY_STRING']);
if(isset($_SERVER['HTTP_USER_AGENT'])) putenv('HTTP_USER_AGENT='.$_SERVER['HTTP_USER_AGENT']);
if(isset($_SERVER['HTTP_VIA'])) putenv('HTTP_VIA='.$_SERVER['HTTP_VIA']);
if(isset($_SERVER['HTTP_CACHE_CONTROL'])) putenv('HTTP_CACHE_CONTROL='.$_SERVER['HTTP_CACHE_CONTROL']);
if(isset($_SERVER['HTTP_X_FORWARDED_FOR'])) putenv('HTTP_X_FORWARDED_FOR='.$_SERVER['HTTP_X_FORWARDED_FOR']);
if(isset($_SERVER['HTTP_REFERER'])) putenv('HTTP_REFERER='.$_SERVER['HTTP_REFERER']);
if(isset($_SERVER['HTTP_COOKIE'])) putenv('HTTP_COOKIE='.$_SERVER['HTTP_COOKIE']);
putenv('REMOTE_ADDR='.$_SERVER['REMOTE_ADDR']);
unset($return_array);
exec($CGISCRIPT, $return_array, $return_val);
$firstline=array_shift($return_array);
echo implode($return_array,"\r\n");
?>

Works like a charm now!
__________________
ICQ: 335034

For sale: oojz.com / upbot.com / iMarijuana.com / toughmarketing.com / playfulencounter.com (website included)

Misc.: 2x ATX2 licenses ($50 each)

thagreek is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Old 09-26-2009, 11:35 AM   #9
thagreek
Confirmed User
 
Join Date: Dec 2006
Posts: 463

Here is the vhost part for lighttpd and a site running smart thumbs and atx

var.vhostdir = "/usr/local/www/vhosts"

$SERVER["socket"] == "x.x.x.x:80" {
$HTTP["host"] =~ "(^|\.)domain\.com$" {
alias.url += ( "/cgi-bin" => vhostdir + "/www.domaincom/cgi-bin" )
server.document-root = vhostdir + "/www.domain.com/htdocs"
accesslog.filename = vhostdir + "/www.domain.com/logs/access.log"
server.errorlog = vhostdir + "/www.domain.com/logs/error.log"
$HTTP["host"] =~ "^domain\.com$" {
url.redirect = ( "^/(.*)" => "http://www.domain.com/$1" )
}
auth.backend = "htpasswd"
auth.backend.htpasswd.userfile = vhostdir + "/www.domain.com/htdocs/st/admin/.htpasswd"
auth.require = ( "/st/admin/" =>
(
"method" => "basic",
"realm" => "SmartThumbs admin",
"require" => "valid-user"
)
)
}
}

Since .htaccess doesn't work with lighttpd you will also need to make a index.php in /st/admin/ with this:

<?php header('Location: rotator.php'); ?>

Then instead of putting:

<?php virtual ("/cgi-bin/a2/in.cgi"); ?>

Put this:

<?php
$CGISCRIPT="/usr/local/www/vhosts/www.domain.com/cgi-bin/a2/in.cgi";
putenv('REQUEST_METHOD=GET');
if(isset($_SERVER['QUERY_STRING'])) putenv('QUERY_STRING='.$_SERVER['QUERY_STRING']);
if(isset($_SERVER['HTTP_USER_AGENT'])) putenv('HTTP_USER_AGENT='.$_SERVER['HTTP_USER_AGENT']);
if(isset($_SERVER['HTTP_VIA'])) putenv('HTTP_VIA='.$_SERVER['HTTP_VIA']);
if(isset($_SERVER['HTTP_CACHE_CONTROL'])) putenv('HTTP_CACHE_CONTROL='.$_SERVER['HTTP_CACHE_CONTROL']);
if(isset($_SERVER['HTTP_X_FORWARDED_FOR'])) putenv('HTTP_X_FORWARDED_FOR='.$_SERVER['HTTP_X_FORWARDED_FOR']);
if(isset($_SERVER['HTTP_REFERER'])) putenv('HTTP_REFERER='.$_SERVER['HTTP_REFERER']);
if(isset($_SERVER['HTTP_COOKIE'])) putenv('HTTP_COOKIE='.$_SERVER['HTTP_COOKIE']);
putenv('REMOTE_ADDR='.$_SERVER['REMOTE_ADDR']);
unset($return_array);
exec($CGISCRIPT, $return_array, $return_val);
$firstline=array_shift($return_array);
echo implode($return_array,"\r\n");
?>

Other then these couple of tweaks everything else is the same.

Frank is adding the above php code to the arrow scripts knowledge base.

If anyone wants to use lighttpd and can't get it working, just hit me up on icq and I will help you out.
__________________
ICQ: 335034

For sale: oojz.com / upbot.com / iMarijuana.com / toughmarketing.com / playfulencounter.com (website included)

Misc.: 2x ATX2 licenses ($50 each)

thagreek is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote
Post New Thread Reply
Go Back   GoFuckYourself.com - Adult Webmaster Forum > >

Bookmarks
Thread Tools



Advertising inquiries - marketing at gfy dot com

Contact Admin - Advertise - GFY Rules - Top

©2000-, AI Media Network Inc



Powered by vBulletin
Copyright © 2000- Jelsoft Enterprises Limited.