Go Back   CodingForums.com > :: Server side development > PHP

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 07-12-2012, 01:13 AM   PM User | #1
Cynephoba
New Coder

 
Join Date: May 2012
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Cynephoba is an unknown quantity at this point
Database Security

Hey.

On my current website I have a PHP file with my database connection information, which connects to the daetsbase and completes a query When I need to use it on a page, I call this other php page, and output the query - as I use the same query on multiple pages. Just wondering if there is a way to stop people from getting the source code of this page, so that they cannot end up with my db connection information.

Thanks.
Cynephoba is offline   Reply With Quote
Old 07-12-2012, 09:44 AM   PM User | #2
Dormilich
Senior Coder

 
Dormilich's Avatar
 
Join Date: Jan 2010
Location: Behind the Wall
Posts: 2,907
Thanks: 10
Thanked 293 Times in 289 Posts
Dormilich is on a distinguished road
see http://www.codingforums.com/showthread.php?t=267591. unless your server is misconfigured or the file does not have the .php extension, PHP source code never leaves the server.
__________________
please post your code wrapped in [CODE] [/CODE] tags
Dormilich is offline   Reply With Quote
Old 07-12-2012, 10:13 PM   PM User | #3
Cynephoba
New Coder

 
Join Date: May 2012
Posts: 15
Thanks: 0
Thanked 0 Times in 0 Posts
Cynephoba is an unknown quantity at this point
Ok thanks.
Cynephoba is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 04:00 AM.


Advertisement
Log in to turn off these ads.