Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    Regular Coder Coastal Web's Avatar
    Join Date
    Oct 2004
    Posts
    225
    Thanks
    12
    Thanked 3 Times in 3 Posts

    include("withVariables.php?s=".help);

    hello everyone, I am a little stumped here.
    I had created a code that was working fine, working fun that is until yesterday evening (perhaps my host made some changes...)

    anyway l was using this code to "include" a script at searches my site for related articles...
    PHP Code:
    include("http://www.somepage.com/related.php?s=".$some_var); 

    The related.php script works fine, however l am getting the following error message when trying to to use the above code to include this page. The funny thing is l made this weeks ago and it has been working fine all along and then last night (w/out any changes on my end) it crashed.

    here's the error l get:

    PHP Code:
    Warningmain(http://www.me.com/tutorials/related.php?s=website+template+design+header+Quick+Layout): failed to open stream: No route to host in /mnt/wm/d3/s31/b0264d2d/www/tutorials/quick-layout/index.php on line 290

    Warningmain(): Failed opening 'http://www.me.com/tutorials/related.php?s=website+template+design+header+Quick+Layout' for inclusion (include_path='.:/usr/local/nf/lib/php'in /mnt/wm/d3/s31/b0264d2d/www/tutorials/quick-layout/index.php on line 290 
    any help would be greatly appreciated,
    Samantha G.

  • #2
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,093
    Thanks
    11
    Thanked 101 Times in 99 Posts
    I assume you have checked the link still exists ?

    If url fopen wrappers have been turned off by your host (allow_url_fopen = 0) then include('http;// etc will not work anymore.

    It could also be a local name resolution problem but thats a question for your sysadmin/host

    Lastly perhaps the page you want to include now requires sessions or cookies or has simply stopped allowing aggregating content/scraping scripts?

    <edit>rereading I assume both scripts are yours in which case scrap 1 & 4 & concentrate on 2 & 3</edit>
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)

  • #3
    Senior Coder
    Join Date
    Apr 2005
    Location
    Colorado, United States
    Posts
    1,208
    Thanks
    0
    Thanked 0 Times in 0 Posts
    That sounds to me like the server's DNS server failed in some fashion. No route to host means it can't connect...not that it's disabled. If it was disabled I believe it'd throw an error about not being able to include remote pages.
    "$question = ( to() ) ? be() : ~be();"

  • #4
    Regular Coder Coastal Web's Avatar
    Join Date
    Oct 2004
    Posts
    225
    Thanks
    12
    Thanked 3 Times in 3 Posts
    Thanks guys...

    sounds like Velox Letum hit the nail on the head - because now it's working again w/out any changes on my end.

    I guess l'll just toss an @ sign in front of the @include('url here'); functions so that if/when this happens again it'll just disappear off the page..

    Velox Letum - That sounds to me like the server's DNS server failed in some fashion. No route to host means it can't connect...not that it's disabled. If it was disabled I believe it'd throw an error about not being able to include remote pages.
    edit:
    "$question = ( to() ) ? be() : ~be();"
    classic... lol ^^


    thanks agian...
    Last edited by Coastal Web; 01-10-2006 at 01:26 AM.

  • #5
    Super Moderator
    Join Date
    May 2002
    Location
    Perth Australia
    Posts
    4,093
    Thanks
    11
    Thanked 101 Times in 99 Posts
    Quote Originally Posted by Velox Letum
    If it was disabled I believe it'd throw an error about not being able to include remote pages.
    DOH, of course sorry
    resistance is...

    MVC is the current buzz in web application architectures. It comes from event-driven desktop application design and doesn't fit into web application design very well. But luckily nobody really knows what MVC means, so we can call our presentation layer separation mechanism MVC and move on. (Rasmus Lerdorf)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •