39,326 Topics

Member Avatar for
Member Avatar for joslup9

php and mysql form Hi all, how I can add values ​​in a table to a combo box in html .. eg: the user's table has the id 1,2,3,4 and that using a query, being able to move to a combo box, to make a selection of id?. Greetings and …

Member Avatar for joslup9
0
302
Member Avatar for rosstafarian

Hi guys. Im new to PHP by necessity really due to a friend of mine asking me a favour. I know vb.net so not completely new to the whole programming scene. But anyway, I have approx 5 drop down lists. Each item in each drop down has a value "option …

Member Avatar for diafol
0
141
Member Avatar for Dani

Hi, How can I use preg_replace to determine if a string contains a word beginning with a pattern, and if it does, remove it? Basically I want to capture query strings from a search, but throw away search modifiers. For example, the search query string: site:daniweb.com query would just become …

Member Avatar for diafol
0
2K
Member Avatar for Jeroen van Zijp

Hey all, To make it more user-friendly, I decided I want to add a JS form validation to my contact form. The essence of the JS should be that it calls for a check.php?input= with the entered captcha code appended. Then the PHP script would echo "valid" or "invalid". For …

0
104
Member Avatar for diyez treze

[CODE]<form action= '1stform.php' method = "POST"> <fieldset border = "5"> <table> <tr> <td>Check Availability</td> </tr> <tr><td> <p>Garden Room: </label> <select name="room_GR"> <option value="0">0</option> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> <option value="7">7</option> <option value="8">8</option> <option value="9">9</option> <option value="10">10</option> <option value="11">11</option> <option value="12">12</option> <option value="13">13</option> <option …

Member Avatar for diafol
0
138
Member Avatar for Pytho

Hi all I'm making a program (for my use only) which contains all the available information about atoms. I want to collect the information from Wikipedia, but if I copy & paste it takes my whole life! For example, heres the [URL="http://fi.wikipedia.org/wiki/Vety"]Wikipedia page[/URL] (sorry, it's in Finnish because I want …

Member Avatar for Pytho
0
180
Member Avatar for kaosjon

Hi, i have written a section of code for my website and i have been trying to get it to work but whatever i try it will not work Here is the code [CODE]$upgrade_user = mysql_query("SELECT * FROM user_info WHERE id='$id'"); while($row = mysql_fetch_array($upgrade_user)){ $real_balance = $row["$balance"]; $real_rank = $row["$rank"]; …

Member Avatar for cwarn23
0
98
Member Avatar for MichaelBerh

I am trying to make my website display a different header depending on the page. If the page is 'index.php', it should include 'index-header.php'. If it isn't 'index.php', then it should include 'page-header.php'. So far, I have the following code: [CODE] <?php if($_SERVER[SCRIPT_NAME] == '/index.php'){include (index-header.php);} else { include ('page-header.php'); …

Member Avatar for cwarn23
0
160
Member Avatar for [csharp]

Hi, I want to limit access to a specific page. Page should be loaded only if the request comes through links from some web address? Can i done this with php?

Member Avatar for chrishea
0
48
Member Avatar for tusharbhatia

Hi, I am trying to search for numbers in an array - "explodedArray" which has been "exploded from a text entry. The aim is to be able to allow the user to type something in like " 5 + 5 " or "5 plus 5" or even "5 plus 5 …

Member Avatar for tusharbhatia
0
143
Member Avatar for davy_yg

Image_gallery.php [CODE] $con = mysql_connect('localhost', 'root', ''); if (!$con) { die('Could not connect: ' . mysql_error()); } echo '<p align="left">Connected successfully'; $db_selected = mysql_select_db("template", $con); if (!$db_selected) { die ("Can't use template : " . mysql_error()); } //Save File if (isset($_REQUEST['save'])){ if (empty($_FILES['uploaded_file'])){ echo "Tidak ada file yang diupload."; }else{ …

Member Avatar for mschroeder
0
424
Member Avatar for a asif

I want to create a visual info system just like google earth. the difference being that it would help people search important educational, industrial, historical sites. what environment should i preferably go for? php or asp.net. i am new to both these env.s so kindly recommend the one that is …

Member Avatar for diafol
0
124
Member Avatar for cleggy1987

hi i am trying to call the Persons() from the user_friends() to get the data for the users it can grab 1 array but when its a multiple array i get this 1111ttTTdd1111110011ee00pp22ttUUPP1111iiSSWWRRii2211HHBB can some one help me please. [CODE]<?php class profile { // Get Person public function Persons($uid) { …

Member Avatar for cleggy1987
0
185
Member Avatar for davy_yg

[CODE] <?php // a) class LongName { var $firstname = " "; var $middlename = " "; var $lastname = " "; function firstname($string) { echo "First Name : ". $string; } function middlename() { if (middlename){ echo "Middle Name : ". $this -> middlename; } else { echo "Middle …

Member Avatar for davy_yg
0
137
Member Avatar for umeshMCA

hi i would like to know that how i can send mail using my gmail account. i am using wamp server and i would like to send mail using localhost. how i can do this using php with mysql using wamp server. i do this job with asp.net but i …

Member Avatar for nakor77
0
79
Member Avatar for David 78

Hi to you guys, I've just been trying to sort this out...I know how to prevent a page load / refresh and I know how to get PHP ID from a html href link...but I have no clue how I can get the value and prevent the page from reloading …

Member Avatar for Stefano Mtangoo
0
1K
Member Avatar for calebcook

Hi. I'm not sure if this is possible: I found out that Blogger allows you to email text, images, etc to a unique email address, and then it'll post the email as a blog post. I'm trying to create a system like that for my client. Is it possible to …

Member Avatar for mschroeder
0
182
Member Avatar for onus

Here is a small PHP code which I am not clear with. [CODE]/** * Form for configurable Drupal action to beep multiple times */ function beep_multiple_beep_action_form($context) { $form['beeps'] = array( '#type' => 'textfield', '#title' => t('Number of beeps'), '#description' => t('Enter the number of times to beep when this action …

Member Avatar for cereal
0
123
Member Avatar for weasel7711

I had followed a tutorial on installing PHP on IIS 7 for Windows Server 2008 and changed the path to reflect my location of PHP. [url]http://www.howtogeek.com/50432/how-to-install-php-on-iis-7-for-windows-server-2008/[/url] I can use the command line to execute php, and I can run php files using localhost, however I cant run the troubleshooting command …

0
82
Member Avatar for vizz

Following code shows live search box. But it does not disappear when clicked on page anywhere or pressing escape key. How to hide search result when clicked anywhere or pressed escape key? index.html [CODE]<script type="text/javascript" src="jquery.js"></script> </script> $(document).ready(function(){ $(".search").keyup(function() { var searchbox = $(this).val(); var dataString = 'searchword='+ searchbox; if(searchbox=='') …

Member Avatar for mschroeder
0
265
Member Avatar for newbie14

Dear All, I would like to generate pdf document via my php page which are based on mysql data? Any recommendation so far I have seen fpdf and tcpdf. Which one will be better or is there any better tool for it? Thank you.

Member Avatar for chrishea
0
85
Member Avatar for cdoggg94

This is what I have for a main page and form and upload code for an image. The image information is stored in a Blob field in phpMyAdmin. [CODE] <?php error_reporting(0); mysql_connect("sql5c1d.megasqlservers.com","vincastweb356440","fakepassword") or die(mysql_error()); mysql_select_db("phpmy1_vincastweb_com") or die(mysql_error()); $picture = $_FILES['image']['tmp_name']; $brand = $_POST['brand']; $year = $_POST['year']; $story = $_POST['story']; $description …

Member Avatar for cdoggg94
0
246
Member Avatar for davy_yg

event_manager.php [CODE] // define variable $id = isset($_POST['id']) ? $_POST['id'] : ''; $event = isset($_POST['event']) ? $_POST['event'] : ''; $tempat = isset($_POST['tempat']) ? $_POST['tempat'] : ''; $mulai = isset($_POST['mulai']) ? $_POST['mulai'] : ''; $selesai = isset($_POST['selesai']) ? $_POST['selesai'] : ''; $keterangan = isset($_POST['keterangan']) ? $_POST['keterangan'] : ''; session_start(); // undefined …

Member Avatar for pritaeas
0
218
Member Avatar for drelix01

Every first time I create a .txt on my server using a Form, it writes like a charm, but when I add a new line in the .txt using also the Form, and view the .txt from a simple file browser made by PHPToys the new line in the .txt …

Member Avatar for cereal
0
120
Member Avatar for edn_781

Is it possible to sending HTTP request without cookies? Or to a Browser where COOKIES allowing is blocked?

Member Avatar for gotboots
0
113
Member Avatar for davy_yg

input_berita.php [CODE] $id = isset($_POST['id']) ? $_POST['id'] : ''; $confirmation = isset($_POST['confirmation']) ? $_POST['confirmation'] : ''; $kategori = isset($_POST['kategori']) ? $_POST['kategori'] : ''; $isiBerita = isset($_POST['isiBerita']) ? $_POST['isiBerita'] : ''; $judul = isset($_POST['judul']) ? $_POST['judul'] : ''; //Load berita if (!empty($_REQUEST['id'])){ $result = mysql_query("SELECT * FROM berita WHERE id =".$_REQUEST['id']) …

Member Avatar for pritaeas
0
260
Member Avatar for draven07

...hello there....i really need help.. ..i'am now working on a web-based student information system through the use of PHP and MySQL... ...but i know that before i can go through the coding part...i have to study first about its business process...... ...the SIS that i've been working was divided into …

Member Avatar for draven07
-1
431
Member Avatar for davy_yg

[CODE] $kategori = isset($_POST['kategori']) ? $_POST['kategori'] : ''; //Hapus berita // undefined index: mode if (!empty($_REQUEST['id']) && !empty($_REQUEST['mode'])){ if ($_REQUEST['mode'] == "delete"){ $id = $_REQUEST['id']; $result = mysql_query("DELETE FROM berita WHERE id =".$id) or die(mysql_error()); $confirmation = ($result) ? "Data Telah terhapus." : "Gagal menghapus data."; } } ?> <div …

Member Avatar for pritaeas
0
297
Member Avatar for Matthew N.

Hello. I'm going to show you how to make a basic php image gallery. Firstly, create the following files [LIST] [*]index.php [*]view.php [*]/images (dir) [/LIST] Now, for the code. index.php [CODE] <?php $img = array(); $img[] = array('title'=>'img1', 'src' = 'img1.jpg'); ?> <html> <head> <title>mygallery | homepage</title> </head> <body> <h2>mygallery</h2> …

Member Avatar for Matthew N.
0
417
Member Avatar for DaSpirit

I need to update the SQL table every minute, as if typing on an online notepad, that save frequently. So of course, I have: [CODE]<textarea rows="20" cols="80" id="notepad"> <?php $con=mysql_connect("localhost","username","password"); if(!$con) { die('Could not connect: '.mysql_error()); } mysql_select_db("database", $con); $result = mysql_query("SELECT * FROM Notepad"); while($row = mysql_fetch_array($result)) { echo …

Member Avatar for pritaeas
0
120

The End.