Web Hosting Vodahost    

Home Take The Royal Tour! Order Now Features Prices
Go Back   Web Hosting > VodaHost Web Hosting Support > mySQL & PHP

Notices

mySQL & PHP Discussions, information and help with mySQL and PHP.

Reply
 
LinkBack Thread Tools
  #1  
Old 08-29-2007, 04:07 PM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Question Olde One Bites Off More than he Can Handle

Below is a piece of code we've been trying to get to work and haven't been able to yet. Searched extensively several forums and web. G,Y,M and several others.
Any Help would be greatly appreciated.

PS: I added the global line in it.

<?php
global $SID,$IPAddress,$_SERVER,$UserAgent,$PageURL,$URL;
$SID="REMOVED_SITE_IDENTIFICATION";
$IPAddress = urlencode($_SERVER['REMOTE_ADDR']);
$UserAgent = urlencode($_SERVER['HTTP_USER_AGENT']);
$PageURL = urlencode($_SERVER['SCRIPT_NAME'].'?'.$_SERVER['QUERY_STRING']);
$URL = "<A href="http://si.REMOVED_SITE_NAME.com/GetData.aspx?SID=".$SID">http://si.REMOVED_SITE_NAME.com/GetData.aspx?SID=".$SID;
$URL = $URL.'&IPAddress='.$IPAddress;
$URL = $URL.'&UserAgent='.$UserAgent;
$URL = $URL.'&PageURL='.$PageURL;
include($URL);
?>
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #2  
Old 08-30-2007, 01:45 AM
navaldesign's Avatar
General & Forum Moderator
 
Join Date: Oct 2005
Location: Italy
Posts: 9,127
Default Re: Olde One Bites Off More than he Can Handle

Try changing :

$URL = '<A href=http://si.REMOVED_SITE_NAME.com/GetData.aspx?SID='.$SID.'>http://si.REMOVED_SITE_NAME.com/GetData.aspx?SID='.$SID;

Also i don't see anywhere the definition of si.REMOVED_SITE_NAME

Also, in my knowledge, you can't include an absolute URL (http://.....)

I also don't understand how you can include a file and also link it in the same time ???
__________________
Navaldesign
Logger Lite: Low Cost, Customizable, multifeatured Login script
Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old 08-30-2007, 01:55 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

Thanks Navaldesign

Didn't catch the difference at first glance till copy and paste one above the other.
I'll try that. propably would have helped if I'd showen the error message also.
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old 08-30-2007, 02:06 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

Is it possible that the post got edited? Because the <A <-- isn't in the code?
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old 08-30-2007, 02:39 AM
navaldesign's Avatar
General & Forum Moderator
 
Join Date: Oct 2005
Location: Italy
Posts: 9,127
Default Re: Olde One Bites Off More than he Can Handle

Yes, it is possible, as the forum editor automatically purses links. You need to go in Advanced, and disable the "Automatically purse links in the text" checkbox.
The difference is that i used single quotes otherwise the " inside will be intrpreted by php as php double quotes, otherwise you would need to place \ before the non php ".
__________________
Navaldesign
Logger Lite: Low Cost, Customizable, multifeatured Login script
Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old 08-30-2007, 02:44 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

<?php
$SID="XXXXXXXXXXXXXXXXXXXX";
$IPAddress = urlencode($_SERVER['REMOTE_ADDR']);
$UserAgent = urlencode($_SERVER['HTTP_USER_AGENT']);
$PageURL = urlencode($_SERVER['SCRIPT_NAME'].'?'.$_SERVER['QUERY_STRING']);
$URL = "http://si.XXXXXX.com/GetData.aspx?SID=".$SID;
$URL = $URL.'&IPAddress='.$IPAddress;
$URL = $URL.'&UserAgent='.$UserAgent;
$URL = $URL.'&PageURL='.$PageURL;
include($URL);
?>

error text
[25-Aug-2007 17:25:10] PHP Warning: include() [<a href='function.include'>function.include</a>]: Failed opening 'http://si.xxxxxx.com/GetData.aspx?SID=xxxxxxxxxxx&amp;IPAddress=xx.xx.x xx.xxx&amp;UserAgent=Mozilla%2F4.0+%28compatible%3 B+MSIE+7.0%3B+Windows+NT+5.1%3B+YPC+3.2.0%3B+.NET+ CLR+1.1.4322%3B+.NET+CLR+2.0.50727%3B+InfoPath.1%3 B+IEMB3%29&amp;PageURL=%2Ftest_page.php%3F' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/xxxxxxx/public_html/test_page.php on line 52
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7  
Old 08-30-2007, 02:46 AM
navaldesign's Avatar
General & Forum Moderator
 
Join Date: Oct 2005
Location: Italy
Posts: 9,127
Default Re: Olde One Bites Off More than he Can Handle

Remains the other problem: you can NOT, from what i know, include an absolute URL (http://sitename.......)
__________________
Navaldesign
Logger Lite: Low Cost, Customizable, multifeatured Login script
Instant Download Cart: a Powerfull, Customized, in site, DB driven, e-products Cart
DBTechnosystems.com Forms, Databases, Shopping Carts, Instant Download Carts, Loggin Systems and more....
Advanced BlueVoda Form Processor : No coding form processor! Just install and use! Now with built in CAPTCHA!

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8  
Old 08-30-2007, 02:47 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

This was a script fron goldencan getdata
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #9  
Old 08-30-2007, 02:51 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

the java scripts work fine but aren't SEO
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #10  
Old 09-02-2007, 05:36 AM
Staff Sergeant
 
Join Date: Dec 2006
Location: Newcomerstown,Ohio
Posts: 41
Send a message via Yahoo to bobs-pcmall
Default Re: Olde One Bites Off More than he Can Handle

The Olde One Found Answer....
Last Line is wrong...
include($URL);
should read as readFile($URL);
You were right on the money naveldesign. Many Thanks.
Even tho it was an html file also required changing the extension to php..
__________________
Bob the Builder
www.bobs-pcmall.com
Without Data, you're just another opinion.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT +1. The time now is 02:19 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC7
2007 VodaHost.com - All Rights Reserved

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 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55