Jump to content


Corporate Sponsors


Latest News: (loading..)

Biancoblu

Member Since 11 Mar 2006
Offline Last Active Yesterday, 09:45
*****

Topics I've Started

How to serve a 404 for pages that do not exist and contain index.php?

25 March 2012, 14:25

Hi,

I'm trying to get non existent pages that contain index.php to serve a 404.

Example: I want http://www.mysite.com/index.php/typo to give a 404 file not found. Right now a page like that just redirects to the home page, the outcome is that non existent pages have started showing in search engines results.

Currently I can only serve a 404 for non existent pages WITHOUT index.php: for example: http://www.mysite.com/typo gives a 404.
I have placed
ErrorDocument 404 /404.php
in htacces.

Based on the above I tried
ErrorDocument index.php/404 /404.php
but I am given an internal server error.

Any help appreciated.
Thanks

Isabella

blank admin login page after server move, admin completely inaccessible

12 February 2012, 17:48

I have read countless threads on this issue but none solve my problem.

After a server move I got locked out of shop admin. I emptied admin/.htaccess and admin/.htpasswd_oscommerce. I truncated the administrators table in phpMyadmin. I also emptied the sessions table in phpMyadmin.

All I get is a blank screen when I try my shop's admin.

Any help appreciated :unsure:

Thanks
Isabella

crawl-delay directive in robots.txt

28 January 2012, 17:29

I'm using version 2.3.1 and i'm on a shared server.

Recently I've noticed a huge traffic peak on my site around 2am server time, so much so that eventually I get this error:

Quote

PHP Warning: mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Too many connections in /home/username/public_html/includes/functions/database.php on line 19

Looking at my logs I notice this happens when the Google Bot and Yandex Bot are crawling my site.
Is it a good idea to add the crawl-delay directive to robots.txt? I read a lot of conflicting info on the net.

Or is the "too many connections" error indicative of the server being too overcrowded thus not being able to cope at certain times?

Thanks
Isabella

Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock...

19 January 2012, 10:02

Quote

PHP Warning: mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /home/username/public_html/includes/functions/database.php on line 19


I see this error frequently in my error log, my host tells me that when they restore somebody's database they have to restart the MySQL service on the server which causes that error and a brief outage.

I don't know much about how servers function, is it normal that they restart MySQL each time they restore a client's DB? I am on a shared server.

Thanks
Isabella

Can't connect to local MySQL server through socket

27 August 2011, 09:34

I've had this error on my site, on and off, for the last few months, without my changing anything. I confirm that I do not use persistent connections, and that my username and pw are correct, as well as my configure files.

I have spoken to host at length about it, they say this error happens during server restarts and that it typically goes unnoticed as it lasts for just seconds. Last time though it lasted for 20 minutes during which time my site was down.

I wonder if someone has an idea on what to do to possibly fix it?

Any advice welcome.

Quote

[26-Aug-2011 08:39:31] PHP Warning: mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /home/username/public_html/includes/functions/database.php on line 19