10,940 Topics

Member Avatar for
Member Avatar for jj.dcruz

i have to backup my database via php codes but i always ended up with an empty file? <?php include "connection.php"; $command = 'mysqldump -u root -p ***** –all-databases > dump.sql'; exec($command) or die(mysql_error()); ?> any help would be great

Member Avatar for jj.dcruz
0
265
Member Avatar for sushilsth

i am actually working for showing online for loged in user. This is my code: $qt="select userid from plus_login where tm > '$tm' and status='ON'"; $result = mysql_query($qt); while($row=mysql_fetch_array($result)) { $uid = $row['userid']; $qt1="select first_name, last_name from signup where user_id='$uid'"; $result1 = mysql_query($qt1); while($rows=mysql_fetch_array($result1)) { $_SESSION['name']=$rows[0]." ".$rows[1]; echo $_SESSION['name']."<br>"; } …

Member Avatar for diafol
0
206
Member Avatar for dawbin

I'm an experienced ASP/MSSQL programmer trying to make the move to PHP/MYSQL and I've been able to wrangle my way up to now. I have a simple SQL query that works great in mymcadmin but gets lost in PHP. I've simplified it a bit here but this is the actual …

Member Avatar for iamthwee
0
237
Member Avatar for jacob21

I have a column name descrption in a table.. descrption contains multiple rows like claim for my new mercedes purchase my new car ------ ----- I am trying to explode each row and save each entery in a new column. claim :save in split1 for:save in split2 my:save in split3 …

Member Avatar for broj1
0
198
Member Avatar for johnef_sh

I need to upload 5 images at ones with they labels I have made this before to upload many images at one it works fine but I need to have an label for each image how this can be done take a look at my code. this is the HTML …

Member Avatar for Mike_danvers
0
490
Member Avatar for LaurenE

Good Day Daniwebbers! Wonder if I can have some help. I am trying to build an 'admin panel' of sorts where the user can add content to their website, edit and delete it, all from one spot (Not unlike a CMS system I guess but purely for the purpose of …

Member Avatar for LaurenE
0
196
Member Avatar for CarterLangley

Me again, I have the following which should generate a form and populate that form. <?php session_start(); include("db_connect.php"); if(($_SESSION['user_id']) && ($_SESSION['access_level'] == 1 )) { ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <head> <title>Teaching Int Limited - Home</title> <meta name="title" content="Teaching Int Limited"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta …

Member Avatar for CarterLangley
0
301
Member Avatar for PriteshP23

Hello, I have used Single Translation Table Approach to make multilanguage site in PHP. You may see [here](http://www.apphp.com/tutorials/index.php?page=multilanguage-database-design-in-mysql#single_translation_table_approach) The current index page is not working. My objective is to have one example to use these tables and display one working page. For example: It should work like [this](http://demo.codeursolitaire.com/multilanguage/index.php) **by using …

Member Avatar for PriteshP23
0
324
Member Avatar for Dinesh_9

Hi everone, Currently i am working on an Pharmacy management project in MVC2 model i have written an servlet code to fetch,insert,update,delete MySQL table contents from the JSP page but my problem is i could insert the data successfully but i am failing at Update and delete here is my …

Member Avatar for Dinesh_9
0
1K
Member Avatar for pritaeas

A while ago I explained how you could tag articles (see [this thread](http://www.daniweb.com/web-development/php/threads/387961/php-code-to-show-related-posts-on-a-blog)). Now you get a full working example. This code and the SQL script is also available on GitHub. The attached MySQL dump needs to be imported into your database, and you must update the credentials in the …

Member Avatar for aufche
2
907
Member Avatar for vexer007

Hi, I've run into absolute brickwall and am really desprate for your help please. I have a MYSQL Database with two Tables called user_comment and the second user_table. When a user register with the site, their details are kept in the user_table. the second table user_comment is so that users …

Member Avatar for chocolatte.lavista_1
0
406
Member Avatar for Mohamed_26

Hello I am trying to update the quantity value but I am not able to do it. As soon as the user clicks on Add To Basket, if the items exists I want it to update the value. At the moment, the quantity is one. //so this bit checks if …

Member Avatar for Mohamed_26
0
2K
Member Avatar for davy_yg

Hallo, This is funny. I export mysql codes to the webserver. Yet, I cannot run the codes correctly, there are some errors when I run the codes: Error SQL query: -- -- Database: `project_infracom` -- -- -------------------------------------------------------- -- -- Table structure for table `infracom_admin` -- CREATE TABLE IF NOT EXISTS …

Member Avatar for davy_yg
0
308
Member Avatar for Benjamin_4

Hello guys i want create a table which willl consist of Regions and Location therefore when i take a region it should give me a list of locations under that region. i hope my question is clear enough THank you

Member Avatar for diafol
-1
166
Member Avatar for apoorvashah28

INSERT into tbl_inquiry (name,phone,email,subject,message) values ('apoorva','000012345','email@email.com','subject','hi what's up')

Member Avatar for chocolatte.lavista_1
0
170
Member Avatar for rosalyn cruz
Member Avatar for chocolatte.lavista_1
0
102
Member Avatar for rosalyn cruz

how to use sql like operator?how to use it give me example thanks!

Member Avatar for chocolatte.lavista_1
0
116
Member Avatar for showman13

I'm hoping that another set of eyes will see something that I'm not. I'm having an issue with a script that I just added a little routine to, so I know the issue is in the routine, because the sript as a whole was working before adding this... the routine …

Member Avatar for showman13
0
183
Member Avatar for nana.k.denise

<?php if (isset($_POST['Login'])){ $Username = $_POST[ 'UserName' ]; $password = $_POST[ 'Password' ]; $user = 'localhost'; $pass = ''; $db = new PDO('mysql:host=localhost;dbname=ovs', $user, $pass ); $sql = "SELECT * FROM Voters WHERE UserName=:UserName"; $query = $db->prepare( $sql ); $query->execute( array( ':Username'=>$UserName ) ); $results = $query->fetchAll( PDO::FETCH_ASSOC ); foreach( …

Member Avatar for nana.k.denise
0
184
Member Avatar for mateusz.baran1

what iam trying to do is get field parameter and run mysql query to update(decrement) value from field quantity, can any one tell me how to do that? <form method="post"> <table class="bordered"> <thead> <tr> <th>No</th> <th>Drug Name</th> <th>Strength</th> <th>Quantity</th> <th>Dis Qty</th> </tr> </thead> <% try { String query="select * from …

Member Avatar for stultuske
0
182
Member Avatar for gihan.madushanka.773

I have written a code to add users into the database and validate their credentials when a user logs in. Only the added users are allowed to login and for non valid users, simply a username/password does not match error message is echoed. Password encryption and checking codes are not …

Member Avatar for iamthwee
0
299
Member Avatar for CarterLangley

Hey guys, me again. OK, I have this form that gets and populates the select boxes with the necessary info. Now, what I would like to do is to take the id field of the select box and use that to do a select query on the relevant table. So …

Member Avatar for CarterLangley
0
225
Member Avatar for nana.k.denise

<link rel="stylesheet" type="text/css" href="admin/css/style.css" /> <?php include('dbcon.php'); include('header.php'); ?> </head> <body> <div class="navbar navbar-fixed-top"> <div class="navbar-inner"> <div class="container"> <a class="brand"> <img src="admin/images/dee.png" width="150" height="50"> </a> <a class="brand"> <h2>UNITOUCH GLOBAL ONLINE E-VOTING</h2> <div class="chmsc_nav"><font size="4" color="white">Uniquely Touching The Universe</font></div> </a> <?php include('head.php'); ?> </div> </div> </div> <div class="wrapper_admin"> </br> </br> </br> …

Member Avatar for nana.k.denise
0
370
Member Avatar for skyscraper11

im creating a voting system that add votes to the database but it seems that my update/submit button don't add numbers(INT) in my database. what could be the problem here?help my database schema: | cid | cpos | cfname | cmname | clname | cyr | cparty | votes | …

Member Avatar for cxzei
0
704
Member Avatar for kgizo

Good day What I would like to do is to alter a mysql table with data in it then add manipulated string data to that created column i.e I first add an extra column to my table then add a reverse string coded from data that had already been inserted. …

Member Avatar for kgizo
0
296
Member Avatar for Yassine_1
Member Avatar for jeffmarlon

I installed XAMPP for my PHP programming practice but when I run it then MySQL is not starting, while apache is running correctly. Can anyone please tell me the solution?

Member Avatar for Bachu
0
41
Member Avatar for nevek

Hi The code below inserts data into a mysql db, for some weird reason IE inserts it 2 times and firefox just once. It should only insert it once. $KOSoep = $_POST['KOsoep']; $KOHoofdgerecht = $_POST['KOhoofdgerecht']; $KODessert = $_POST['KOdessert']; //insert query kinderopvang $insert_kinderopvang="INSERT INTO `menukinderopvang` ( `datum` , `soep` , `hoofdgerecht`,`dessert` …

Member Avatar for diafol
0
252
Member Avatar for Yorkiebar14

Hello, I am a web developer who is having a hard time trying to get my scripts to connect to my new web host. The script works perfectly on my localhost (I'm using XAMPP) but once I try to use it on my web host, I get the following error: …

Member Avatar for kanuriyesu
0
289
Member Avatar for Udeme_1

please guys i am making an app and i want to show the number of users online on the app i have this code function whoisonline() { //what are my variables values $email=$_SESSION['jwp_email']; $sqloo="SELECT `id` FROM users WHERE email='$email'"; #mysql_query($sqloo) if ($run=mysql_query($sqloo)) { $b=mysql_fetch_assoc($run); $b['id']; $c=$b['id']; } $ip=$_SERVER['REMOTE_ADDR']; $ip_ua=$_SERVER['HTTP_USER_AGENT']; $time=time(); …

Member Avatar for samfoster017
0
167

The End.