cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Well the Google android comes with a browser but there is an app to convert that browser into the Google Chrome browser. And no you don't have 24GB of Ram but it proves that Google Chrome can run with ~1GB of ram even though it's a memory hog. ;)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

And how many users know about the app? Am sure if you knew, you would have mentioned one.

Ok. Here is an app for google chrome on the google android.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

So what's happening happygeek. I just got pm's that all except one have been moved to the php forum. So are the php mods going to review these and do I from now on post these in the php forum with the prefix TUTORIAL: or NEWS: ?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I've just submitted a redirect tutorial and am waiting for staff writers to approve. Soon I'll have dinner and start on the next tutorial.

pritaeas commented: Go cwarn23 ! +14
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

In php/html/javascript there are two different ways you may redirect a user to another page however there are a few things to consider before choosing with method to use. As you should know by now php has the ability to send html and javascript to the web browser and php can contribute to html and javascript functionality by generating scripts on the fly. So first I shall demonstrate php's ability to generate scripts on the fly.

#method 1

<?php
$page='http://www.google.com/';
// $page=''; //will disable redirect
// some massave code above here
?>
<head>
<title>A test page</title>
<?php
if (strlen($page)>0) {
echo <<< DATA
<meta http-equiv="refresh" content="0;url={$page}">
<script>
window.location="{$page}";
</script>
DATA;
}
?>
</head>

Now in the above script you will see that it uses client side scripting for the redirect. In this case it uses both the meta redirect and javascript redirect so that it if javascript is disabled the browser can meta redirect or if meta redirect is disabled then the browser can javascript redirect. So if you want client side redirect that is the basic way to go about it keeping in mind client side redirecting isn't always the best option. Keep in mind that with client side redirecting, you are not guaranteed to make the user redirect. In some cases both javascript and meta redirect will be disabled. Luckily php has it's own solution. So lets see what php has installed for us.

#method 2

<?php
$page='http://www.google.com/';
// $page=''; //will disable …
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I wonder what I'm going to do with this new computer just arrived in my mail. I might render a movie then play a game on it.

*Didn't mean to spam links but makes a good touch*

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Please post a list of ideas for tutorials that can be written for the php section. Please bear in mind the tutorials are to be kept relatively small so don't ask for something that may take pages upon pages of text to explain. Thanks.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Hi, in this news you will see how in the past few years there has been some controversy over a bug or more commonly known as a feature which appears it may be removed as of php 5.4.0. According to the features list of php 5.4.0 beta there is the following quote.

- Removed features:
. Removed magic_quotes_gpc, magic_quotes_runtime and magic_quotes_sybase
ini options. get_magic_quotes_gpc, get_magic_quotes_runtime are kept
but always return false, set_magic_quotes_runtime raises an
E_CORE_ERROR. (Pierrick, Pierre)

Now some users will have a good idea what this is but most won’t have a clue as most don’t dig into the closed in corners of php. For non php experts magic quotes is used for $_POST to add a backslash to each quote whenever a form is posted with method=post. But this only applies within a certain range of php versions and can be disable in the php.ini making a task to check if the backslashes exists of not. Fortunately two functions had existed until php 5.4.0 and they are in the following code.

<?php
class httppost {
    public $value;
    function stripslashes($value) {
        $value = is_array($value) ? array_map(array($this,'stripslashes'), $value) : stripslashes($value);
        return $value;
        }
    function __construct($in) {
    if(get_magic_quotes_gpc()) {
        //magic quotes enabled
        $this->value=$this->stripslashes($in);
        } else {
        $this->value=$in;
        }
    }
}

////////////////////////////////////////////////////
if (isset($_POST)) {
$post=new httppost($_POST);
echo htmlentities($post->value[‘item_name’]);
}
?>

However as of php 5.4.0 all you need to do is the below to get the same result as of php 5.4.0.

<?php
if (isset($_POST)) {
echo …
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

While it's true RAM is cheap as chips, installing 24 GB isn't an option for everyone. What about netbook users, or desktop users with 32-bit systems? :icon_rolleyes:

FireFox seems to work fine on my Intel Atom N450 powered netbook, with 1 GB or memory. Anyone tried Chrome or Opera on a netbook?

I'm sure there's an app for that :)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

And you can always buy more memory. Why not enjoy the full benefits of the 24GB ram capacity a standard motherboard can hold. Why cat back to 1GB or 2GB? Is beyond me why people do.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

The shift you posted looks like producing same result here in Python. 2**512 is no problem in Python (>>> is the interactive prompt):

Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32
Type "copyright", "credits" or "license()" for more information.
>>> 128*4096>>10
512
>>> 2**512
13407807929942597099574024998205846127479365820592393377723561443721764030073546976801874298166903427690031858186486050853753882811946569946433649006084096L
>>> 1<<512
13407807929942597099574024998205846127479365820592393377723561443721764030073546976801874298166903427690031858186486050853753882811946569946433649006084096L
>>> 10 - 1 << 3
72

def myfact(n):
    f = 1
    for n in range(2,n+1):
        f *= n
    return f

>>> myfact(10)
3628800
>>> myfact(1000)
402387260077093773543702433923003985719374864210714632543799910429938512398629020592044208486969404800479988610197196058631666872994808558901323829669944590997424504087073759918823627727188732519779505950995276120874975462497043601418278094646496291056393887437886487337119181045825783647849977012476632889835955735432513185323958463075557409114262417474349347553428646576611667797396668820291207379143853719588249808126867838374559731746136085379534524221586593201928090878297308431392844403281231558611036976801357304216168747609675871348312025478589320767169132448426236131412508780208000261683151027341827977704784635868170164365024153691398281264810213092761244896359928705114964975419909342221566832572080821333186116811553615836546984046708975602900950537616475847728421889679646244945160765353408198901385442487984959953319101723355556602139450399736280750137837615307127761926849034352625200015888535147331611702103968175921510907788019393178114194545257223865541461062892187960223838971476088506276862967146674697562911234082439208160153780889893964518263243671616762179168909779911903754031274622289988005195444414282012187361745992642956581746628302955570299024324153181617210465832036786906117260158783520751516284225540265170483304226143974286933061690897968482590125458327168226458066526769958652682272807075781391858178889652208164348344825993266043367660176999612831860788386150279465955131156552036093988180612138558600301435694527224206344631797460594682573103790084024432438465657245014402821885252470935190620929023136493273497565513958720559654228749774011413346962715422845862377387538230483865688976461927383814900140767310446640259899490222221765904339901886018566526485061799702356193897017860040811889729918311021171229845901641921068884387121855646124960798722908519296819372388642614839657382291123125024186649353143970137428531926649875337218940694281434118520158014123344828015051399694290153483077644569099073152433278288269864602789864321139083506217095002597389863554277196742822248757586765752344220207573630569498825087968928162753848863396909959826280956121450994871701244516461260379029309120889086942028510640182154399457156805941872748998094254742173582401063677404595741785160829230135358081840096996372524230560855903700624271243416909004153690105933983835777939410970027753472000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000L
>>>

This 10 - 1 << 3 could differ from what you expect.

Which one of those numbers are your answer because I'm confused?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

last night I posted a second tutorial and both tutorials are in the que. I know two staff writers are subscribed to this topic so could one of them please review them.
Thanks.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I think you need to reinstall your phones operating system. There is a youtube video for how reinstall the phones operating system. Please view the below video for how to do so.
http://www.youtube.com/watch?v=88qRbLLEAPQ

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Well at least I think it's invalid input. I'll let the fellow posters decide that. For now I shall setup an equation that I find simple but I dunno about you.

(pow(2,128*4096>>10)|1)-1
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I don't disagree with you. Just saying.

I've been an Opera user for years.

I don't disagree with that but I just shortened my post for those who can't read a whole paragraph of text. :)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Basic math is of course simple, but got myself mystified sometimes with exponentiation (shame on me, and I got stipend of best mathematical science student in my graduation year 1984 in my town):

-1**0.5 is valid formula (-1^0.5 some languages).

In c++ that would result in a compilation error as one is an int and the other is a double. Haha solved it (Answer: invalid input) lol :)

skilly commented: i do believe +0
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Opera is up to 11.51 now and that article came out at the start of the year :)

Well the Google Chrome articles came out of date before that and that's what I'm highlighting.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

well you cant take it apart unless you have a dust free environment to do so,

the inside of the harddrive resembles a record turntable ,when you dropped it the arm with the needle hit the spinning HDD platter causing the damage ,repairable maybe but very expensive .try slaving it to another computer and retrieving the files ,or using a external case to put the drive into .if you have no access to such devices take it to a computer shop and see if they can get file for you ,then buy a new HDD

In this situation this would not work because dropping the laptop would cause the pin the crush into the magnetic disk from the force of the impact. So even if the magnetic disk was removed and put into another hard drive then you would still have a corrupted hard drive that you may not even be able to boot from. Best bet would be to retrieve those backups and put them onto a new laptop. You did have backups right?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

In the case of a SD card the best way to make sure it cannot be stolen is to design a camera which encodes the images with an algorithm that only specialized software can read. Then to save the images to the computer you would need to process these files through a secure program which requires a registration and have it so that each registration will only work on one computer. Their my thoughts anyway.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

OMG these bugs keep on coming. Did you hide any more for me to fix?

<?php session_start();
if (!isset($_SESSION['referer'])) { 
    $_SESSION['referer']='';
    }
$_SESSION['referer'].=(isset($_SERVER['HTTP_REFERER']))?($_SERVER['HTTP_REFERER']."\n"):'';
$my_web = $_SESSION['referer'];
?>

This time I tested it :)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Just to let you know I have written a tutorial for this and it has been in the holding que for the past 23 hours. At the moment I'm waiting for staff writers to approve it but when it's approved I shall give you the link.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Actually the worlds fastest browser at the moment is Opera but you must read the entire reason before denying. Versions of Opera before 10.10 were terribly slow in comparison to todays browser standard and when Google Chrome came out Opera was up to 10.09 and probably beta too. So that meant when all of those comparisons were done during the time of the Google Chrome launch period it shows Operas older slower version. But 3 or 4 months later Opera released version 10.10 beating Google Chrome and very few headlines were made about this because browser wars had already made news recently. So when you search for a comparison of browsers generally you will see a comparison from BEFORE opera became 10.10+ (the speedy version) which is when the influx of articles occurred. So if you want a true comparison dig hard and get an up to date version with the latest browser versions and you will see that Opera is truly the fastest when comparing the latest version of each browser instead of comparing selected versions of each browser.
http://download.cnet.com/8301-2007_4-10452292-12.html?tag=mncol;1n

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Ow now I see. Another bug. Try this.

<?php session_start();
if (!isset($_SESSION['referer']) { 
    $_SESSION['referer']='';
    }
$_SESSION['referer'].=$_SERVER['HTTP_REFERER']."\n";
$my_web = $_SESSION['referer']
?>
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

C:\Windows\system32\msible.dll

To have that file I am assuming you have Windows 7. I believe that file might be something to do with the windows idle processor. What I would suggest doing is booting up windows in safe mode then renaming that file by putting the number 3 at the end. Then put in the windows installation disk and do a repair of the system and it should replace that file with a clean one. If not then rename that file back.

If it comes down to it I think you can reinstall windows without loosing your files but you loose anything in Program Files and any Registry entries. But that's an assumption from a past experience.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Your script should be the following:

<?php session_start();
 $_SESSION["referer"] .= $_SERVER['HTTP_REFERER'];
 $my_web = $_SESSION["referer"]
?>

Also you will need to find another alternative to $_SERVER as it isn't always that accurate. The reason being is users can disable that information being sent.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

$_GET is to get a variable from the url or a form method="GET" request like the previous post suggests.
$_POST get's a method="POST" request and is designed so that people can't read this data without a special addon or script which many people do for hacking reasons.
$_REQUEST is both $_GET and $_POST combined into the same array so it is the same as the following:

$_REQUEST=array_merge($_POST,$_GET);
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

You may want to use cron to execute the task and disable the cron task after it has started executing. Please tell use what admin panel do you use (eg cpanel/plesk) and what operating system are you dealing with (eg centos/ubuntu) and which software stops running.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

To copy your files to a flash file and reinstall windows you should really boot through a ubuntu live cd and copy the files while in ubuntu then reinstall windows. You can download the ubuntu live cd at http://www.ubuntu.com/download/ubuntu/download and to use it simply insert it into the computer then reboot or crash windows. After the computer reboots boot from the live cd (don't install it) and in the side panel there will be a picture of a folder. Click it. Then insert the flash drive. Copy all of the files from the other drives the the new drive that just appeared. Then reboot and take out the cd and put in the windows cd. Then reboot again and reinstall windows. Then after windows is installed your files *might* already be their but if their not then copy them back from the flash drive. That simple.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Warning: This method requires nerd gparted experience.

I have dealt with similar circumstances before and will explain how I went about doing it. For my method you will require an external harddrive or a giant flash drive. To do this you need to buy or download a linux disk which comes with the gparted software preinstalled. To download it simply find a linux iso image (any linux variation with gparted part of the package bundle) then burn that iso image to a cd. After that insert the cd into the cd-rom drive and reboot the computer. When the computer reboots you will see a new menu. From this menu you will want to boot from the cd. After booting from the cd, open gparted and format the external harddrive or flash drive as the same file system as what the drive you are going to copy too is and during the process give it the label temp. After that you may close gparted and open the linux equivelent of explorer. Now copy all of your files from the drive your going to copy too to this external harddrive or flash drive (remember all of this is in linux and non of this will be in windows). Now in gparted check the two internal drives and write on a piece of paper every piece of information gparted can report about their file systems, partitoning, boot sectors etc. You will need to program all of that information back in later. After …

jingda commented: Welcome to the hardware community;) +11
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Hi Dani
Would it be possible to have a second page (cached/updated every 7 days) of stats where it shows graphs of fortnightly stats for things like the following.

  • Line graph of (Total reputation added to daniweb).
  • Line graph of (My received reputation) and (My sent reputation) on same graph.
  • Pi graph of (Threads made) and (Threads solved) in the past fortnight.
  • Pi graph of (Repution points added) and (voting points added)

And any other graphs people can think of and post here. Note that all stats are restricted to the past fortnight and the page with these stats only gets updated every 7 days. Also to save cpu you could make it a members only page meaning you must be signed in to view it.
Thank you

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

What is it that inspires you to continue programming every day or every week. Is it work or results or something else you would like to share. So please share as I'm sure this will be interesting.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Wow when did this topic turn into an explosion in the middle of New York. This happens every time somebody asks what is the best programming language on any forum on any website anywhere on the internet. It's like people treat their favourite language like their personal adopted baby. I can't believe how people aren't open to the opinions to others and aren't able to vote on the facts that are presented. Seriously where above has somebody voted on a weather one of the facts presented are true or not instead of saying it must be false because theirs are true. All I can say is same on you for making a great topic turn into a disaster thread.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Making sites is nice and fun but what if you don't want everybody too see something like an admin panel or maybe a special button. Well this tutorial helps you understand how to add a password to a php site in a simple manner. There are two techniques you can use. One is to use a database which allows you to have a group of users who may access the site. Another technique is to have pre defined variables that check if the values match the value of the variable. In this tutorial you will get to know the basics while following the method of entering users into a php file. Please note all passwords should be hashed but this is a tutorial and I kept it as simple as possible.

To use a variable stored in your site configuration file (eg config.php if you have one) you simply do the following:

<?php //config.php
$users[0]['name']='cwarn23';
$users[0]['password']='password';
$users[1]['name']='root';
$users[1]['password']='drowssap';
?>

Now you will notice that there is an array of users that may use the site along with their passwords. Normally for security reasons the password would be salted on both sides of the string. Then hashed, then substr() then finally rehashed. Note you should never use crc32 or crc32b as a hashing algorithm but for now lets see how to check if the user has loged in. To do that we need a html form. So lets make one.

<form method="post" action="">
Username: <input type="text" name="user" /><br />
Password: …
happygeek commented: thanks for the tutorial +12
scarcella commented: Very well written! +3
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

But that's like saying you can only use the tools that were available 2,000 years ago when Jesus walked the earth to do today's work. Assembly may be the father of all computer languages but sure isn't the best one, or even the most efficient one to use today.

If it isn't the most efficient one then why does Intel program their chips using Assembly and Linux use Assembly to recognize the computers hardware along with C. Even Windows XP has a small amount of Assembly to recognize Bios in the boot sequence. If Linux can be written in entirely in Assembly and C then I don't see why everything else can't. So do you deny that Linux and Windows are efficient (not that Windows is anyway) or because they use Assembly they are both terribly slow.

PS
Now that I think about it, it could be because Linux uses more Assembly than windows which makes Linux faster :)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Below is an encrypted birthday present and I have pm'd dani instructions on how to decrypt it. :)

6D49994337A1B0D0EDB50CD77C2664C98614827FDB91DD56AF8FB83079C0D7C0C89FEE7471F46CDB
2D1E5F5FB9DE010CADB8AF25845CDA401420FDDF7922FD409C68953CD82F9B441E46E83106BBDC40
6FB76DCC1167B5D82A5A50F1FC9F1B712E370AECB9FA9A7EE35F1E634508A3BBD7ACE9243B018119
31E811AE33913A0B4AA39B9CBC51C5779462BA2E567AE61AF9A680F023ED94C81AFD79245D0E61CE
37A24AF13AA8DC5CBA1771EB4861BADB5FDFF4E7D4A7A7DB06008DB533036B8E14C9B93B78303EC1
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Please refer to the computer language family tree. It clearly shows Assembly is the ultimate language with no previous generation to it. It is like god/jesus of programming which gave birth to children/languages which gave birth to even more children/languages. So if you want true efficiency then use Assembly and not the mutant offspring. May not be pretty but it works.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

You also may want to refer this this thread.
http://www.daniweb.com/web-development/php/threads/179487
Brings back the memories.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Please post a description of what the problem is and what errors you are receiving. In case you are wondering how many words are necessary I would say 32 or more.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

The "return" statement is used primarily in two areas. One is custom functions that you define and the other is in the include() and require() to return from the required or included page a variable. So here's a sample script.

<?php //index.php
function myfile() {
return 'test.php';
}

$variable=include(myfile());
//$variable now has the value 'test'
<?php //test.php
return 'test';
?>

As you can see in that script is all of the uses for return. Basically it ends the subscript and returns to the parent script.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Perhaps the website uses a salt on the hash there by making it hard to validate/compare even if you have the original data. At the moment I'm using brute force to find the salt on 3.2GHz 3 core as that should find if any basic salts if the salt isn't too long. But other than that you will need to find out what salt the website uses.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

> Anything that you post in there can only be seen by yourself as well as moderators/staff writers

Just FYI, I can't see anything in there. Are you sure it's not "staff-writers-only"? Or is it that nothing has yet been submitted?

I've just submitted a tutorial so something should be in there.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

PHP is a nice language with features a wide range of automated features for memory but when it comes to mass processing for things like calculating pi or processing a database that's a couple dozen Gigabytes then you may run into a few troubles if things aren't done correctly. This of course only happens depending on what operating system you have and what updates you have done along with settings you have set but those pieces of information are a bit puzzling as some web servers have this problem while others don’t.

So this feature I'm going to talk about makes it impossible to process no more information than the amount of ram you have. So lets examine the code below and detect the bug in the following PHP code.

<?php
$b=pow(2,20);
for ($i=0;$i<1024;$i++) {
$a=bcpow('10',$b);
}
?>

Now if you examine that code it is a straight forward loop that does nothing. But it has great importance and I shall show you why. On the first line is the PHP opening tag as normal. Then second line is a variable assigned a number which is equivalent to 1MB in bytes. This will be used later. Then next line down is a loop and inside that loop is the assignment of a variable. Now it is the assignment of this variable that is interesting. The variable is assigned 1MB of data there by because the other variables are numbers the Ram usage should be about 1MB. However with that …

happygeek commented: thanks for the tutorial +12
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I went ahead and renamed the 'Contribute News Stories' forum to the 'Contribute Editorial' forum because that is specifically its purpose, and it can work just as well with tutorials as with news stories.

http://www.daniweb.com/community-center/contribute-editorial/178

Anything that you post in there can only be seen by yourself as well as moderators/staff writers. Once approved, it gets moved to one of the public sections of the site and promoted to an official news story or tutorial.

Thanks for the new forum dani. I shall give it a try but with the approval system in place it would be nice for another forum where people can ask for tutorials to be written. Could such a forum be created? Could even be a subforum of the Geeks Lounge along with a sticker on how to post tutorials in that forum.

Thanks
cwarn23

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

It is clearly missing the surrounding scene of a super computer in front of the desk with remote access on the monitor screen. Also the toilet should be below the desk so you don't need to get out of the chair to go to the loo.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I would have to say Assembly, C, Python and SQL. If you can learn those four languages completely and fluently than you can solve just about any computer software issue weather it's to do with servers or linux or windows software etc.

sergent commented: Assembly! +0
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Are you referring to the image format psd or something else because it is impossible to convert an image to html unless you are talking about the <img> tag.

Please advice.
cwarn23

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Could you please be more descriptive on what it is you need done. From what I got from your two sentences you need to convert an excel file to a pdf using php is that right. If so there is the PHPExcel library and I believe php has an optional c module you can install for pdf files meaning you would need to recompile apache and php to install the pdf module. Besides that the link for the PHPExcel script is http://phpexcel.codeplex.com/ and take a look around that website to see if that is the missing piece of the puzzle. If not then please describe in more detail what the problem is.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

If you want to download more than one image then perhaps a loop might be best. For example.

<?php
//first to specify the url
$links=array(
'http://images.daniweb.com/1a.jpg',
'http://images.daniweb.com/2c.jpg',
'http://images.daniweb.com/3d.jpg',
'http://images.daniweb.com/4h.jpg',
'http://images.daniweb.com/5f.jpg',
'http://images.daniweb.com/6e.jpg',
'http://images.daniweb.com/7d.jpg');
foreach ($links AS $url) {
//now to retrieve it
$imagedata=file_get_contents($url);
//now to save it
file_put_contents(basename($url),$imagedata);
//and image.jpg will be in the same directory as your php file
}
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

There is a nice function called file_get_contents which gets the contents of a url and stores it in a variable then you can place it into a file or process it into a mysql database etc. For example

<?php
//first to specify the url
$url='http://images.daniweb.com/logo.gif';
//now to retrieve it
$imagedata=file_get_contents($url);
//now to save it
file_put_contents('image.gif');
//and image.gif will be in the same directory as your php file

And there you go. As simple as that.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

cwarn23, you used the tags <xmp> and </xmp> before and after your code. Could you explain what they are for?
Matthew

They are just html tags to make the text look pretty literally. Without them the text doesn't look as good and is all on one line.