# Pulling info from the database

**URL:** <https://forum.mautic.org/t/pulling-info-from-the-database/5030>\
**Category:** Development\
**Created:** [August 23, 2016, 5:54pm UTC](https://forum.mautic.org/t/pulling-info-from-the-database/5030 "2016-08-23T17:54:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![newb](https://avatars.discourse-cdn.com/v4/letter/n/2acd7d/32.png) [@newb](https://forum.mautic.org/u/newb)\
**Post date:** [August 23, 2016, 5:54pm UTC](https://forum.mautic.org/t/pulling-info-from-the-database/5030/1 "2016-08-23T17:54:45Z")

</div>

I would like to expand the Widgets and get info that isn’t currently being offered in the Dashboard.  
  
  
  
However, I’m having a hard time figuring out which file(s) to edit to code with Mautic “standards.”  
  
I can code with PHP/MySQL, but OOP PHP programming and Symfony are both very new to me.  
  
  
  
For example, I have raw PHP code that has the data I need - where I do insert that and how can I find Mautic’s preferred method of querying the database (assuming it is a public function).

---

<div class="post-metadata">

**Author:** ![newb](https://avatars.discourse-cdn.com/v4/letter/n/2acd7d/32.png) [@newb](https://forum.mautic.org/u/newb)\
**Post date:** [August 23, 2016, 5:54pm UTC](https://forum.mautic.org/t/pulling-info-from-the-database/5030/2 "2016-08-23T17:54:45Z")

</div>

I would like to expand the Widgets and get info that isn’t currently being offered in the Dashboard.

However, I’m having a hard time figuring out which file(s) to edit to code with Mautic “standards.”  
I can code with PHP/MySQL, but OOP PHP programming and Symfony are both very new to me.

For example, I have raw PHP code that has the data I need - where I do insert that and how can I find Mautic’s preferred method of querying the database (assuming it is a public function).

---

<div class="post-metadata">

**Author:** ![newb](https://avatars.discourse-cdn.com/v4/letter/n/2acd7d/32.png) [@newb](https://forum.mautic.org/u/newb)\
**Post date:** [August 24, 2016, 3:00am UTC](https://forum.mautic.org/t/pulling-info-from-the-database/5030/3 "2016-08-24T03:00:44Z")

</div>

To extend my original post…

I’d love to contribute any improvements (once I get the hang of Mautic) to git. I realize modifying the core code will be overwritten upon the next update.

To summarize:  
I want to modify /s/dashboard

I can do so easily by editing app/bundles/DashboardBundle/Views/Widget/detail.html.php and adding my raw code there. However, this is not in line with Mautic standards. Where may I determine the source of adding a currently nonexistent widget? (No, the info/function doesn’t presently exist in the Add Widget menu)

I’ve inspected app/bundles/DashboardBundle/Form/Type/WidgetType.php and ashamed to admit, not sure where to go next.

(Apologies for the obscenely newbish question)
