Community

warning include (...) [function.include]: failed to open stream: No such file or directory ..

I keep getting the following warning message on my Drupal site:

warning: include (sites/all/themes/ymca/php/twitter-feed.php) [function.include]: failed to open stream: No such file or directory in /data1/home/vanymca/docs/centres/tonglouie/sites/all/themes/ymca/page-front.tpl.php on line 166

warning: include() [function.include]: Failed opening 'sites/all/themes/ymca/php/twitter-fee.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php')
in /data1/home/vanymca/docs/centres/tonglouie/sites/all/themes/ymca/page-front.tpl.php on line 166

I no longer use the twitter feed so I had removed the "twitter-feed.php" file and commented out the section of the code related to the twitter feed in the page-front.tpl.php on line 166. Some how Drupal is still trying to reference and read the twitter feed. I've also disabled the twitter module in Drupal. I'm not sure where Drupal is reading twitter from and where else I need to remove that's related to twitter.

Thanks!

Comments

1) clear your cache. If that

1) clear your cache. If that doesn't help, then:
2) Visit the theme administration page. This can clear the theme cache. If that doesn't help then:
3) You've probably edited the wrong file. To see if this is the case, temporarily rename the file and follow the above two steps again. If things don't go really weird, then you've edited the wrong file.

Jaypan We build websites

Thanks for the suggestions.

Thanks for the suggestions. The file is correct and I've cleared the cache many times before. I just tried using /*...*/ for comments in php inside the comment html code to see if that will fix my issue since the section of code I want to comment out has both php and html.

AZ

And what was the result? Were

And what was the result? Were you able to see the comments in the HTML source?

Jaypan We build websites

I can't tell yet. The warning

I can't tell yet. The warning messages only show up once in a while so I'll have to wait and see. Thanks for all your help though!

AZ

Ok I just received the same

Ok I just received the same warning message again. Here is the chunk of code I tried to comment out:

<!-- /* <div id="home_right_box_3">
     <div class="home_box_container">
     <h2>We're on <img src="/centres/langara/sites/all/themes/ymca/images/logo_home_twitter.jpg" alt="Twitter" /></h2>
     <?php include('sites/all/themes/ymca/php/twitter-feed.php'); ?>
     <p><a href="http://twitter.com/tonglouieymca" class="btn_follow_us_on_twitter" target="_blank">Follow us on Twitter</a></p>
     </div>
     <div id="home_right_box_3_top"></div>
     <div id="home_right_box_3_bottom"></div>
     </div>
          */ -->

Did this code not comment out correctly?

AZ

The PHP part of the script

The PHP part of the script will still be entered even in an HTML comment. PHP tags don't check to see if they are in a comment. They just tell the processor to switch from directly outputting the data to parsing the data as PHP. Why haven't you just removed all this code? There is the reason you are seeing the error.

This is why you should include your code with your posts. You said you had commented out the code, but you haven't commented out the PHP code at all. You could have solved your problem much sooner.

Jaypan We build websites

Thanks!! I had put /* ..*/

Thanks!! I had put /* ..*/ before and after the html comment so I thought it would've commented out both html and php. I wasn't aware that PHP tags don't check to see if they are in a comment. I've just backed up the code and removed it now.

On another issue, would you also happen to know how to sort by day timestamp on a Drupal page? I have created a list of pages for various program activities (fitness, aquatics, day camp programs etc.) on my Drupal site. For each program activity such as Fitness, there are classes listed under each day of the week so it displays something like this:

Ex of Fitness Programs page:

Day Timestamp: Monday

-Teen Strength & conditioning Centre Orientation

-Step & Strength

Day Timestamp: Tuesday

-Zumba

-Cyclefit
.....

Day Timestamp: Sunday

-Personal Training

-Yoga

I've set up in Administer>Site building>Views to group field and sort by "Day Timestamp" (sorting from Monday to Sunday) for each program page. I've applied the same group field and sort settings to all of the various programs on my site and most of them are sorting correctly from Monday to Sunday except 2 of them. It would display the days of the week out of order ( Tues, Thurs, Sat, Fri, Wed..) I've checked the SQL database tables to see if the days of the week were entered incorrectly in case there were different ASCII characters that may lead to wrong sorting order. This did not work either. Any suggestions on this one?

Thanks!

AZ

Better to start a new topic

Better to start a new topic for that.

Jaypan We build websites

I did start a new topic on

I did start a new topic on Jan 9th, but haven't gotten any feedback yet.

http://drupal.org/node/1884602

AZ

This has happened to me too,

This has happened to me too, thanks for sharing. This has happened to me too, thanks for compartirsiempre to start with a new program for me I have enough problems, I had to take many turns in google to find the solution, I need to learn to look better.

Encountered the same error message when creating a light box using CK Editor. The templates were intact and working for a lightbox set up previously in the same way. So it seemed a mystery event.

Overcame the problem by turning off HTML Purifier, creating the lightbox and then turning the filter back on. Don't know enough about the intricacies of the drupal system to understand why this worked but delighted it did. This may assist someone else with a similar problem.

i think , server or localhost

i think , server or localhost was fail. you can test again.

đại lý xe máy điện xe đạp điện uy tín