Relocate database connection info ? -...

User 2845737 Photo


Registered User
10 posts

My question is this, now that I have the form working is it possible to take the section of code below out of form.cfg.php and and move it higher up outside of public_html?
Then just use the php equivalent of an include command or is that going to cause issues? I mean php is server side execution so the server can access any folder it wants right?
Does that really provide any protection or can someone still see the information with a debug program or something?

I know html and javascript but php I know just enough to edit what's there. And this isn't what I do for a living hence why I'm using this software haha

Maybe I'm being paranoid, I just don't like my database password sitting there in a public area possibly for someone to see who knows what they're doing. Granted remote connections to DB are restricted to a few IP's for my own use.


Any simple examples of what the file storing the information should look like and the "include" command would be VERY much appreciated.

Thanks again guys.

-Kenny

"data_settings" :
{
"save_database" :
{
"database" : "SomeDatabase",
"is_present" : true,
"password" : "userspassword",
"port" : 3306,
"server" : "localhost",
"tablename" : "SomeTable",
"username" : "someDBuser"
},
"save_file" :
{
"filename" : "form-results.csv",
"is_present" : false
},
"save_sqlite" :
{
"database" : "UTM.dat",
"is_present" : false,
"tablename" : "UTM"
}
User 187934 Photo


Senior Advisor
20,271 posts

Hi Kenneth,
If you try to look at that page you will see that nothing shows.
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.