Unstoppable Domains

An Include

Spaceship Spaceship
Watch

combs84

Established Member
Impact
23
OK so a website who is advertising with me sent me a webpage of like http://www.superbook.com/seo.txt

I guess I am suppose to somehow use the webpage to extract the link which they can change at will, which will inturn change on my site so we don't have to keep communicating and updating it.

He said "I just think it's easier for you to make an include of these ready-to-use
text links."

So I guess he wants me to make an include of this webpage then? I'm not sure how to do that. I have a slight idea of what it mean, but have no idea how to do it.

Any help is VERY VERY appreciated!
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
AfternicAfternic
0
•••
PHP:
<?php

echo file_get_contents('http://www.superbook.com/seo.txt');

?>
 
0
•••
-NC- said:
PHP:
<?php

echo file_get_contents('http://www.superbook.com/seo.txt');

?>

Yeah this is a pretty good way to do it, you should check for bad input incase they put some unfriendly JS in there too.

Dan
 
0
•••
I'll check that program out for sure and see what it's about.

Thanks for the include code, i'll give it a try!
 
0
•••
as daniel suggests, you need to check the file and make sure there not stuffing anything dodgy in there. The obvious ones are onload, script, style, and stylesheet. If any of those are in the file i'd have the script NOT included and email you an error report. Stripping them out isnt an option in this case as your pages will be a mess whenever one of the rogue adverts are displayed.

regards

Darren
 
0
•••
Use file_get_contents as suggested above, do not include a remote file. This could allow the execution of arbitrary code on your server. Anyway, any content should be parsed carefully.
 
0
•••
Actually you cant "include" a remote file using the include command(fortunately). file_get_contents or any of the fopen based methods with the allow url on fopen setting on will do what you need. my focus was on checking the contents (every time) as html, javascript and related injection attacks could be performed. If your passing the contents of the file to a templating system and/or storing it in a database, i'd also check for php and mysql injection attacks
 
0
•••
Dynadot — .com TransferDynadot — .com Transfer

We're social

Domain Recover
DomainEasy — Payment Flexibility
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back