Jump to content

Search the Community

Showing results for tags 'config'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 6 results

  1. I'm trying to convert existing website php code to use config.php on my local server but keep getting the following http 500 error before anything shows on the screen: "This page isn’t working foxtest is currently unable to handle this request." My config directory is within my project directory until I get this working. Here's the contents of config.php: <?php $app_root = DIRNAME(__DIR__); $php_path = $app_root.'config/'; include_once $php_path.'PDO_Connection_Select.php'; include_once $php_path.'GetUserIpAddr.php'; Here's my index.php <?php require_once('config/config.php'); $ip = $php_path.'GetUserIpAddr()'; if (!$pdo = $php_path.'PDOConnect("foxclone_data")') { exit; } $stmt = $pdo->prepare("INSERT INTO access (address) values (?)"); $stmt->execute([$ip]) ; require_once("header.php"); ?> <header class="header"> <div class="header-content"> <div class="text-container"> <div class="header__top" style="text-align:center;">FoxClone</div> <p class="p-small">FoxClone is a image backup, restore, and clone tool for Windows and Linux systems, using a simple point-and-click interface. Being Linux-based, it boots to its own system exclusive of anything on the hard disk drive (HDD) or solid disk drive (SSD), where it takes images of the partitions and stores them for later restoration. The resulting image files can optionally be compressed to save space. .</p> </div> </div> </header> <body> <nav class="navbar" style="background:transparent;"> <div class="navbar-links"> <ul> <li><a href="index.php">Home</a></li> <li><a href="features.php">Features</a></li> <li><a href="legal.php">Legal</a></li> <li><a href="contact.php">Contact</a></li> <li><a href="download.php">Downloads</a></li> </ul> </div> </nav> <header class="header"> <div class="header-content"> <div class="text-container"> <div class="header__top" style="text-align:center;">FoxClone</div> <p class="p-small">FoxClone is a image backup, restore, and clone tool for Windows and Linux systems, using a simple point-and-click interface. Being Linux-based, it boots to its own system exclusive of anything on the hard disk drive (HDD) or solid disk drive (SSD), where it takes images of the partitions and stores them for later restoration. The resulting image files can optionally be compressed to save space. .</p> </div> </div> </header> <?PHP require_once("footer.php"); I know I must be looking past the problem after looking at the code for several hours, but I'm stumped. I'd appreciate some help on this.
  2. can someone help me with my problem configuring mysql? thank you in advance
  3. Please guys help me. I have a site with high traffic. Sometimes over 1k people online. I just got this brand new server because my other server was crashing all the time. I need to configure my.cnf and appache to handle the traffic without issues. Server stats. Dual Intel Xeon 5639 2.13Ghz - 2 Processors 12 Cores / 24 Threads 24GB DDR3 RAM Current My.cnf config: [mysqld] key_buffer=32M myisam_sort_buffer_size=64M join_buffer=2M sort_buffer=2M table_cache=2048 thread_cache_size=512 connect_timeout=60 wait_timeout=500 interactive_timeout=500 max_allowed_packet=16M tmp_table_size=128M max_heap_table_size=128M query_cache_limit = 2M query_cache_size = 512M query_cache_type = 1 #open_files_limit = 20000 thread_concurrency=16 max_connections=1000 log-slow-queries local-infile=0 connect_timeout = 60 Current httpd.conf config <IfModule prefork.c> StartServers 20 MinSpareServers 15 MaxSpareServers 35 ServerLimit 2000 MaxClients 2000 MaxRequestsPerChild 10000 </IfModule> <IfModule worker.c> StartServers 20 MaxClients 2000 ServerLimit 2000 MinSpareThreads 30 MaxSpareThreads 305 ThreadsPerChild 355 MaxRequestsPerChild 10000 </IfModule> Thanks in advance for the help.
  4. I have a HTTP server setup on port 9000. I want to setup a squid proxy server lies before it. After I installed the squid, I just did two changes: acl Safe_ports port 9000 # http acl ppnetwork src 192.168.0.0/24 http_access allow ppnetwork Then, I squid -k parse squid The squid is running. I can see the log from cache.log 2013/09/18 16:25:44 kid1| Store logging disabled 2013/09/18 16:25:44 kid1| Swap maxSize 0 + 262144 KB, estimated 20164 objects 2013/09/18 16:25:44 kid1| Target number of buckets: 1008 2013/09/18 16:25:44 kid1| Using 8192 Store buckets 2013/09/18 16:25:44 kid1| Max Mem size: 262144 KB 2013/09/18 16:25:44 kid1| Max Swap size: 0 KB 2013/09/18 16:25:44 kid1| Using Least Load store dir selection 2013/09/18 16:25:44 kid1| Set Current Directory to /home/xxxxx/squid/var/cache/squid 2013/09/18 16:25:44 kid1| Loaded Icons. 2013/09/18 16:25:44 kid1| HTCP Disabled. 2013/09/18 16:25:44 kid1| Squid plugin modules loaded: 0 2013/09/18 16:25:44 kid1| Accepting HTTP Socket connections at local=0.0.0.0:3128 remote=[::] FD 9 flags=9 2013/09/18 16:25:45 kid1| storeLateRelease: released 0 objects But, if I access the http site like http://mysite:9000, should I supposed to see any contents in the squid access.log? If so, why is my access.log empty? Do I setup the proxy server correctly? Thanks!
  5. I'm trying to proof a comet style page and to start it up I thought I would set a simple counter in PHP to output 0->3 with a one second delay between each output and flush it to screen each second. Problem is nothing I have tried has actualy managed to flush the buffer out. It just sits there with the loading spinner and after 4 seconds dumps the lot onto the screen at once. I have been diging about and have set the nginx config to the following: user www-data; worker_processes 1; error_log /var/log/nginx/error.log; pid /var/run/nginx.pid; events { worker_connections 1024; multi_accept on; } http { include /etc/nginx/mime.types; access_log /var/log/nginx/access.log; sendfile on; tcp_nopush on; #keepalive_timeout 0; keepalive_timeout 65; tcp_nodelay on; #---------------------------------------------- # fastcgi_keep_conn on; proxy_buffering off; gzip off; #---------------------------------------------- gzip_disable "MSIE [1-6]\.(?!.*SV1)"; include /etc/nginx/conf.d/*.conf; include /etc/nginx/sites-enabled/*; } I had to comment out the fastcgi_keep_con on; as this wasn't recognised. The following is the PHP page. <?php ini_set('zlib.output_compression', 'Off'); ini_set('output_handler',""); ini_set('implicit_flush',1); set_time_limit(0); ob_start(); header("Cache-Control: no-cache, must-revalidate"); flush(); ob_flush(); for ($i=0;$i<4;$i++) { echo "$i <br>"; ob_flush(); flush(); sleep(1); } ob_end_clean(); ?> Any ideas what I'm missing here?
  6. Okay, so I have a website. My images are stored in /images. When someone links to an image on my site from somewhere on the web, I want them to be redirected to a file (image.php) that handles redirecting them to a page that shows the image. This way any user linking to one of my images ends up linking the user to my page that contains that image. My problem is that when I implement the following line in my htaccess, internal images - that is to say anchors on all of my pages break. Is there a way to check if a user is on, say index.php and allow images to be linked to, but if a user is just plain trying to view that image without being inside any other file, to make the redirect happen? RewriteRule ^images/([^\s]+(\.(?i)(jpg|png|gif|bmp))$)$ image.php?id=$1 [R=301,NC,L] I have tried everything I've seen online and am out of ideas. There is really only one file that DOES need the image anchors, so I wouldn't be terribly disappointed if the code was just a manual whitelist of files or something of that sort. Thanks in advance!
×
×
  • 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.