I wish to add some code like php or other to obtain, for example, a personal home screen with a avatar and personal text when the users log in into the website.
How can I accomplish this?
How can I get the data stored in the users database to display this information?
I understand that I can create single pages with the aid of php.
I suppose I can put them into the application/single_pages directory.
But where do I put than the CSS or JS files attached to this single page file?
I did also try to access my database because I wish to retrieve some Users-data stored in the database.
I did find the table Users with the id, name and email. But i did not find the profile photo.
Can you tell me where this foto is stored and how I retrieve this?
I hope that you are not upset with all these silly questions.
I like the concrete5 CMS but there are not so many tutorials like there is for instance for wordpress.
in fact I regret this a little. nevertheless I hope that I will succeed with my mission.
thank you for your reply.
Stefaan De Reu
> Op 7 aug. 2017, om 16:58 heeft concrete5 Community <[email protected]> het volgende geschreven:
I'm don't mind you asking questions, that's what this forum is for. I'm
glad to help. You need to know some php to customize the single page.
You need the take the default.php or view.php pagetype template (I think
it's the view.php) from the theme you are using and copy the content to
your new, empty profile single page which you indeed put in the
application/single_pages directory. Copying this content is necessary
because it contains the header and footer inclusions while the default
profile page doesn't because it uses the back end style.
This page is now overriding the default profile page. Then you take the
code parts from the default profile page and put them in your page. You
might also have to apply the theme to the page through the dashboard or the
page properties, I'm not sure.
The avatar is a user attribute and is not stored in the users table. It's
stored in the files folder of your website unless you are using a CDN
(content delivery network). You can retrieve it programmatically as you do
with any other user attribute. There's another single page that is used to
update the user avatar. If you look in the controller and template you can
see how this works (retrieving and storing).
C5 could definitely do with some more tutorials but it just had a major
overhaul going to 5.7 and it takes time for documentation and tutorials to
I'm not behind a computer right now so I can't give you a more detailed
example right now. See if this works for you and otherwise I'll have a look
when I get back tomorrow.
On Aug 7, 2017 15:10, "concrete5 Community" <[email protected]>