39,402 Topics
![]() | |
I'm learning PHP & MySQL. While trying to folllow a tutorial I am not getting the erxpected result which is simply to retrieve a little data out of a table with a query. Here is my PHP code: [CODE=php]<?php //1. Create a database connection $connection = mysql_connect("localhost", "kingdomc_mtech", "busine$$"); if … | |
I'm not sure if this is the right forum so I apologize in advance! I created a mobile version of my website. I have a subdomain called mobile.thinkdolphin.com. I've tried doing a redirect in my .htaccess file but I get an error saying there are too many redirects: [CODE]RewriteEngine On … | |
Hi, I have the following dates, either: - 07-09-09 (which is 7th September 2009) or - 07/09/2009 (which is again 7th September 2009) I need to reformat whichever one of these formats comes up so it is correctly inserted into myql db via php. Have tried strpos to find - … | |
BELOW IS PHP CODE GETTING PARSE ERROR AT LINE #16 [CODE=PHP] <html> <head> <title>table php file</title> <?php $times=2; if(isset($_POST["submit1"])) { $start=$_POST["txtStart"]; $end=$_POST["txtEnd"]; $times=$_POST["txtTimes"]; for($start;$start<=$end;$start++) { $answer= $start * $times; print($start. "multiplied by" .$times. "=" .$answer.) ; } } ?> </head> <body> <form name="form1" method="post" action="table.php" size=15> Start-Number:<input type="text" name="txtStart" value="1" … | |
Hi frnds... I m inserting some text(link+) into db table like : [B]Our PHP forum is the place for Q&A-style discussions related to this popular development language. LAMP programmers... [url]http://www.xxxxxxxx.com/gallery/gallery.php?gid=295&gcat=Heroines&gname=Bhumika%20Chawla's%20Hot%20[/url].... Our PHP forum is the place for Q&A-style discussions related to this popular development language. LAMP programmers [/B] When i … ![]() | |
I had a rather short question, doesn't OOP Programming make you increase the amount of executed queries? [code=PHP] class Guild{ private $members[]; private $sName; private $iLevel; function __construct($guildId) { // get all information from db using the guildid // also get all memberid's from the db and pass these trough … | |
Hi, I've got the following type of date string parsed from an OFX file: 20090902000000[-5:EST] How can I get this into my mysql db via php - formatted as d-m-Y I've tried : [code]$ofxdate = strtotime("20090902000000[-5:EST]"); $stmtdate = date("d-m-Y",$ofxdate); [/code] Obviously wrong! ... Any assistance appreciated! How would I do … ![]() | |
[CODE] <?xml version="1.0"?> <staff> <user> <id>A</id> <rank>User</rank> </user> <user> <id>B</id> <rank>User</rank> </user> <user> <id>C</id> <rank>Administrator</rank> </user> </staff> [/CODE] I have to promote to "Administrator" a random user using XPath. How can I do it? | |
Hi All, I have a PHP code for Sending http post from cURL. it work fine but i have a trouble that when i am send any data from loop it display me only first string the remaining string it not print. I am Use this Code. [ICODE]<html> <head> <meta … | |
The script works just fine in IE, problems occur in FF. [code=javascript] <script language="JavaScript" type="text/javascript"> var counter = 0; window.onload = ajaxFunction; function ajaxFunction(nr){ var ajaxRequest; try{ // Opera 8.0+, Firefox, Safari ajaxRequest = new XMLHttpRequest(); } catch (e){ // Internet Explorer Browsers try{ ajaxRequest = new ActiveXObject("Msxml2.XMLHTTP"); } catch … | |
Adding The Sig [IMG]http://i179.photobucket.com/albums/w300/scalia24/sigforum1.jpg[/IMG] Always attach Sig Option [IMG]http://i179.photobucket.com/albums/w300/scalia24/forumsig2.jpg[/IMG] NO SIG!!!! [IMG]http://i179.photobucket.com/albums/w300/scalia24/nosig.jpg[/IMG] please tell me what i need to do i use [url]www.forummotion.com[/url] | |
[CODE=php]<? function outError($text){ print "<center><b><font color = red>$text</font></b><br><br></center>"; }[/CODE] [CODE=php] <option value="0" <?= ($installtype == "0") ? "selected" : ""; ?> >Install with CPanel Info (can create MySQL DB automatically)</option> [/CODE] I have a script with such unusual tags and the script won't work. I cannot replace them since they … | |
I'm a newbie in programming. I spent few hours yesterday and today working on a small AJAX page with multiple combo boxes that are populated from the database. I use IE6 99% of the time and I utilize the excellent . I almost done with the page (I’m pretty proud … | |
Hi all getting this error "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1" [code] if($_POST['paypalsubmit']) { $upsql = "UPDATE orders SET status =2, payment_type =1 WHERE id =" . … | |
Hello, I am retrieving results from a RSS feed, but not all results have a title. I would like to run something like the below code which, lets me know how many times a title is empty. If three "titles" are empty, then X code would dynamically echo "3" etc.... … | |
Hi, I am writing code to create new text filed dynamically. [COLOR="Red"]But after create 2 or 3 it stops. Not creating continuously. [/COLOR] How to solve this?? [code] <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Untitled Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <SCRIPT language="javascript"> function GenerateRow(rowid){ str = … | |
Hi I have what is probably a simple question as still fairly new to php. I have a webpage which has two drop down lists, both dynamically created from sql databases. I need the user to be able to select a client in the first drop down list and it … | |
I didn't know where to post this so please move this if it is in the wrong place. I need flash to read from my database(mysql database) and also write to it. I tried doing it through php>xml>flash but it won't work. My friend works with flash while I work … | |
Well, i found this hack for VB. And basically it displays the information of the user the same as before but in a different position. I was wondering if someone could help me out and tell me how to center the action buttons and info above and below the post. … ![]() | |
Where is the best place to save cakes.php in Apache web server? I was trying to develop a web page in Dreamweaver, and then save it so that the Apache server runs it in standard browser without fail. ![]() | |
which method work fast GET() or POST() ? | |
Here are details about my forum to make things easier. phpBB Version 3.0.1 Host Servage.net Style fisubice2 Database type/version MySQL 5.0.85 How did you install your board? Using install package from Phpbb.com Fresh install or a conversion First I installed Phpbb2. And then upgraded to version 3 MODs installed? [CODE] … | |
Hello guys I still could not solve the PDF issue :( I am using XAMP server on windows system. I think PDF comes with it by default. (not sure though). I have uncommented the required 2 lines in php config file. Yet no luck. Could somebody please help me out? … | |
How do I make the timestamp string be displayed as something that is actually readable / understandable? Yes, I have looked on google, here and a couple other places, but I am not seeing anything too specific or I am just not understand. Thank you for your understanding, helping me … ![]() | |
Heya Guys, I am currently working on a project, on which my customer wants to have a customizable object. Now, what i mean by this is that the customer wants a customizable "shoe" on their site. Whereby visitors can choose the colour of the laces, the lace holes etc etc. … | |
So here is what I would like to achieve, I currently have 2 servers one of the servers has a script installed on it that is a pretty nice script, I would like to be able to run this script on both server while it is only installed on one … | |
Hi! I have a form working and in the login section I also give the option to register in case someone hasnt done so yet. This will show another form which, on submit, will use a different .php page. Now on that page,if register is successful, I'd like it to … | |
Hi I have updated the database when browser is closed,But i have a small problem.i.e. The database is updating when the page is refreshing also. I need that the Database should be updated on when the browser is closed(Not updated when page is refreshed). | |
Hello, Anyone know how to solve this problem? I have several tables. 1. the main table namely lesson contains several fields that used for searching. 2. weight is assigned by users for each keyword for searching purpose. 3. users' keyword will be compared with the record in the database. each … | |
Hi, i am having Cakephp code like [CODE]<?php foreach ($viewfields as $r): if($r['Attribute']['type']=='radio') { ?> <script type="text/javascript"> jQuery.noConflict(); jQuery(document).ready(function($){ $("#"+<?=$r['Attribute']['id'];?>).each(function() { type= "<?=$r['Attribute']['type'];?>"; attribute_id="<?=$r['Attribute']['id'];?>"; if(type=="radio") { var ht = $.ajax({ type: "GET", url: "http://localhost/FormBuilder/index.php/forms/viewChoices/"+attribute_id, async: false }).responseText; var myObject = eval('(' + ht + ')'); var data = myObject;var j=0; … | |
Hi I'm trying to use the functions/methods of one class inside another, however I keep getting errors and I don't understand this... for example; [CODE=PHP] class DB { private $host; private $user; private $pass; private $database; public function __construct($host, $user, $pass, $database) { ... } public function query($sql) { ... … | |
Hi mate, I use regex for my validation but @ this time I get confuse, how to use white space in it. I want user to enter a city name, some city name contains white space like Los Angeles, New York, I have regex which is not allowing user to … | |
I installed a joomla template and the search seems to be the only thing that is not working ,it a;ways comes up with a 0' for results where in in the back end can i fix this issue ? thankyou | |
I am working with a php file(WAD Assignment.php) now. If a condition is satisfied, it displays a JRadiobutton option. I want the value of that JRadioButton in my php file. But the value is not coming out. How can I do it? Code is below. <code=php> if($row["membership_category"]=="Student member"){ ?> <html> … | |
hey guys,,I need some help on how to call the stored procedure using classes,, I have my weeklyevent.sql file that contains stored procedure.One of this is updating a record [QUOTE] drop procedure editweeklyevent$$ create procedure editweeklyevent ( i_ses bigint, i_weid int, i_strt date, i_end date, i_act smallint, i_min smallint, i_vis … | |
Hi all, Wondering if somebody can help me.. Bascially I have two tables bid table and proposal table. I'm trying to print to screen all the proposals made by a particular user! The problem is that only those proposals that have bids made on them are printing to screen. So … | |
hi guys,,i had this problem,,I want to make a function for the days but the days has the equivalent values..... 1-Sunday 4-Wednesday 2-Monday 5-Thursday 3-Tuesday 6-Friday and 7-Saturday and also for the visibility 1-Active 2-Inactive No database had been query on it..So its just a function but the output would … | |
Hey everyone. I just recently set up(or tried to) a userdatabase where people can log in and see a user edit page. For some reason when you try to register, instead of redirecting to the successfull register page, it just goes to a page, "process.php" which process the login when … | |
hello, i am new to php and i am problem whie installing classifieds my database is hitech_classifieds and username is hitech_admin Please tell me how should i write that info in the following code so the errror doesn;t come <?php $haserrors=FALSE; function print_sql_error(){ global $haserrors; $haserrors=TRUE; print('<font color="#FF0000">' . mysql_error() … | |
This seems like the most basic issue in PHP, but I can't figure out the best way to do this. In short, I am working on upgrading an existing site and instead of Dreamweaver's clunky template function, am switching to PHP includes for various constant parts of the site (header, … | |
Warning: mail() [function.mail]: Failed to connect to mailserver at "C:\wamp\sendmail\sendmail.exe -t" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\wamp\www\akhil\booking.php on line 559 | |
Hi frnds... I am doing poll in AJAX..this is first time i am using AJAX.. The below code is working fine in mozilla, chrome...but not working in IE....plz check the below code...and change the code as correctly..i think problem in object creation in IE.. [CODE] <script> //VOTE POLL ------------------------------------- function … ![]() | |
My code is a php search function which is supposed to search from two tables in my database and displays matching results from the two tables in a line after line format. It is supposed to match the two tables with a common key field. However, the primary table has … | |
I'm running a PTC website. I want to show the last member registered on my website. I tried the following query but nothing is shown on the page; [CODE] <? $mem = mysql_query("SELECT username FROM tb_users ORDER BY id DESC LIMIT 1"); ?> New Member: <? echo $mem; ?> [/CODE] | |
Hey. I've got this code, [CODE] // query article $query1 = "SELECT * FROM (articles LEFT JOIN authorisation ON articles.page_id = authorisation.page_id LEFT JOIN authors ON articles.author_id = authors.author_id) WHERE articles.page_id NOT IN (authorisation.page_id) ORDER BY issue ASC"; $mysql_result1 = mysql_query ($query1) or die ("Query '$query1' failed with error message: … | |
When I fill my Contact Form 1) select option TITLE (MR. MRS. MISS) 2)First Name 3)Last Name 4) E-mail I make validation to all data, The question is when I select title e.g. MR and then fill first name, last name AND e-mail IS NOT right (info2company.com) validation said *Email … | |
I'm trying to setup a simple php code that will read .txt files. I want the links to change $x to the desired .txt file, then print the results below the navigation. The code works if i predefine $x, but i want to make it where clicking the links defines … | |
hi all, i am generting a report where i need to display the monthly wise reports iam not able to display correctly [code=php] <?php ob_start(); include_once('login_check.php'); include_once('functions.php'); $mon=date("m"); $year=date("y"); $num = cal_days_in_month(CAL_GREGORIAN, $mon, $year); ?> <html> <head> <title>..</title> <META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW"> <link rel="stylesheet" type="text/css" href="../styles.css"> <style type="text/css"> <!-- body … | |
hi all i have a very urgent question i want to write a function that i can use what i want to do is something like that: [code] <?php $a=_GET["a"]; function radom() { $x=rand(0,4); echo "&b=$x"; } if($a==1) {random(); } [/code] the problem is that it doesnt work... i'm getting … | |
I am a php noob and I have tried a few things and nothing so far has worked. I need to find some php code that allows me to do an http post and return the results into an array so I can parse the results for a string. The … |
The End.