Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Access appSettings from TActionControllers #15

Closed
adderly opened this issue Feb 7, 2014 · 2 comments
Closed

Access appSettings from TActionControllers #15

adderly opened this issue Feb 7, 2014 · 2 comments

Comments

@adderly
Copy link

adderly commented Feb 7, 2014

Hellos Gentlemen,

I was digging in the source code for a way to access the application settings from a controller and there is actually no way to access the already loaded ones in TWebApplication. Which i guess are the ones in application.ini.

I think it will be handy to access the quickly. I still don't know how the framework handle the dispatch of these controllers, to write this code will take too much time (I am willing to do it if anyone give me a hint where to do it ;) ).

@treefrogframework
Copy link
Owner

You mean this?
Tf::app()->appSettings();

Reference: http://treefrogframework.org/tf_doxygen/index.html

@adderly
Copy link
Author

adderly commented Apr 7, 2014

Yeah that exacly.
from a controller you can do this, which i didn't know.

TWebApplication* app =Tf::app();
app->appSettings();

@adderly adderly closed this as completed Apr 7, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants