I have been trialing Amazon's S3 service with the intention of using it to serve images from instead of choking the current web server with multiple image requests. Early tests were encouraging, so I started to think about how I could serve the files on the Amazon S3 storage service.
The...
I am trying to install a PHP Extension.
Have copied the .so file to my extensions dir, added the reference to php.ini and re-booted. I have the following error when I try to execute a test page:
Warning: dl() [function.dl]: mymodule: Unable to initialize module Module compiled with module...
Running phpinfo() on my shared host tells me that Zend Optimizer is supported:
This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies
with the ionCube PHP Loader v3.3.4, Copyright (c) 2002-2009, by ionCube Ltd., and...
My host has PHP compiled as an Apache module.
I am hoping to run the cron.php file every 5 minutes. The file is just a test and sends me an email. That's all.
Either I have specified the wrong path or my syntax is wrong because it is not working.
MAILTO=myemailaddress.com
*/5 * * * *...
I have a .bat file which moves files from one location to another:
move "W:\imagedump\*.jpg" "C:\test\"
When I manually click the .bat file, it works perfectly. When I get VB.NET to run the process, I get a quick DOS box flash and nothing happens. I'm guessing it is a security issue. This...
I have a LINQ query which has multiple inner joins. I've got a feeling that this is not perhaps the most efficient way to acheive my result. I hace a recorset of 16k rows and the query executes in 8-10 seconds.
What can I do to speed it up?
SELECT Stock.CatalogueNo...
I have the string "MYPART0123456789"
I want to search it for the first occurance of a character within the range [0-9], and return everything after that (0123456789).
I have experimented with strstr, but I need to pattern match.
I know the code below won't work, but I can't get any further...
I have a stock table in my database with 20k records.
I'm not experiencing any performance issues.
At this stage, I could split this large table into 3 smaller tables. One for stock, price, and category and simply join them in a query.
Is there a real performance issue leaving one large...
I need to Encrypt a file in PHP and Decrypt in ASP.
This is quite a loaded question, so I just wondered if anyone has any experience doing this or could point me in the right direction.
Using PGP would be a solution, but my PHP host does not allow access to the command line.
I have found an...
Okay, I'm a newbie. Apologies over to everyone who finds arrays easy...
I want to count all the values of an array. I'm using the function array_count_values.
$a = array('apple', 'bannana', 'pear', 'apple');
print_r(array_count_values($a));
// Gives Array ( [apple] => 2 [bannana] => 1...
I have 2 webservers.
Webserver #1 has a file index.php, and I would like to know the last date modified property of the file. Using this code, it is quite simple:
<?
$filename = 'index.php';
if (file_exists($filename)) {
$a = date ("F d Y", filemtime($filename));
echo $a;
}
?>
Works...
I wrote a vb.net 2008 program to upload a file to a web server. It works fine when executed manually, but has issues when scheduled on our Microsoft Small Business Server 2003.
It works for about a week, then just stops working. On the web server, I get a zero-byte file. I think this...
I wrote a vb.net 2008 program to upload a file to a web server. It works fine when executed manually, but has issues when scheduled on our Microsoft Small Business Server 2003.
It works for about a week, then just stops working. On the web server, I get a zero-byte file. I think this...
I'm having dificulty redirecting a dynamic page to a static one using the following in my .htaccess file.
I just get "The requested URL /accessory_header_menu.asp was not found on this server."
RewriteCond %{HTTP_HOST} ^www.mydomain.co.uk
RewriteCond %{QUERY_STRING}...
I have an annoying issue with missing programs in the "Uninstall or change a program" section. Should have 40-50 programs, but only 15 show. Running Win 7 64bit.
Other posts suggest looking in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Winows\CurrentVersion\Uninstall section of the registry and...
I have a database with some null values.
I understand that I should be able to use IS NULL within my query.
SELECT * FROM `mytable` WHERE mycol IS NULL
From within PhpMyAdmin, I get this:
MySQL returned an empty result set (i.e. zero rows).
What am I doing wrong?
The strrchr() function finds the position of the last occurrence of a string within another string, and returns all characters from this position to the end of the string.
My code:
echo strrchr("I am searching for OBSVALUE on my text", "OBSVALUE") . "<br>";
echo strrchr("I am searching for...
This is driving me crazy:
I have a simple form and I'm trying to post back a single character and test it's ASCII code. Although it works for standard characters, special characters such as Ø give an incorrect code. The code should be ASCII 216. I'm getting ASCII 239.
I tried changing my...
I'm trying to output the selected value form a select box and compare it, see code below. If someone selects "Test1", I want the alert box "yes", for every other selection, "no". I'm sure this is simple stuff, but I'm stumped! Can anyone help me?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0...
I'm working on an Ajax live search search facility which uses Mysql Queries. The performance was sluggish, and I found the answer was to close the database connection at the end of the script using the mysql_close() function.
I'm sure it's good practice to close the db connection, but the...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.