[Solved] How do i MD5 crypt password at registration?

[ad_1] You need to use like that for your INSERT Statement: $user_password= md5($_REQUEST[‘user_password’]); Now how can you select md5() password from database after insertion? Its very simple, you must need to follow same step: $user_password= md5($_REQUEST[‘user_password’]); // your input with md5 MD5() PHP Manual As per manual, it will return you the hash as a … Read more

[Solved] I want calendar to appear when pressed on my date textfield and the user should be able to select date from that calendar [closed]

[ad_1] HTML5 browsers have built-in support for date pickers. To do what you are asking you only need to change the type of your input field to date. Like this: <input id=”date”type=”date” name=”text” class=”input”> [ad_2] solved I want calendar to appear when pressed on my date textfield and the user should be able to select … Read more

[Solved] Timer recorded in php

[ad_1] You could use setInterval to increment some number every second, starting the interval when the input gets focus, and clearing the interval when it loses focus. var timeSpent = 0; var interval; document.getElementById(‘password2’).addEventListener(‘focus’, function() { interval = setInterval(function() { timeSpent++; document.getElementById(‘timeSpent’).value = timeSpent; }, 1000); }); document.getElementById(‘password2’).addEventListener(‘input’, function(event) { if (interval && event.target.value === … Read more

[Solved] Error: you have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use

[ad_1] Error: you have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use [ad_2] solved Error: you have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use

[Solved] displaying the html entities in php code

[ad_1] Use PHP pre defined $_SERVER variable : $_SERVER[‘PHP_SELF’] <html> <body> <form action=”<?php echo $_SERVER[‘PHP_SELF’]; ?>” method=”post”> <input type=”text” name=”keywords” id=”keywordsid” value=”sample keyword” /> <input type=”submit”> </form> <?php if(isset( $_POST[‘keywords’])) { echo $_POST[‘keywords’]; } ?> </body> </html> Here, <?php echo $_SERVER[‘PHP_SELF’]; ?> helps you to get result on the same page without sending the request … Read more

[Solved] I need to join two tables in php [closed]

[ad_1] This code did not suddenly stop working, it never could have worked with its present query syntax. Change the query to this – $q2 = $pdo -> prepare(‘INSERT INTO allbets (user, bet, komanda, teams, cof, data, image) VALUES ($user, $bet, $komanda, $teams, $cof, $data, (SELECT `users2`.`image` FROM `users2` WHERE `username` = ?)); Do yourself … Read more

[Solved] Notice: Array to string conversion ERROR [closed]

[ad_1] First you need to change: foreach ($traits[$i] as $trait) To: foreach ($traits as $trait) Then realize that $trait is still an array. So instead of echo ‘<BR>’.$trait, $test, $i + 1; You want to still loop through that array: foreach($trait AS $value) Now you can echo out your $value foreach ($traits as $trait) { … Read more

[Solved] Downloading files with curl in PHP [closed]

[ad_1] Im not sure what is your problem. If you just don’t know how to use CURL – here you have example: $oCurl = curl_init(); // initialize curl object $url=”http://domain.com/page”; curl_setopt($oCurl, CURLOPT_URL, $url); // set URL $siteContent = curl_exec($oCurl); // you will get HTML or other file contents here 0 [ad_2] solved Downloading files with … Read more

[Solved] jquery ajax fileupload [closed]

[ad_1] It is inevitable that you will have to use a “plugin” to your definition, but… Here’s the good news: There’s a really good, easy to use, simple to code jQuery-File-Upload by blueimp that you can Download Here. You wanted it simple: Since you are looking for it to be a simple, basic jQuery… You … Read more

[Solved] Notice: Undefined variable: [closed]

[ad_1] The error is here: if($admin_username && $admin_password && $admin_token == session_id()) It seems quite likely this is line 63. The problem is you are only defining $admin_username if $_SESSION[‘admin_username’] is set. Although you don’t show it in your code example, I’d presume that the same thing is true of $signin_username. Solution #1 – use … Read more