39,326 Topics

Member Avatar for
Member Avatar for Charles_25

My script merges 18 files and returns all numbers that occur >=13 times within the merger. I timed my script and array_count_values is so slow it accounts for 80% of the 2.35 sec time. The files are large, 200,000 numbers per file, so the merged array is well over 2 …

Member Avatar for benanamen
0
645
Member Avatar for masimies

Hello, I have a problem to get unique values from dateperiod-loop. There is a tons of examples how to do it, but after hours of searching, i couldn't find suitable solution for me. The code starts like this. To put it into array_unigue is hard to accomplish for me. Have …

Member Avatar for benanamen
0
318
Member Avatar for random_1

I have a list.php which displays all the records that is in the database with 2 options Edit or Delete. When clicked its suppose to delete by id but instead it deleted everything. I'm not sure where i went wrong, please help. list.php <?php include "db.php"; try { $conn = …

Member Avatar for benanamen
0
349
Member Avatar for David_116

This problem's driving me crazy since yesterday. I have a table consist of 5 columns: kode_barang (item ID), nama_barang (name of item), qty (quantity), harga_beli (price), jumlah (total). User can input 2 items. This is the code of the form: <HTML> <?php include "koneksi.php"; ?> <form action="insert3.php" method="POST"> <table id="theTable" …

Member Avatar for benanamen
0
2K
Member Avatar for mattyd

Before I get into the specific issues, I want to provide some other details: - Normally, I work on a live, paid server (even in dev); I realize that is not advised, but it is a bad habit I developed over the years. I've tried using Xammp, but do not …

Member Avatar for benanamen
0
653
Member Avatar for FOYSAL_1
Member Avatar for nam_6
0
240
Member Avatar for Magic8Computing

How do i formatt the dates do the come out as DD/MM/YYYY please <?php $convar = mysqli_connect("localhost","root","","ffp_calendar"); if(mysqli_connect_errno()) { echo "Error occured while connecting with the database ".mysqli_connect_errno(); } $sqlvar = "SELECT * FROM `calendar` WHERE `CurrentDate` = curdate()"; $resultvar = mysqli_query($convar, $sqlvar) or die("Bad Query: $sql"); while($rowvar = mysqli_fetch_assoc($resultvar)) …

Member Avatar for benanamen
0
310
Member Avatar for abubaker_2
Member Avatar for rproffitt
0
655
Member Avatar for Zxander

Hello ! I have a task from my university that bothers me and I definately need some help. I have to create a web app in which i can add locations from the world map by taking the coordinates and make route between two selected locations from the added. Also …

Member Avatar for rproffitt
0
444
Member Avatar for random_1

Hi. Im new to codeigniter, so im not sure if its something wrong with the codeigniter or my php. what im trying to do is if the records from a database table is empty echo a message. The message which ,"No records exist!", does display but then underneath is is …

Member Avatar for cereal
0
428
Member Avatar for John_116

Dear All, I Made a facebook quize website, i wrote code but i have a problem, I want get my name and one of my friend name. but it didn't work. <?php session_start(); // added in v4.0.0 require_once 'autoload.php'; use Facebook\FacebookSession; use Facebook\FacebookRedirectLoginHelper; use Facebook\FacebookRequest; use Facebook\FacebookResponse; use Facebook\FacebookSDKException; use …

0
169
Member Avatar for NOVICE3

When a user enters the page in question, a textarea is populated from data from a text file stored on the server. The user can then edit that text (add, erase all or part, and modifiy). When the submit button is clicked, the edited text is written back into the …

Member Avatar for cereal
0
1K
Member Avatar for bharathi_2

I created quiz application using PHP..in that Application i display one question per page when user click on next button it display next question from database randomly..so for that i want to display time...but my problem is.. i want to display timer from starting only seconds..and user click on next …

Member Avatar for network18
0
210
Member Avatar for Mohammed_44

//The php section of the code <?php function getJSONFromDB($sql){ $conn = mysqli_connect("localhost", "root", "","rent"); //echo $sql; $result = mysqli_query($conn, $sql)or die(mysqli_error()); $arr=array(); while($row = mysqli_fetch_assoc($result)) { $arr[]=$row; } return json_encode($arr); } $jsonData= getJSONFromDB("select Pic from Display"); $jsn=json_decode($jsonData); //for loop to retrieve rows from database for($i=0;$i<sizeof($jsn);$i++){ $a=$jsn[$i]->Pic; //here is the main …

Member Avatar for network18
0
376
Member Avatar for sheik_2

Hi, Below is my code can you please help me to fix it. function gw_bbcode_html($t) { $regexfind[] = '/\&lt;(.+)\&gt;/esiU'; $t = str_replace('&amp;', '&', $t); $t = str_replace('&quot;', '"', $t); $t = str_replace('&039;', ''', $t); $regexreplace[] = "gw_bbcode_html_tag(gw_bbcode_htmlspecialchars('\\1'))"; $t = preg_replace_callback($regexfind, $regexreplace, $t); # $t = str_replace('&#', '&amp;#', $t); $t = …

Member Avatar for rproffitt
0
832
Member Avatar for subhra44

Can anyone tell me how to retrieve records from database one at a time.. I am attaching a sample code here: [CODE]include('connection.php'); $sql1="SELECT * FROM question_master"; $result=mysql_query($sql1); while($row = mysql_fetch_array($result)) { echo $row['Question']; }[/CODE] Let me explain the code.. There is a table named "question_master" (containing some questions) in database …

Member Avatar for akshay_12
0
5K
Member Avatar for Magic8Computing

How do i format my Query result so it has thousand seperator and only to 2 decimal places <!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=utf-8" /> <title>Daily Sales</title> <link rel="stylesheet" href="../styles/login.css" media="all" /> </head> <body class="normal"> <?php include("../includes/x3connect.php"); ?> <?php $sql="SELECT SUM …

Member Avatar for rproffitt
0
470
Member Avatar for Magic8Computing

Hi I have the following code that i can run in MSSQL Query and the result are returned correctly but when i try to run it in PHP it errors what do I need to change to get it to work please. SELECT SUM (CASE WHEN FFP.BPARTNER.CUR_0='GBP' THEN (FFP.SORDERQ.YORIQTY_0 * …

Member Avatar for Magic8Computing
0
410
Member Avatar for idaryl

I am trying to get a small plugin Im putting together to work from the admin page - I have the functrion working, although it would be better to "activate" it from that page *the default would be "OFF" here is a copy of the function - it just turns …

0
172
Member Avatar for mattyd

I have recently been using XAMPP for dev. Although I'm new to XAMPP, the recent issue sprung up surprisingly, the simple script running a day before. The script is just being used to test the ability to capture/display an IP address; this will later be used in a larger project: …

Member Avatar for mattyd
0
631
Member Avatar for Online Check

I have a website name onlinecheckwriter.com which helps my client to print check online. Right now I'm facing one problem that I didnt find any vendor that provide offical routing never verification api. Right now our customer add routing number but I need cross check it with bank . So …

Member Avatar for rproffitt
0
666
Member Avatar for davy_yg

How to take part of url and store it into a variable? For example: /home/pages/id --> I want to take id out and store it into $id. How to do that?

Member Avatar for diafol
0
376
Member Avatar for spades0001

Greetings! I am trying to connect my android application to a MySQL database. The app serves as a tool for lawyers providing them features such as: - a calendar wherein they can add and view events -an agenda list wherein they can see a list of their agendas -a notification …

Member Avatar for HitsuGaya198
0
4K
Member Avatar for davy_yg

Hello, This time I am having problem with html tag. pages.blade.php <section id="container"> <menu></menu> <cont> <center><b>{{ $pages2->pages_title }}</b></center><br> {!! $pages2->pages_content !!} </cont> <sidenav> @foreach( $pages as $p) <a href="{{url('')}}/home/pages/{{ $p->id }}">{{ $p->pages_name }}</a><br><br> @endforeach </sidenav> </section> If I let the html appears: {{ $pages2->pages_content }} This is the title and …

0
216
Member Avatar for borgyborg

newbie here! I am working with a simple PHP form with few fields and few uploads. I want to use the Modal pop up form for this. Below codes are working fine. I was able to insert the fields into MYSQL successfully but I don't know how to add file …

Member Avatar for diafol
0
3K
Member Avatar for Patiodude

I run a website where I periodically post articles. I'd like to add a timestamp/datestamp to each article showing the post date (the upload date, I assume, would be the logical choice). I had already asked for advice on this topic; unfortunately, the result is a blank. Literally. Here's an …

Member Avatar for Ty omotayoo
0
725
Member Avatar for සශික

I'm developing some kind of web application simillar to forum. I want to show comments under which it belongs to. I currently used bootstrap, php, mysql for this. Here I post my code.... <div class="col-md-7"> <div class="col-md-12"> <form action="insert_post.php" method="post"> <div class="input-group"> <p><b>You Are Posting As : </b></p><h4><span class="label label-default"><?php …

Member Avatar for diafol
0
509
Member Avatar for sanus

Hi everybody, How to add option target=>_blank in my code. <?= Html::submitButton($model->isNewRecord ? ' <i class="fa fa-save"></i> Save & Print' : ' <i class="fa fa-save"></i> Save & Print', ['target'=>'_blank'] , ['class' => $model->isNewRecord ? 'btn btn-success' : 'btn btn-primary']) ?>

Member Avatar for sanus
0
236
Member Avatar for jeffersonalomia

Hi, I would like to ask for help with regards on my problem on my phpmyadmin - mysql database. I am using wamp server 2.5. So here's the scenario, I try to insert data on two tables (accounts, user_info) on mysql @ phpmyadmin using php ajax. Now the problem is …

Member Avatar for diafol
0
262
Member Avatar for eoop.org

Hello, I have been strugling with this for a while. Is it possible to create a loop that will make this function run automaticly. I want to type in how many times it should repeat the pattern. For example, i want to run to $sum20 Please help me out! <?php …

Member Avatar for diafol
0
397

The End.