Open URL

General discussions related to php

Moderators: macek, egami, gesf

Ideen911
New php-forum User
New php-forum User
Posts: 3
Joined: Mon Mar 10, 2003 12:45 am
Contact:

Open URL

Postby Ideen911 » Mon Mar 10, 2003 12:55 am

Hello everyone,

I'm having a problem finding a function that opens a URL. I have a for loop, and during each cycle, it opens a random URL from a database. I've done all the hard work, I just can't seem to find a way to open the URL (make it as if a link has been clicked). Anyone have any ideas?

Thanks in advance,
Ideen911

User avatar
WiZARD
Moderator
Moderator
Posts: 1257
Joined: Thu Jun 20, 2002 10:14 pm
Location: Ukraine, Crimea, Simferopol
Contact:

Re: Open URL

Postby WiZARD » Mon Mar 10, 2003 2:56 am

Hi Ideen911!
How i know 911 it's a emergensy, interesting who need help?

1) OOpen DB
2) put in array all DB with URLs
3) make shuffle (it's function)
4) use next like:$handle = fopen ("http://www.example.com/", "r");

Ideen911
New php-forum User
New php-forum User
Posts: 3
Joined: Mon Mar 10, 2003 12:45 am
Contact:

Postby Ideen911 » Tue Mar 11, 2003 12:13 am

Thanks, I tried that and I go this error:

Warning: fopen("some URL","r") - No such file or directory in ...generator.php on line 39.

This function that i worte is supposed to create and open AIM links that start with "aim:"... instead of "http://"
Do you know how I can just redirect to that URL since the file does not exist?

Thanks again!

By the way, 911 is for my PORSCHE 911 TURBO! Not that I own one yet.. but soon.... maybe :wink:

User avatar
WiZARD
Moderator
Moderator
Posts: 1257
Joined: Thu Jun 20, 2002 10:14 pm
Location: Ukraine, Crimea, Simferopol
Contact:

Postby WiZARD » Tue Mar 11, 2003 6:27 am

Of course, url like aim for youre system fault cause AIM not present.....
Best if you open new window and give link to aim

Ideen911
New php-forum User
New php-forum User
Posts: 3
Joined: Mon Mar 10, 2003 12:45 am
Contact:

Postby Ideen911 » Tue Mar 11, 2003 1:17 pm

oh, I see.

How would I do that with PHP?

thanks again.

User avatar
WiZARD
Moderator
Moderator
Posts: 1257
Joined: Thu Jun 20, 2002 10:14 pm
Location: Ukraine, Crimea, Simferopol
Contact:

Postby WiZARD » Tue Mar 11, 2003 11:34 pm

See carefully at our forum....
By the way it's working if at client who open page installed AIM


Return to “PHP General”

Who is online

Users browsing this forum: No registered users and 1 guest

cron