Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8593939
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T00:05:57+00:00 2026-06-12T00:05:57+00:00

Right now, im using drupal for making a site. Im modifying the drupals user

  • 0

Right now, im using drupal for making a site. Im modifying the drupals user module, because i need to make a custom layout for the profile page.

Unfortenly im having issues for accessing trough the array.

all the data of the profile is on an array ($user_profile)

The array is just HUGE. im trying to navigate trough the objects.

While im doing a good job navigating (thanks to the print_r function), im facing a problem right now.

there’s an object called entityInfo:protected. Inside this object there’s more objects (by example, im trying to access to the object that is inside of this object, called label.

the issue is, if i try to do this:

echo $user_profile['profile_medico']['view']['profile2']['2']['field_tags']['#object']->{'entityInfo:protected'}->label 

I get the next message

Notice: Undefined property: Profile::$entityInfo:protected in include() (line 55 of D:\xampp\htdocs\specialdr\modules\user\user-profile.tpl.php).
Notice: Trying to get property of non-object in include() (line 55 of D:\xampp\htdocs\specialdr\modules\user\user-profile.tpl.php).

I dont know how can i write this correctly so i can access to this object and keep going trough the arrays and objects… because i still have a loong way until i get to the objects i need to access.

By the way… if you want to see the array… http://fancomix.net/bigarray.txt

Thanks in advance.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T00:05:58+00:00Added an answer on June 12, 2026 at 12:05 am

    It is simply ->entityInfo, :protected is not needed, it is an access modifier or visibility modifier. It is only displayed in the var_dump() to provide information about the property. An object property (and method also) can be declared either public, protected or private in PHP. You can read more about Visibility in the Manual.

    protected means the property can only be accessed from an object method – no outside access, so you won’t be able to get the property. The Profile class can have a getter method though – you should inspect the definition of that class to find it, or make necessary changes if you can, like changing it to public or writing a getter method.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Right now I am using a custom list view and I am inflating an
I need a random 4 digit number right now im using rand(1000,9999) that always
Running a rails site right now using SQLite3. About once every 500 requests or
I am building a site right now using the new siFR3 it works perfectly
We are using a Java EE application and we are right now using Informix
Right now I am using sqlite within a ios application, and I want to
Right now I am using std::pair to represent a 2d point in c++. However,
Right now I currently using transactional replication with updatable subscription. Is there any ways
Right now I'm using a few scripts to generate files that I'm including as
Right now I'm using the following: export CFLAGS=-O2-isysroot/Developer/SDKs/MacOSX10.5.sdk -arch i386 -I/sw/include/ export LDFLAGS=-Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk,-L/sw/lib/ sudo

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.