Relative Content

Tag Archive for phpmysql

I am struggling to get prefill data while editing document in php

<?php session_start(); include ‘../config.php’; // Check if user is logged in if (!isset($_SESSION[‘id’])) { echo (“<script LANGUAGE=’JavaScript’> window.alert(‘Please Login First..!!!’); window.location.href=’index.php’; </script>”); exit(); } $id = $_GET[‘id’]; $query = “SELECT * FROM tbl_associate_master WHERE id = ?”; $stmt = $conn->prepare($query); $stmt->bind_param(‘i’, $id); $stmt->execute(); $result = $stmt->get_result(); $associate = $result->fetch_assoc(); $stmt->close(); include ‘intelmark_head.php’; include ‘intelmark_sidebar.php’; ?> […]

password_verify() returning false, even though both values are same

<?php $A = ‘ABCD’; $B = ‘ABCD’; $md5A = md5($A); //cb08ca4a7bb5f9683c19133a84872ca7 $md5B = md5($B); //cb08ca4a7bb5f9683c19133a84872ca7 echo “Using the password_verify() funtionn”; if (password_verify($md5A, $md5B)) { echo “True”; } else { echo “False”; } echo “nUsing the Using the == copmparisonn”; if ($md5A == $md5B) { echo “True”; } else { echo “False”; } ?> password_verify() returning […]