Jump to content

jimfog

Members
  • Content count

    1,744
  • Joined

  • Last visited

  • Days Won

    1

jimfog last won the day on December 17 2011

jimfog had the most liked content!

Community Reputation

30 Excellent

About jimfog

  • Rank
    Dedicated Member
  • Birthday 10/28/1979

Contact Methods

  • MSN
    papageorgiou40@hotmail.com

Profile Information

  • Location
    Athens, Greece
  • Interests
    Computing, in any form of it, whether is web development, control theory or other, enjoy reading history books, especially WWII books, movies, fast cars(i do not have one, just a humble toyota yaris).

Previous Fields

  • Languages
    Englsh, Greek
  1. radio buttons checked..how to

    Your answer is very general and it does not address my issue....and you say there is identical ID...I see none. It seems your answer is relevant after all....I found the cause of the problem but for the time being I do not know how to solve it.
  2. radio buttons checked..how to

    In my app a business user fill in a form the services he/she offers along with the option if the prices of them are to be visible to the end-user. And if at sometime he/she wishes to edit these data he/she clicks the edit button...presented to him/her like this fiddle. You can see what happens when the user clicks the edit button. And now my problem: Focus on the price visibility section...when the edit button is clicked the radio button checked must be the one the user has selected from before.If the user has opted for price visibility then the radio button checked must reflect this...(yes in this case).In the JS pane you see code that gathers the values witch reperesent this(in both services this is 1 and this means the user has opted for price visibility in both services). The problem is that the radio button of only one service is selected...the other ought to be also(the top)...but it does not.We have the value of 1 also for the top service....as such YES must be selected too. So there must be something wrong with the JS code...specifically with the replace HTML method. I tried to be clear,if there is something you do not understand ask me to clarify further.
  3. serialize or not?

    I have a series of inputs(and more can be added by clicking the plus icon):https://jsfiddle.net/fiddlehunt/pu4qqnrd/ In the left input user enters service(s) and in the right price(s) and these must be sent with AJAX to the server... From a little search serialize() can do this but there is a problem. suppose that the values to be sent are these:service1 and 55...service name and it;s price...take a look what is sent to the server. form%5B0%5D%5Bservice%5D=service1&form%5B0%5D%5Bprice%5D=55 Many meaningless characters...is there something I can do to clean this string before or after it reaches the server or... serialize() maybe not the best solution for this type of problem after all....what do you think?
  4. netbeans message about superglobal arrays

    Ι assume that this means using after all filter_input()
  5. I am using netbeans to code PHP...when using a superglobal array such as $_POST for example I get frequent the message that I should not access them directly for security reasons. I know the reason behind that and and the solution(filter_input). The question is if it is so safety critical that I should use filter_input in superglobals. Where it is critical,such as in database inserts I use prepared statements...but what about in other cases? Such as this for example: if(trim($_POST['email'])=='') { //do this } Must I use a filtering function?
  6. throttling login atempts

    Tell me if I got this right cause I am little confused... There are 2 cases when throttling must be applied to a form...when an attacker performs an attack(dictionary attack,brute force etc) to a single account. In the above case throttling must be activated in this specific account AND when there is distributed brute force attack at which case throttling must be activated to ALL of the accounts. Am I correct?
  7. trying to set session cookie parameters...

    I agree... Nonetheless...before setting the parameters in every site page I must be certain that the "thing" works. So...in order to test it I just placed the code in one page and hit refresh.
  8. trying to set session cookie parameters...

    After deleting the session cookie and refreshing the page the login screen appeared(something to be expected as the session was destroyed)...a logged in again and a new cookie was sent...meaning that the code still has no effect. I must add this: When the user logins he/she is redirected to a page called appointments.php(it is the home page of a logged in user)...the code is found there. It is not the page where the session is set originally....so I am wondering if the code must be placed in the page where the session is set original. I just placed the code in appointments.php and did the testing there.
  9. I trying to set the session cookie parameters using the function session_set_cookie_parameters.Here is the code: $sesarr=session_get_cookie_params();//I use this function here to grab the data and padd them below session_set_cookie_params($sesarr["lifetime"],$sesarr["path"],$sesarr["domain"],TRUE,TRUE); session_start(); Now....according to the manual if the secure option is set to true(as the case above) the cookie will only be sent if the connection is secure. I do my testing to a local machine(localhost) and as such the connection is not secure. Despite that the cookie is sent after all...I can see that from chrome dev tools. Any idea why this might be happening?
  10. markup problem with a form

    What I cannot understand is how to use conditionals to achieve this. Here the form must appear when the link is clicked which is an if(isset['GET']) { //form } Yes but we also must take into consideration when the submit button is clicked: if (isset($_POST['submit'])) { //form } So my problem now is how to combine these two...and as you said having one form.
  11. markup problem with a form

    I am facing a problem with the markup of a registration form. The user is presented with some links and each of them when clicked leads to a registration form-so far everything is OK. But when the submit button is clicked(and if errors are found) the user is taken to the registration form again-but this time the markup is different,the errors displayed. In other words I have markup in my HTML file for two different registration forms(I mean the form is the same of course but the one appears when the link is clicked and the other when the submit button clicked.) Take a look here http://hastebin.com/iriqiyepom.xml : It is a mess...there are times that in the screen the same form appears twice. How I could clean it up? The reason that lead me using 2 forms is that the second contains markup for errors shown(span elements).
  12. form data problem

    yes....modifying form action value seems to do the job and transfer data from page to page...
  13. form data problem

    Take a look again at the code at line 17:http://hastebin.com/fomibewiqe.scala what gets sent to the server must be values like '1'.You must modify your acode according to that before I can test it. I can do it myself but since you started it I want you to complete it please. It is important that this little detail gets settled before continuing.
  14. form data problem

    My page has 2 links that when one of them is clicked a registration form appears. The links correspond to different type of business.This info must be passed to the registration form and sent to the server with $_POST. The way I do this you can see that here http://hastebin.com/fomibewiqe.scala (along with other code) at line 17. And here is my problem: So,when I click the submit button the btype value is sent to the server. But Imagine this for a while: I click the submit button, an input is empty,I get a warning,I fill it and then click the submit button again(second time). $_GET['Btype'] gets to be udefined. The reason for this being that when I click the submit button second time the URL is this: /form/php,,,, btype query parameter is absent from the URL and as such it gets to be undefined. WHat can I do?
  15. read more links...blog posts

    You are right.
×