![]() |
|
| |||||||
| Notices |
| mySQL & PHP Discussions, information and help with mySQL and PHP. |
![]() |
| | LinkBack | Thread Tools |
|
#1
| |||
| |||
| 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); ?> |
|
#2
| ||||
| ||||
| 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! |
|
#3
| |||
| |||
| 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. |
|
#4
| |||
| |||
| Is it possible that the post got edited? Because the <A <-- isn't in the code? |
|
#5
| ||||
| ||||
| 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! |
|
#6
| |||
| |||
| <?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&IPAddress=xx.xx.x xx.xxx&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&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 |
|
#7
| ||||
| ||||
| 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! |
|
#8
| |||
| |||
| This was a script fron goldencan getdata |
|
#9
| |||
| |||
| the java scripts work fine but aren't SEO |
|
#10
| |||
| |||
| 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.. |