39,323 Topics
| |
$replacedString = str_replace(array_keys($array1), $array1, $externalVariableString); I have an entire array above that called `$championToIdConversionArray`, it has about 650 switches, it looks something like this $array1 = array( "1" => "Banana", "12" => "Monkey", "2" => "Apple", "121" => "Human" ); Now if I let script parse numbers "121", it won't … | |
# my Form # <form role="form" method="post"> <div class="form-group"> <label for="email">Email address:</label> <input type="text" class="form-control" id="email" name="email"> </div> <div class="form-group"> <label for="pwd">Password:</label> <input type="text" class="form-control" id="pwd"> </div> <button type="button" class="btn btn-default" data-toggle="modal" data-target="#myModal" name="submit">Submit</button> </form> # my Modal # <!-- Modal --> <div id="myModal" class="modal fade" role="dialog"> <div class="modal-dialog"> <!-- … | |
Hi guys! Im trying to get the ighest value from any array coming from mysql query. What i've till now is it! class vfsClass{ function localvfs() { try { $sql = $this->link->prepare("select Vfs_ID from tbl_track order by id asc"); $sql->execute(); $rs = $sql->fetchAll(PDO::FETCH_ASSOC); return $rs; } catch (PDOException $e) { … | |
How to make pagination in slim framework? i have list of deals. I have to set pagination for deal listing. | |
<div class="hor-menu "> <ul class="nav navbar-nav"> <li class="active"> <a href="index.html">Dashboard</a> </li> <li class="menu-dropdown mega-menu-dropdown"> <a data-hover="megamenu-dropdown" data-close-others="true" data-toggle="dropdown" href="javascript:;" class="dropdown-toggle"> Categories <i class="fa fa-angle-down"></i> </a> <ul class="dropdown-menu" style="min-width: 710px"> <li> <div class="mega-menu-content"> <div class="row"> <div class="col-md-4"> <ul class="mega-menu-submenu"> <li> <h3>Level 1</h3> </li> <li> <a href="add_category.php" class="iconify"> <i class="icon-plus"></i> Add Categories … | |
Hello, i have a problem with a variable i use to call a statement. The statement its ok, returns data from database as wanted, i checked it on phpmyadmin. I think that the problem is on the variable. Here is the code $select =mysqli_query($db,"SELECT * FROM table WHERE row is … | |
I have a problem with this code and i really can't understand what is it.. i have unique ID for every ticket and it works good but i have made a button to open a `modal (#myModal)` and from there to send the ticket to some username but the problem … | |
Hi, I want to run php function using jquery ajax, Task is i have two dropdown(html select) **Filter_by_class.php** <form action="filter.php" method="POST" id="filter_students_form"> <div class="field"> <label for="stud_class_filter" class="cbx-lbl lbl-width">Select Class</label> <span class="dbl-dote">:</span> <select name="studclass_filter" id="stud_class_filter"> <option value="">-- SELECT STUDENT CLASS --</option> <?php if ($getStudentClass = $db->query("SELECT * FROM classes")) { if … | |
i want to know the error in this code <?php $firstname = $_POST ['firstname']; $lastname = $_POST ['lastname']; $pass1 = md5($_POST['pass1']); $pass2 = md5($_POST['pass2']); $email = $_POST ['email']; // filters name function filtername ($field) { $field = filter_var(trim($field), FILTER_SANITIZE_STRING); if (filter_var($field, FILTER_VALIDATE_REGEXP, array ("options"=> array ("regexp"=>"/^[Z-zA-Z\s]+/")))) { return $field; } … | |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> </head> <body> <form name="entry" method='post' action=""> <label>NAME </label> <input type="text" /></br></br> <label>mobile</label> <input type="text" /></br></br> <input type="submit"/> </form> </body> </html> <?php $servername = "localhost"; $username = "root"; $password = ""; $dbname = … | |
In my project the client pay money to admin using paypal system . sometimes Admin need to return back some amount to the user .now my client ask us to done it systamatically .is it possible ? please advise on this | |
Hi guys, I am working on my PHP script as I want to add the value in the variable to add it to 5 hours forward. When I use this: <?php $links = $row['links']; $html = file_get_html($links); $base = $row['links']; $curl = curl_init(); curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE); curl_setopt($curl, CURLOPT_HEADER, false); curl_setopt($curl, … | |
Hello i want to know how create form signup php&mysql And how security form for inpot with insert data in database 1- firstname 2- lastname 3 -password 4- ُEmail | |
Dear All help me pls.. i am unable to fetch result in dropdown from database... connection.php $db = new PDO("mysql:host=localhost;dbname=test","root",""); ----------------------------------------- Add_student.php <tr> <th>City</th> <td><select name="st_city" id="st_city"> <?php echo get_option_list("city","City_id","City_name"); ?> </select> </td></tr> ----------------------------------------- functions.php function get_option_list($table,$id,$name) { $SQL=$db->query("SELECT * FROM ".$table." ORDER BY". $name); $get_list="<option value=0>Please Select</option>"; while($row=$SQL->fetch(PDO::FETCh_ASSOC)) { … | |
id,ancestor,descendant,lvl,tier_id 1, 11, 11, 0, 0 2, 11, 65, 1, 1 3, 65, 65, 0, 0 5, 11, 66, 1, 2 6, 66, 66, 0, 0 i am using closure table model. i placed tier_id cloumn there. let say new entry save in above table then tier_id should be placed … | |
Hi All, I am using php to create a Webservice API calls. I am checking all the service calls in Chrome's Postman and sending the data in JSON format. I want to upload an image in JSON format with other datas.Actually I have converted the image to base64 before uploading.Its … | |
I want to fetch Students results from this site http://202.63.105.206:8585/JNTUHResults/PortalGUI/Results/StudentResult.aspx?result=10224 1.I want to create a script ,which reads all Roll No Values(from a file) one by one and save the result in any format. 2.This script should always return same Date of Birth Value 3.This Script should copy the captcha … | |
hello daniwebers... I am really stuck with this design of tables for calendar. Here is the thing...there are employees in a specific company. Each employee accepts customers of the company per day. The number of customers is limited by the doctor on a day by day basis. So for e.g. … | |
Hi there, my table fields are. id mobile email date. Here mobile and email should be unique. How to check exisitng email and existing mobile number in php. i want to put the message separately. this is what i done . public function createUser($name, $email, $password, $mobile_no) { $response = … | |
Hi There, I'm checking if I can get all the occurrences of a variable in a php file. What will the best and easest method be? Any help is greatly appreciated. Regards | |
Hi i am currently building a admin section for my website but i am stuck at a certain point, right now my user authentication is working and my form validation is working great, when i log in as admin i want it to display the admin dash and when a … | |
Hi I am newbie to PHP. I just wanted to create a registration page for students. In that page I've populated checkboxes for students who wants to enroll more than one classes. Everything got done. But I'm stuck with the final phase of this idea. I just wanted to save … | |
I have no idea how to open extra chat box if room_id record more than 1 <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Admin</title> <script type="text/javascript" src="js/jquery-1.9.0.min.js"></script> <script type="text/javascript"> $(document).ready(function() { // load messages every 1000 milliseconds from server. (1 second = 1000milliseconds) var roomID = $('#room_id').val(); load_data … | |
Sorry, may i know what is the problem? load_data = {'fetch':1}; window.setInterval(function(){ $.post('shout.php', load_data, function(data) { $('.message_box').html(data); var scrolltoh = $('.message_box')[0].scrollHeight; $('.message_box').scrollTop(scrolltoh); }); }, 1000); $("#shout_message").keypress(function(evt) { if(evt.which == 13) { var iusername = $('#shout_username').val(); var imessage = $('#shout_message').val(); var roomID = $('#room_id').val(); post_data = {'username':iusername, 'message':imessage, 'roomID':roomID}; //send data … | |
Hi for some reason i keep getting a parse error when i try to load my view could someone tell me why it says unexpected end to file on line 20 <section id="login-landing" class="block block-gray"> <div class="container"> <div class="card card-container wow zoomInUp animated"> <a href="<?php echo base_url()?>"> <img id="profile-img" class="profile-img-card" … | |
hello how create filter for input password in php | |
Is it possible to connect USB device in the HTML page? If yes then How I can? I want to integrate Boogie Board into a dynamic page with a question. | |
Hello the valuies are not echoing when I am out side the loop <?php if(isset($_GET["catid"])) { $catid = $_GET["catid"]; $query_cat = mysqli_query($connection, "SELECT * FROM category WHERE cat_name='$catid'"); while($row = mysqli_fetch_assoc($query_cat)) { $h1 = $row["h1"]; $h2 = $row["h2"]; $span = $row["span"]; $catslide = $row["cat_slider"]; $ct_name = $row["cat_name"]; } ?> <div … | |
First of all I confess I am very new to PHP programming. Here is my problem. I just wanted to create a registration page for students. In that I need to populate the classes which the students want to enroll in checkboxes from database(because a student can enroll n number … | |
I created an add to cart function but not working properly on submit i see these errors on the place of product details Notice: Undefined variable: product_id in C:\wamp\www\connectdemo\product_details.php on line 218 etc etc.... product_details.php <?php session_start(); include_once("includes/layout/header.php"); include_once("includes/connection.php"); include_once("includes/functions.php"); if(isset($_POST["addtocart"])) { $pid = $_POST["productid"]; $prod_name = $_POST["productname"]; $prod_price = … |
The End.