idy Posted September 29, 2006 Share Posted September 29, 2006 Hello !I have put the results of an SQL query into a PHP array. I then pass on this array into a javascript array to manipulate these data in javascript (especially with google maps). But if I click on View source code, anayone can display the full content of this javascript array. How could I hide these data ?Thanks for your help ! Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/ Share on other sites More sharing options...
printf Posted September 29, 2006 Share Posted September 29, 2006 There is no way to hide it, unless you use the httprequest object right on your page. It still not hidden, but it will not be written on to the output page!me! Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/#findComment-101141 Share on other sites More sharing options...
idy Posted September 29, 2006 Author Share Posted September 29, 2006 OK so if I understand correctly, you mean I should try to do some Ajax stuff there ?Is it the case for instance on that site http://www.propsmart.com/homes-for-sale/US/San-Francisco-metro ? Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/#findComment-101148 Share on other sites More sharing options...
printf Posted September 29, 2006 Share Posted September 29, 2006 Yes, the normal user does not see the data because it's not written to the page, it is written to a variable assignment and held in memory. If advanced user wants to see the data, you can't stop them from writing a script to do it. But for the normal user, that never is the case! me! Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/#findComment-101150 Share on other sites More sharing options...
jerastraub Posted September 29, 2006 Share Posted September 29, 2006 Idy, I just want to say, I love your map feature, haven't seen anything quit like it for real estate. Very user friendly! Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/#findComment-101151 Share on other sites More sharing options...
idy Posted September 29, 2006 Author Share Posted September 29, 2006 Just to make sure, the way you suggest me to go round the problem vs. the normal user is to use Ajax if possible ?jerastraub > I am actually trying to get some inspiration from the website I mentioned... I wish I could do such a job, but alas, this is not my work ! Link to comment https://forums.phpfreaks.com/topic/22541-view-source-code-reveals-all-the-content-of-my-database/#findComment-101156 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.