Bienvenue, Invité
Nom d'utilisateur : Mot de passe :


This Help forum is for issues relates to the latest release (1.0). For issues related to beta or svn version please use their own Help forum.
When requesting help please provide as much information as possible. Explain what version of webtrees, PHP and MYSQL you are using. If possible provide a URL to your site so we can see the problem first-hand.
Tip: Think about putting these details in your signature, so it appears in the footer of ALL your messages

SUJET : "ERROR 2" on My Page

"ERROR 2" on My Page il y a 8 ans 10 mois #1

  • alroe
  • Portrait de alroe
Hi, we just installed webtrees version 1.06 and it seems to work ok. There is an error on My Page, however, below the two boxes "On This Day ... " and "No events exist for today" (see below). Any ideas on what may be the problem?
Hugo

ERROR 2: require(templates/personbox_template.php) [function.require]: failed to open stream: No such file or directory
0 Error occurred on line 361 of file functions_print.php in function print_pedigree_person
1 called from line 361 of file functions_print.php in function print_pedigree_person
2 called from line 206 of file module.php in function getBlock
3 called from line 135 of file index.php

Warning: require(templates/personbox_template.php) [function.require]: failed to open stream: No such file or directory in /home/xxxxxx/aner/includes/functions/functions_print.php on line 361

ERROR 2: require(templates/personbox_template.php) [function.require]: failed to open stream: No such file or directory
0 Error occurred on line 361 of file functions_print.php in function print_pedigree_person
1 called from line 361 of file functions_print.php in function print_pedigree_person
2 called from line 206 of file module.php in function getBlock
3 called from line 135 of file index.php

Warning: require(templates/personbox_template.php) [function.require]: failed to open stream: No such file or directory in /home/xxxxxx/aner/includes/functions/functions_print.php on line 361

Fatal error: require() [function.require]: Failed opening required 'templates/personbox_template.php' (include_path='/home/xxxxxx/aner/library:.:/usr/local/lib/php') in /home/xxxxxx/aner/includes/functions/functions_print.php on line 361
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #2

  • fisharebest
  • Portrait de fisharebest
  • Hors Ligne
  • Administrator
  • Messages : 11556
The error would appear to be from a "User favourites" block.

Do you have this block? Do you have any favourites listed within it?
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #3

  • alroe
  • Portrait de alroe
Yes, we have the User Favourites block on My page (I dont know where to configure this, though). And yes, I have a user favourite, I can see this in the link to Favourites in the Menu.
I looked at another user who did not yet have a user favourite, and here the box was shown on My page and no error. However, when I chose a favourite for that user, the error came on that page as well.
On the front page, the database favourite is shown without errors.
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #4

  • ToyGuy
  • Portrait de ToyGuy
  • Hors Ligne
  • Moderator
  • Live like it's Christmas every day - Santa Stephen
  • Messages : 4925
Hugo
You may not be aware that there is a difference between Favourites selected by the admin for site wide application, and personal favourites. You configure the personal favourites using the personal block on your My Page (block title is My Favourites) and add to it using the configuration link at the bottom of the block, "Add a new favourite". The site favourites block is similar, but located on the Home Page and configured there in the same fashion. Site-wide Home Page favourites should appear on every user and casual visitor's pages while personal (My) favorites will appear only on a single person's pages. If existing for that user, they will both appear in the menu at the top, and then separately on the Home and My Page page blocks.

The code may be confused if the block is present on your 'My Page', but have no favourite specified. This should not be the case as selection is not mandatory, but could be, and identifying this would be helpful as a clue to the error.
Thanks,
Santa Stephen the Fabled Santa
Latest webtrees at MyArnolds.com
Hosted by webtreesonline.com, a division of GeneHosts LLC
MacOS 10.6.8, Apache 2.2+, PHP 5.4.16, MySQL 5.5.28
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #5

  • fisharebest
  • Portrait de fisharebest
  • Hors Ligne
  • Administrator
  • Messages : 11556
At first glance, it would appear that the theme is undefined. Does this affect all themes. Do you have a custom theme?

This *could* be a coding error (FYI, the relevant code has been updated since 1.0.6), however, I cannot reproduce this error in either 1.0.6 nor the latest code.

Fixing errors that you cannot reproduce is very difficult.

Without more information, I can only suggest waiting until the next release (middle of January?)
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #6

  • alroe
  • Portrait de alroe
Yes, the error looks the same in all themes, and we don't use a custom theme. I don't know what might cause the error on our site and not on other sites, but I understand that you cannot do more. It is only a minor error, so I will wait and see whether the update removes the error. Thanks for looking into it.
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 10 mois #7

  • kiwi
  • Portrait de kiwi
  • Hors Ligne
  • Platinum
  • Messages : 4965
While you wait (and I wouldn't be at all confident any code change will fix this, as all other sites seem to work OK), have you checked that the files referred to in the error do exist?
ERROR 2: require(templates/personbox_template.php) [function.require]: failed to open stream: No such file or directory

There should be this structure within each theme folder, such as /themes/webtrees/templates/personbox_template.php. In fact there should be three files in each "templates" folder.
Nigel

www.our-families.info

Hosted at:
Follow me at:
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 8 mois #8

  • daj
  • Portrait de daj
I think there is more to this than you may think. I know this is a old post but I was searching as I now have the same problem.

Everything was working fine for a user on my test system and then I customized the front page and added user Favourites and (I think) 'up and coming events'.

I now get the same error
ERROR 2: require(templates/personbox_template.php): failed to open stream: No such file or directory
If you think about this a little more you will see that the Theme directory has not been tagged onto the require statement -- one would expect 'theme/<themename>/' to preceded the filename ?

The next line of the error tells me that the 'require' statement in on line 361 of functions_print.php. I looked at the line and see $THEME_DIR should be prepended. A quick hack of the script to print the variable shows me that $THEME_DIR is blank :-o

If I change the variable to WT_THEME_DIR it solves the problem and the script moves on, but errors again with a similar problem. It would appear that $THEME_DIR is being cleared somewhere --Yes/No?
Dernière édition: il y a 8 ans 8 mois par daj.
L'administrateur a désactivé l'accès en écriture pour le public.
Avez-vous besoin d'une solution d'hébergement web pour votre site webtrees ?
Si vous préférez un hébergeur spécialisé de webtrees, la page suivante en liste quelques-uns capables de vous offrir ce type de service :

Re: "ERROR 2" on My Page il y a 8 ans 8 mois #9

  • kiwi
  • Portrait de kiwi
  • Hors Ligne
  • Platinum
  • Messages : 4965
As we are only hours away from releasing ver 1.1.0, I would recommend you wait briefly then try that version, as per this comment:
This *could* be a coding error (FYI, the relevant code has been updated since 1.0.6), however, I cannot reproduce this error in either 1.0.6 nor the latest code.

Fixing errors that you cannot reproduce is very difficult.

Without more information, I can only suggest waiting until the next release (middle of January?)
Sorry the release is later than "middle of January", but it WILL be out in a few hours.
Nigel

www.our-families.info

Hosted at:
Follow me at:
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 8 mois #10

  • fisharebest
  • Portrait de fisharebest
  • Hors Ligne
  • Administrator
  • Messages : 11556
Hi David,

Your investigation and diagnosis are correct. $THEME_DIR has been replaced with WT_THEME_DIR.

From the line-number, I'm guessing you are using webtrees 1.0.6

This bug has already been fixed, and the 1.1.0 release (tomorrow?) will include it.

Greg
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 8 mois #11

  • daj
  • Portrait de daj
Thanks Nigel.

I will look forward to the update, and I can report back.

I did hear one was coming soon so I am waiting with some anticipation as there are several things I hope will get fixed but I have held off on reporting them. I have been busy themeing while I waited on an update, but this particular problem has floored me as I do not know how to fix the problem for that user now (so they can not login). It's a test system at the moment anyway so not a biggie
L'administrateur a désactivé l'accès en écriture pour le public.

Re: "ERROR 2" on My Page il y a 8 ans 8 mois #12

  • daj
  • Portrait de daj
Greg, thanks
fisharebest écrit:
Hi David,
Your investigation and diagnosis are correct. $THEME_DIR has been replaced with WT_THEME_DIR.

From the line-number, I'm guessing you are using webtrees 1.0.6
Yes, I'm on 1.0.6
This bug has already been fixed, and the 1.1.0 release (tomorrow?) will include it.
i'm excited :-)
L'administrateur a désactivé l'accès en écriture pour le public.
Propulsé par Kunena