minbak Posted July 20, 2006 Share Posted July 20, 2006 I have encountered a little bit problem here when I transferred my site to new host.My new host doesn't allow FOPEN in the PHP code to access a URL.So someone suggested me to change from the Original code http://www.Motortradermalaysia.com/ShowBan...ype=468x60' to suggested code ShowBanner.php?BannerType=468x60Am I right? My problem is I could see the file of ShowBanner.php but not ShowBanner.php?BannerType=468x60.?BannerType=468x60Where could I find this file?This is the uploaded banner by the user.What is the correct code? Quote Link to comment https://forums.phpfreaks.com/topic/15130-changing-path-in-php-script/ Share on other sites More sharing options...
ChaosXero Posted July 20, 2006 Share Posted July 20, 2006 ?BannerType=468x60 is creating a variable in a superglobal array called $_GET. You need something in your code to tell it what to get/do. If that's a size for an image you might echo an img tag with the correct size or similar. Unless you specifically tell it to look for a file, it's just passing the banner type variable to the page.Also, when you write in for help, including the page code always helps. Just remmeber to scrub out any personal data (DB passwords etc.)Good luck and I hope this helps. Quote Link to comment https://forums.phpfreaks.com/topic/15130-changing-path-in-php-script/#findComment-61009 Share on other sites More sharing options...
minbak Posted July 21, 2006 Author Share Posted July 21, 2006 The original code is<? include_once($BannerPath."/ShowBanner.php?BannerType=120x60"); [color=red][font=Verdana][b]?> </center> </td> <td valign=top style="padding-top:5" width=600> <div align="center"> <? include_once($BannerPath."/ShowBanner.php?BannerType=468x60"); ?> </div>[/b][/font][/color]What is the correct code to avoid using Fopen ? Quote Link to comment https://forums.phpfreaks.com/topic/15130-changing-path-in-php-script/#findComment-61533 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.