ecommerce website design Shropshire, Custom & Ecommerce Website Designers, Web Page Design Company Shropshire UK Site Map
Phone:01743 272 609 Fax: 0709 286 1166
Home page, website design service at Shrewsbury, Shropshire. We supply website design service to business in Shropshire and whole UKAbout spark computing, website design service at Shrewsbury, Shropshire. We supply website design service to business in Shropshire and whole UKExpertise and services from spark computing, website design service at Shrewsbury, Shropshire. We supply website design service to business in Shropshire and whole UKOffice automatic solutions, online business solutions supplied by Spark computing, shrewsbury, shropshirecontact spark computing, shrewsbury, shroshire to discuss online business websites, custom software development

27/07/09

Permalink 09:23:34 pm, Categories: Shropshire talk  

A water cooler company

Hello people, here is a water cooler company in Shropshire

Wenlock Water coolers » .

You can buy or rent bottled/mains water coolers online.


Tweet this! Facebook Live Yahoo bookmark Digg US google bookmark
Permalink 08:27:27 pm, Categories: General IT articles  

How to force a download using php

Here is a handy function for forcing a download a file in any folder on the server that is readable by your php script.

PHP:

function send_file($path) {
    session_write_close();
    ob_end_clean();
    if (!is_file($path) || connection_status()!=0)
        return(FALSE);
 
    //to prevent long file from getting cut off from     //max_execution_time
 
    set_time_limit(0);
 
    $name=basename($path);
 
    //filenames in IE containing dots will screw up the
    //filename unless we add this
 
    if (strstr($_SERVER['HTTP_USER_AGENT'], "MSIE"))
        $name preg_replace('/\./''%2e'$namesubstr_count($name'.') - 1);
 
    //required, or it might try to send the serving     //document instead of the file
 
    header("Cache-Control: ");
    header("Pragma: ");
    header("Content-Type: application/octet-stream");
    header("Content-Length: " .(string)(filesize($path)) );
    header('Content-Disposition: attachment; filename="'.$name.'"');
    header("Content-Transfer-Encoding: binary\n");
 
    if($file fopen($path'rb')){
        while( (!feof($file)) && (connection_status()==0) ){
            print(fread($file1024*8));
            flush();
        }
        fclose($file);
    }
    return((connection_status()==0) and !connection_aborted());
}

Tweet this! Facebook Live Yahoo bookmark Digg US google bookmark
Permalink 02:09:25 pm, Categories: General IT articles  

Image button submit value

For example, if you have a image button like

Code:

<input type="image" name="Submit" value='Register' class="btn" src="images/register_form_btn.jpg" />

When the form is submitted via POST. there is nothing for $_POST[’Submit’]. However, you will have $_POST[’Submit_x’] and $_POST[’Submit_y’] that records the x and y coordinates of the click.

You can not do

Code:

if($_POST['Submit_x'] ) {
  //do something
}

that’s because a user might press the Enter key to submit the form. In this case, $_POST[’Submit_x’] and $_POST[’Submit_y’] are both 0!!

A convenient solution is to put a hidden field such as

Code:

<input type='hidden' name='form_sent' value='1'/>

within the form. Then in your php code

Code:

if($_POST['form_sent'] ){
//process form
}

Tweet this! Facebook Live Yahoo bookmark Digg US google bookmark

22/07/09

Permalink 09:08:20 pm, Categories: General IT articles  

Harden web server with suhosin

Suhosin is a “hardened php” project which can improve security of a web server running php script. If you are having some troubles running some scripts after you’ve installed, you will have to change some of the configuration values. I learned that when one customer has a very large html form to submit data using POST. However, only part of the form data can be accessed via the $_POST variable.

One way to sort it out is to put

Code:

suhosin.post.max_array_depth = 1024

in the account’s php.ini file.

Another way is to put

Code:

php_value suhosin.post.max_array_depth = 1024

in your .htaccess file. This only works if your administrator put

Code:

suhosin.perdir = 'p'

in the global php.ini file.

– Ben


Tweet this! Facebook Live Yahoo bookmark Digg US google bookmark

30/06/09

Permalink 01:13:18 pm, Categories: Spark computing news  

Warwickwright.com website ready

Warwickwright.com is specialised in retirement planning, pensions, investments, life insurance and annuity. Check it out more on their website.


Tweet this! Facebook Live Yahoo bookmark Digg US google bookmark

<< Previous Page :: Next Page >>

March 2025
Mon Tue Wed Thu Fri Sat Sun
 << <   > >>
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            

Spark Website Design, Shropshire

Technical articles on IT solutions.

Free information on office and home IT solutions; How to get a website running for your business; self-help e-commerce; and tips on website design.

Search

Misc

XML Feeds

What is this?