39,395 Topics

Member Avatar for
Member Avatar for praveen_dusari

hi all, i am using json and codeigniter for a project which it has 2 language preferences..english and french...my problem is.. in json number field has to accept (,) instead of (.) in french language can any one guide me on this... thanks, Praveen

Member Avatar for twiss
0
84
Member Avatar for scoobie

Hi, i was wondering if anyone can help me. i am new to php and was wondering if it was possible to embed javascript in php. i was trying to get an alert/msg box up to explain an error to the user. i have written the following code <?php ............. …

Member Avatar for shridharshenoy
0
646
Member Avatar for umesh daiya

hi, i would like to know how to use server side validation in php i mostly use client side validation using javascript but now i want to validate my form using php. thanks

Member Avatar for vibhaJ
0
55
Member Avatar for karthik_ppts

how to add circle marker on google map by giving latitude,longitude and radius in KM?

Member Avatar for karthik_ppts
0
245
Member Avatar for minart

Hi, I've seen similar problems to this posted here but nothing exactly the same so apologies if this question is repeated elswehere... I've got PHP/HTML page which shows a table of users and their e-mail addresses, retrieved from a MySQL DB. Part of the code builds the e-mail addresses returned …

Member Avatar for minart
0
160
Member Avatar for klemme

Hi all, I have installed Tinymce on my textareas, which are working fine. I have more than one textarea, and the Tinymce attaches itself on ALL textareas, where I only need it to display on one. It starts like this, and logically it will show on textareas, anyone who knows …

Member Avatar for vibhaJ
0
220
Member Avatar for begueradj

Hello people I used TinyMCE for my "textarea" inputs. When I display that text the colors of TinyMCE don't work meanwhile my script works fine, including other features of TinyMCE who work fine also (such as Bold, Italic fonts ...etc) Only colors don't work, I just add that similar script …

Member Avatar for vibhaJ
0
119
Member Avatar for rotten69

Hey all, I'm just hoping to receive great help from you people.. I'm tryin to fix my PHP coding and it looks good,but the server says that a particular line is broken.. [CODE] <?php $hd = fopen('content.txt', 'r'); $line = fgets($hd); $content = array(); while($line) { $word = explode(',', $line); …

Member Avatar for vibhaJ
0
91
Member Avatar for ben.matthews18

Hi, I have a contact form which is laid out like the following; [CODE]<form id="form1" name="form1" method="post" action="send.php"> <table width="362" border="0" align="center" class="tbltxt"> <tr> <td height="30" colspan="2" style="color:#174AA8; text-decoration:underline;"><b>Send us a message!</b></td> </tr> <tr> <td width="95" height="30"><label for="Name">Name</label></td> <td width="257"height="30"><input name="Name" type="text" id="Name" style="width:200px;" /></td> </tr> <tr> <td height="30"><label for="Subject">Subject</label></td> …

Member Avatar for vibhaJ
0
524
Member Avatar for dyingatmidnight

Hi all. I'm working on a database for school and I'm working between two computers, my laptop at home and my desktop at work. Now my code works fine on my desktop but when I moved it over to the laptop the two drop down select boxes aren't being created. …

Member Avatar for dyingatmidnight
0
91
Member Avatar for Violet_82

HI there, I am some problems creating a redirect from a php file. Now, here's teh problem. On my site - let's take this page - [url]http://antobbo.webspace.virginmedia.com/webediting/content.htm[/url] I have a comment form that sends me an email everytime somebody submits the form. Now, the php file is configured so that …

Member Avatar for brewbuff
0
200
Member Avatar for gnomix

Hi friend! I would compile my file php under under Linux. Have you got an idea of this? (free solution...) Thanks a lot [Gnomix]

Member Avatar for jakubmisek
0
925
Member Avatar for abhi10kumar

How do I populate a combobox when checkbox is checked or not on click event. If I click checkbox then combobox fill certain values, and If I uncheck then combobox will get its original items. How this can be done using ajax (jQuery) ?

Member Avatar for diafol
0
31
Member Avatar for adamworld

I have code where I am pulling data from my database and it needs to be separated by commas except the last value (that part works) so I can take those values and input into another SQL query. Here is the working code: [CODE]$biz_id = $row_businesses['id']; $query_related = sprintf("SELECT * …

Member Avatar for adamworld
0
112
Member Avatar for dyingatmidnight

Sorry its a lame title. Not sure really if this should be hear or over in the sql section. I know what I want to do but I'm blanking on how exactly to go about it. I'm inserting book titles into a library database and what I'd like it to …

Member Avatar for diafol
0
98
Member Avatar for Hakoo

Hello Friends, I am working in JME. Now, I have situation in which, I suppose to connect with Database which has been used with PHP. So, How can I access to Mysql? As usual same as to connect mysql with JDBC? Is Mysql and Mysql in WAMP Server different? Please …

Member Avatar for diafol
0
202
Member Avatar for phpbeginners
Member Avatar for branding4you

hi i want to direct my website to different pages If there are competions that are active to show the page list of them else go to other page i tried this but no luck [CODE]<?php include_once "connect_to_mysql.php"; $extract = mysql_query("select * from tbl_competition WHERE fld_closed='N'"); while ($row = mysql_fetch_assoc($extract)) …

Member Avatar for branding4you
0
167
Member Avatar for twitah

Hello buddy, im getting some warning like this: [QUOTE]Warning: file_get_contents() [function.file-get-contents]: Filename cannot be empty in /home/a8150490/public_html/index.php on line 4 Warning: imagecreatefromstring() [function.imagecreatefromstring]: Empty string or invalid image in /home/a8150490/public_html/ocrbreaker.php on line 5 Warning: imagesx(): supplied argument is not a valid Image resource in /home/a8150490/public_html/ocrbreaker.php on line 52 Warning: imagesy(): …

Member Avatar for diafol
0
453
Member Avatar for designalex

Hi, please point me in right direction. I want to be able to post php/html/mysql code on my website and have it viewed as i would if i posted code on daniweb and used the CODE tags for e.g [CODE]<?php echo "I would like to see my code like this"; …

Member Avatar for diafol
0
103
Member Avatar for branding4you

how does one search mysql where one fields has multiple entries. example: in my db i have two fields in table, one field is the type field: id | Garment | Type 1 | Satin Shirt | "Chemical Clean" 2 | Silk Shirt | "Dry Clean", "Chemical Clean" When i …

Member Avatar for branding4you
0
101
Member Avatar for mangel.murti

hi all, i want loading image should be display first for 3-4 second on every search button click then result should be display. [CODE] $(document).ready(function () { $('#form').submit(function() { $('#dsr').addClass('loading'); $.ajax({ type: 'get', url: 'search_hotel.php', data: $('#'+this.id).serialize(), dataType: "html", async:false, success: function(result){ $('#dsr').html(result); }, complete: function() { $('#dsr').removeClass('loading'); } }); …

Member Avatar for mangel.murti
0
887
Member Avatar for TotoTitus

Hello everyone, I am using the following code to do a post to localhost: [CODE] $ch=curl_init(); curl_setopt($ch, CURLOPT_URL, 'http://localhost/response.php'); //response.php just spits out json_encode($_POST) curl_setopt($ch, CURLOPT_HTTPHEADER, Array("Content-Type: text/html")); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_POSTFIELDS, Array('data' => $xml)); $curl_result = curl_exec($ch); if(curl_errno($ch)) { echo 'Curl error: '.curl_error($ch); } curl_close($ch); …

Member Avatar for TotoTitus
0
2K
Member Avatar for abhi10kumar

Query Runs in mysql but gives an error when I run in PHP here is the query [CODE]select p.pid as pid, s.sid as sid, s.status as staus, p.name as name, p.mobile as mobile, p.email as email, c.name as course from students as s, prospects as p, courses as c, batch …

Member Avatar for karthik_ppts
0
97
Member Avatar for ben.matthews18

Here is my script [CODE]<?php $Name = $_REQUEST['Name'] ; $Subject = $_REQUEST['Subject'] ; $Email = $_REQUEST['Email'] ; $Message = $_REQUEST['Message'] ; mail( "email@email.com", "Contact form", $Message, "From: $Email" ); header( "Location: http://randomaddress.com" ); ?>[/CODE] How can i prevent mysql injection? Thanks

Member Avatar for rkskeka
0
58
Member Avatar for zakir ali

function main() { if(window.XMLHttpRequest) { ab=new XMLHttpRequest; } else { ab=new ActiveXObject("Microsft.XMLHttp"); } ab.onreadystatechange=function(){ if(ab.readyState==4 && ab.status==200) { document.getElementById("progress").innerHTML=ab.responseText; } } ab.open("GET","querygoogle.php"); ab.send(); } function test(id) { if(window.XMLHttpRequest) { xmlhttp=new XMLHttpRequest; } else { xmlhttp=new ActiveXObject("Microsft.XMLHttp"); } xmlhttp.onreadystatechange=function(){ if(xmlhttp.readyState==4 && xmlhttp.status==200) { document.getElementById("testdiv").innerHTML=xmlhttp.responseText; //alert(xmlhttp.responseText); } } xmlhttp.open("GET","test.php",0); xmlhttp.send(); } function …

0
160
Member Avatar for thedonedeal

Is there a way to write a line in .htaccess so that a rewrite rule will NOT rewrite the URL if a certain query_string is found or if a certain page is referring to the page about to be rewritten?

0
115
Member Avatar for makimbo

I have this function: [CODE] function card_draw ($numeroDeobjetos) { for ($i=0; $i<$numeroDeobjetos; $i++) { $aleatorio=rand (1,40); $usada[$aleatorio]=true; } for ($i=0; $i<=39; $i++) { if ($usada[$i]==false) { echo '<img src="card.jpg">'; } else { echo '<img src="'.$i.'.jpg">'; } } }[/CODE] How can I do to prevent repeated numbers in $aleatorio? Thank you.

Member Avatar for makimbo
0
135
Member Avatar for Tenaciousmug

It's only displaying the first result and not the others. What am I doing wrong? I'm selecting the items the user occupies. Then I'm selecting the name and image of that item from the item table. [CODE]echo "<table cellspacing=\"0\" class=\"news\" align=\"center\">"; echo "<tr>"; $sql = "SELECT * FROM useritems WHERE …

Member Avatar for C#Jaap
0
138
Member Avatar for PixelatedKarma

Hello! So this might be really weird, but I'm having one of those mornings (the type of morning that no matter how hard you think nothing quite happens haha). So anyways where you guys step in - I am working on a website for a gaming clan. I am making …

0
70
Member Avatar for klemme

Hey, I have a question on how to make an inline style to this..: [CODE] $sqlCommand = "SELECT * FROM pages WHERE subjectid='" . $subjectid . "' AND showing='1' ORDER BY pos ASC"; //*** $query = mysqli_query($myConnection, $sqlCommand) or die (mysqli_error()); $PageMenuDisplay = ''; while ($row = mysqli_fetch_array($query)) { $pid …

Member Avatar for klemme
0
158
Member Avatar for veledrom

Hi, I just started learning CodeIgniter. There is a library [ICODE]$this->load->library('form_validation');[/ICODE] for form validation with rules. Does that mean we don't have to use Javascript to validate forms anymore? Because, if we have to use those validators in CI (sake of the best practise), what is the point of using …

Member Avatar for veledrom
0
937
Member Avatar for Kieron Thomas

Hi all, I am kinda new to web design and also PHP. I am currently working on a Mobile Tyre Fitting website for my dad and need a little help on a search form. The search form has 3 dropdown menu's which are WIDTH , PROFILE and SIZE. I have …

Member Avatar for TySkby
0
148
Member Avatar for ms.rhea

hi.. I have a form that needs 10 inputs from a user.. Now my problem is, once the user have input the 10 needed information, he/she cannot input another information and there will be a message stating that he/she cannot input the information because past information have inputed. What do …

Member Avatar for ms.rhea
0
127
Member Avatar for muhito

Hello guys, I need help with this. When I run it, I get a blank page. Please Me out. [CODE] <?php //The Main Program $call_put_flag="c"; $S=50; $X=52; $T=0.5; $r=0.05; $v=0.15; BlackScholes ($call_put_flag, $S, $X, $T, $r, $v); //echo $call_put_flag, $S, $X, $T, $r, $v; //Commulative function function CND ($x) { …

Member Avatar for muhito
0
85
Member Avatar for umeshMCA

hi any body help me. i am new user in web development i would like to know how to send mail using php.(localhost) while using wamp server. thanks and regards umesh daiya

Member Avatar for mafhh14
0
283
Member Avatar for abhi10kumar

I have a checkbox, populates the combox on both checked and unchecked. I am using AJAX to populates. When checkbox is checked, It works fine, but when I unchecked It wont work, actually it wont do anything. [CODE]<input type="checkbox" name="course_inactive" id="course_inactive" onclick="courseStatus(document.getElementById('batch').value, document.getElementById('batch').value)">[/CODE] If remove courseStatus() function is removed, it …

Member Avatar for diafol
0
35
Member Avatar for Ritesh_4

Hello Am new to PHP coding, and would like to get some very good tutorials on PHP forms and processing involved, with mysql may be included as well as part of the forms data to be used, anyone can suggest some nice sites or ebooks or tutorials? Googled some, but …

Member Avatar for astra2000
0
141
Member Avatar for johng123

have problems understanding the logic of using variables inside this code. why ist it possible to use %s for different variables and how is it possible to use them as %1$s and %2$s...without even defining them somewhere...i just dont get it, the complete code can be viewed in the thread: …

Member Avatar for vibhaJ
0
189
Member Avatar for ZaphodQB

Is it possable to un-include a file to reduce the footprint of a script? That is, after it is included, can it be un-included?

Member Avatar for robbz
0
392
Member Avatar for -==Zero==-

In This Page How Can I Make The Page Title Get Its Name From (( Title )) In Database Ads [CODE]("SELECT * FROM ads where id='$id'");[/CODE] [CODE]<!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" dir="ltr" lang="en"> <head> <title>:: [COLOR="Red"]ZERO XXX[/COLOR] ::</title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link href="http://www.e-alriyadh.com/favicon.ico" …

Member Avatar for Stefano Mtangoo
0
766
Member Avatar for CobRalf

Hello everybody ;) I have written a kind of css (pre)-processor in PHP, and it uses the GET-method to acces to the file: HTML: [CODE]... <link rel="stylesheet" href="css.php?file=style.css" /> ...[/CODE] PHP: [CODE] ...$pss=file_get_contents("css/".$_GET["file"]); ...[/CODE] My problem is now, if a user types something like "css.php?file=../index.php", he gets the source codes …

Member Avatar for CobRalf
0
142
Member Avatar for rpv_sen

Hi Friend I need a alert msg display in php, without using javascript. Pls help me to solve it [CODE]$pqty = $bdatam["sum(curr_qty)"]; $pamt = $bdatam["sum(curr_amount)"]; $btotal= $bgtqty+$pqty;[/CODE] i want to display $btotal in alert msg display. Pls help me

Member Avatar for rpv_sen
0
238
Member Avatar for cliffcc

I have the php which can import the csv files into mysql. But how to avoid the wrong data replace the data database. What is the code in php for checking before insert into the database? Thanks!

Member Avatar for vibhaJ
0
129
Member Avatar for hjames

[QUOTE=~s.o.s~;610914]> how to make div id's as unique (since it need to identify a unique div for each row) One way would be to create a separate counter (e.g. i) which would be incremented for each "for each" block and create an ID dynamically by appending the common name with …

Member Avatar for rpv_sen
0
104
Member Avatar for ebanbury

Hi First I'm really sorry if this is the wrong area to post this query, but as my pages are all in php, I thought it may have something to do with it. I have just realised that the top part of my pages flicker when you move your mouse …

Member Avatar for ebanbury
0
80
Member Avatar for zulkefli82

hi, I create a form using php+html in my website. When visitor of my website press send button, the information their key-in in the form will send directly into my inbox. The problem is, my inbox always receive spam from this.. I already delete the form to solve this problem …

Member Avatar for almostbob
0
99
Member Avatar for eduardc

Why is the serial no always 0 while I put other numbers? Php file: <html> <body> <?php $con = mysql_connect("localhost","eduardli_user","-z.x,c"); if (!$con) { die('Could not connect: ' . mysql_error()); } $description = $_POST["description"]; $price = $_POST["price"]; $quantity = $_POST["quantity"]; mysql_select_db("eduardli_company", $con) or die(mysql_error()); mysql_query ("INSERT INTO Products (description, price, quantity) …

Member Avatar for almostbob
0
139
Member Avatar for Mattshu

In the top of the first page that is requested, I make a global variable and store the value of microtime() in it. The footer of the page is require()'d at the bottom, and in the separate footer page is a code that subtracts the current microtime() from said global …

Member Avatar for diafol
0
62
Member Avatar for perohijo

Hello. Although I have seen someone else having a similar problem here, I got stuck with an error. This is the code and it shows a red parenthesis. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>JumbleMaker</title> </head> <body> <?php function DisplayError($fieldName, $errorMsg) { global $errorCount; echo …

Member Avatar for perohijo
0
157

The End.