39,402 Topics
![]() | |
i wanna get two inputs and calculate them. how can i do? my code is [CODE] <input type="text" name="a" /> <input type="text" name="b" /> <input type="submit" name="Submit" value="calculate" /> <?php if ($a > $b) echo "a is greater than b"; else echo "a is greater than b" ?>[/CODE] please help … | |
Hello guys, i got a problem here.. I would like to change the url: [url]http://mysite.com/edit_files.php?deleteid=26[/url] to something randomized so people can change the numbers in "deleteid=26" I know i need a htaccess code for this, and i've searched allot to try bring this bitch down, so asking some pro fellas … | |
[CODE] <?php class X { function X(){ if($_POST['break']=='yes'){return;} } } class Y extends X{ function Y(){ parent::__construct(); print("Y_constructor_finished"); } } $_POST['break']=='yes'; $new_Y=new Y(); // will print "Y_constructor_finished" [/CODE] i does't work with return it still print Y_constructor_finished | |
Hi guys Can I use HTML Frames with PHP? I presumed I can do this by.. <?php session_start(); require("auth.php"); require("do_html_header.php"); if($_SESSION['SESS_admin'] == 0) require("do_menu.php"); else require("do_menu3.php"); do_html_header(); print"<h1>Welcome ". $_SESSION['SESS_FIRST_NAME']."!</h1>"; do_menu(); ?> </body> <frameset rows="50%,50%"> <frame noresize="noresize" src="limits.php" /> <frame noresize="noresize" src="limits.php" /> </frameset> </html> I have put it everywhere … | |
html.html is below [CODE]<form action="734608271.php" method="POST" /> Carrier: <select> <option name="car" value="nothing">------------------------------</option> <option name="car" value="Alltel">Alltel</option> <option name="car" value="AT&T">AT&T</option> <option name="car" value="BoostMobile">Boost Mobile</option> <option name="car" value="CentennialWireless">Centennial Wireless</option> <option name="car" value="EinsteinPCS">Einstein PCS</option> <option name="car" value="Nextel">Nextel</option> <option name="car" value="Sprint">Sprint</option> <option name="car" value="T-Mobile">T-Mobile</option> <option name="car" value="US Cellular">US Cellular</option> <option name="car" value="VerizonWireless">Verizon Wireless</option> <option name="car" … ![]() | |
Currently I am trying to get a php script I wrote with the help of a programmer friend to work in a content management system page. After countless hours trying to study why the CMS is not working, I've determined that there must be something wrong with my php code. … | |
My phpthumb will not generate thumb nails on one of my sites. The other site seems to work(although sometimes only some thumbnails are generated). My first problem was, I was running my image paths like so: [CODE]<img border='0' src='http://domain.com/phpThumb.php?src=".$row['path']."&w=150&zc=1' /> //.$row['path']. = http://domain.com/path/to/image.jpg[/CODE] I was getting an error telling me … | |
Hi Guys, I really don't not know where I'm going wrong with this. I am learning PHP. I have been able to input a user birthday on registration on my website using a list menu such as is on facebook. I however just cant be able to extract the date, … | |
I have taken little CMS script. but there some lines in script it confises me. who can help me to understand this lines this is [B]index.php[/B] [CODE]<? //ə session_start(); $sid = md5('atlasmed.az'); define('_INCLUDED_', true); include_once('config.php'); include_once('class.php'); $class = new functions(); $id = $class->is_num($_GET['id']); $menu = $_GET['menu']; $menus = array ( … | |
Ok I'm having a problem with this code. The problem occures when I set the POST request and alert me with 411 error. Without this two lines [CODE]curl_setopt($session,CURLOPT_POST,true); curl_setopt($session,CURLOPT_POSTFIELDS,$xml)[/CODE]this code output nice xml which shows all the info in my spreadsheet. With this two lines we should put in the … | |
Hello I am trying to develop a group site where a user can signup and create group and other user can signup and join the groups created by other users, each user will have a wall where the posts from the groups they joined will appear, I need help in … | |
Hi everyone, I am new to PHP and need help in making my script be able upload multiple images simultaneously. I need a large image and a thumb for each. I got this script from the web and made a few changes. I would really appreciate any help. The forms … | |
Hi all, I need help in the alert function. I'm using count in php in which if the item is less than or equal to 10,the alert function would pop up. However my code does not work.Below is my code. Part of the php code: [CODE]echo "<td>".$row['COUNT(item)']."</td>";[/CODE] Javascript code: [CODE]<script … | |
I don't know if this is more efficient or if it is just as quick to just code out a new page. But what I was wondering is how you create an index page and call on a new page, but the url usually says something like: index.php?page=contact instead of … | |
Hello. I want to create this address with php! [CODE] <?php $a = new dbclass(); $a->tablename->fieldname1('fieldvalue1')->fieldname2('fieldvalue2'); $a->delete(); //<<-- example! $a->insert(); //<<-- example! $a->update(); //<<-- example! ?>[/CODE] Please help me how to create class with this feature. thanks a lot. | |
I have a drop down box like this: [code] <select name="DateDropDown"> <option value="2010 selected">2010</option> <option value="2009">2009</option> <option value="2008">2008</option> </select> [/code] I use the value that the user selects to refresh the page and perform a query on a database. Is there a better way than the following to keep the … | |
Greetings All, You helped be greatly last time I was here, hoping for a repeat. I have a page at [URL="http://www.vfw10216.com/download_file.php"]http://www.vfw10216.com/download_file.php[/URL] that displays contents of my database that stores PDF files. The contents field is type 'mediumblob' and attributes is 'binary'. The field does contain data in every record, as … | |
[I]Not sure if this is the right place to post this.[/I] I'm currently working on my personal site, and was wondering how would I connect a desktop application to my site without entering my site on a browser. I'm not here to get any codes worked by someone but I … | |
i used this code for email [CODE]$to = "somebody@example.com"; $subject = "My subject"; $txt = "Hello world!"; $headers = "From: webmaster@example.com" . "\r\n" . "CC: somebodyelse@example.com"; mail($to,$subject,$txt,$headers);[/CODE] however this error shows up Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or … | |
Hi , I am design our website , and my requirement is to upload image. I want to upload image seperate for every user... when user register in my website a dynamic folder is created through his userid ..and photo is store in his directory.it is for every user seperetally.. … | |
Hi everyone, Well I have developed a site in PHP and now I want it make live. While talking to the hosting company, they have asked about the server configuration that I want. But actually I don't have any knowledge about hosting the website. So can anyone tell me the … | |
| |
Hi Guys, I am having trouble with my links, i am currently trying to use my $_SESSION['SESS_MEMBER_ID']; to automatically link it directly to the specific user page. However I always have this error: Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in C:\xampp\htdocs\ThesisDB\DisplayThisUser.php on line 21 [CODE] … | |
Hey Guys! :) Sorry to bother you all I can't seem to get my code to work and I would be much obliged if you could help me out. So what I was trying to do was get a column from a table of my database and show only the … | |
Hi, I have dynamically created radio buttons. [CODE] $i=1; <input type="radio" name="qtn-$i" value="yes"> $i++; [/CODE] Now how to get the values of these buttons using post method? | |
Trying to use [URL="http://mythreads.sourceforge.net/demo/"]MyThreads links manager[/URL] to update links on our front page without having to directly edit the code. Here is the page we're trying to include on the home page: [URL="http://www.ealantamagazine.com/links/index.php3?category=1"]http://www.ealantamagazine.com/links/index.php3?category=1[/URL] and here is the home page: [URL="http://www.ealantamagazine.com/"]http://www.ealantamagazine.com/[/URL]. Notice that the original page shows up but the area … | |
I have one table that I need to pull data from to display. there are two fields that a user's id can be attached to. Field1 and Field2, but they are always either or. In addition, I have a couple of extra where clauses in my query. My experience in … | |
Hello, I am supposed to alphabetize an array created from an HTML entry form. The array is supposed to take the information entered and place it into individual strings which will them be placed into an array which I must then alphabetize by last names. This is the code for … | |
hiii ALL!! I have to match/compare fields of one table with the fields of another table. basically m i have to search a record from another tables using some fields of a different table. for exmple I have two tables. Table 1: newjobs table 2: employer form Table 1 newjobs … | |
hi all, have some question on displaying a countdown system i have the following code <?php date_default_timezone_set('Singapore'); // Define your target date here $targetYear = 2011; $targetMonth = 9; $targetDay = 10; $targetHour = 12; $targetMinute = 00; $targetSecond = 00; // End target date definition $targetDate = mktime($targetHour,$targetMinute,$targetSecond,$targetMonth,$targetDay,$targetYear); $actualDate … ![]() | |
[CODE]<?php ob_start("ob_gzhandler"); include("../config/dbconfig.php");//connect db $result = mysql_query('select * from salesreport'); $count = mysql_num_fields($result); for ($i = 0; $i < $count; $i++){ $header .= mysql_field_name($result, $i)."\t"; } while($row = mysql_fetch_row($result)){ $line = ''; foreach($row as $value){ if(!isset($value) || $value == ""){ $value = "\t"; }else{ $value = str_replace('', '', $value); $value … | |
I have a database, test.db, with a table called Events. I tried this: [code] <?php try { // open the database $database = new PDO('sqlite:test.db'); $result = $db->query('SELECT * FROM Events'); foreach($result as $row) { // both of these lines produce a blank page //echo $row['EventName'] . ' | ' … | |
Error: Parse error: syntax error, unexpected $end in _-----___ on line 89 [CODE]<?php $connect = mysql_connect("","",""); if (!$connect) { die("MySQL could not connect!"); } $DB = mysql_select_db(''); if(!$DB) { die("My SQL could not select Database!"); } $Car = $_POST['car']; $Num = $POST['num']; if($Car == "Alltel") { $To = "$Num" . … | |
Title:CAn anyone provide me a very simple code for shopping cart? Good day, I am newbie in PHP. I wish to learn to implement a shopping cart. Since i start doing my final year project with the title "buy and sell books". I have to learn how to code the … | |
When we test our currency converter it shows a weird number before the numbers we enter. "25 pounds to U.S. dollars" returns "$1.5406, 25 British Pound = $38.52 U.S. Dollar". (For the record, Google says "25 British pounds sterling = 38.5375 US dollars".) What's wrong? [CODE=PHP] <?php /** * Jojo … | |
Hello, Im trying to make a feed for my website, anyway, what i want it to do is everything from table messages where the userid = the friend id, but what if there is multiple friend id's. sorry if this is a really easy thing, but im a newbie to … | |
Any one know's about a code in PHP that can add/edit/delete a profile of a student. I create a xHTML FOR all i need is a PHP code please do help i really want to learn.. <div id="Eform1"> <h1>FILL UP HERE: </h1> <form action="anotherpage.php" method="POST" id="form1"> <span class="pi">Personal Information: </span> … | |
Hello, I am facing something strange. I will discuss it by very clear and simple example below. 1)I have function called Test() in [B]page1.php[/B] (gives correct output) as follows: function Test(){ $sql = "SELECT * FROM accounts WHERE account_id = 4"; $rs = mysql_query($sql); while ($row = mysql_fetch_array($rs)) $mobile_number = … | |
Hello. I would like to echo out all the images from a folder on a page with pagination. I have not found something like this on the internet and i am asking now if any of you know of this. Just a simple image page with 4 rows then a … ![]() | |
Hi all, Is there a Joomla expert who can recommend a good Buy & Sell-component system for Joomla 1.5? Visitors will be able to place ads when they buy / sell. Happy New Year! Greetings newweb | |
Dear all, Digest authentication is not working in my php. I do not how to check whether digest authentication is enabled in my php . Is any other module is required to enable the digest authentication in php. Thank you, With Regards, Prem | |
I've been stuck in a situation. I am trying to retrieve image from database using ajax. I am using php as a server side scripting language.. I need to run the js funtion on every image i fetch from the database which happens to be a while loop...But that doesnt … | |
plz find the error it give this error Warning: Cannot modify header information - headers already sent by (output started at D:\xampp\htdocs\soomrof\a_task_2_1.php:3) in D:\xampp\htdocs\soomrof\a_task_2_1.php on line 24 [CODE]<? include("connection.php"); $check=false; $sql=mysql_query("select * from doctor_schedule_information where doctor_ID='".$_POST[doctor_id]."'") or die(mysql_error()); if(mysql_num_rows($sql)==1) { $row=mysql_fetch_array($sql); $check=true; } else { $check=false; } if($check==true) { header("location:a_task_2_3.php"); … | |
plz find the error it give this error Warning: Cannot modify header information - headers already sent by (output started at D:\xampp\htdocs\soomrof\a_task_2_1.php:3) in D:\xampp\htdocs\soomrof\a_task_2_1.php on line 24 [CODE]<? include("connection.php"); $check=false; $sql=mysql_query("select * from doctor_schedule_information where doctor_ID='".$_POST[doctor_id]."'") or die(mysql_error()); if(mysql_num_rows($sql)==1) { $row=mysql_fetch_array($sql); $check=true; } else { $check=false; } if($check==true) { header("location:a_task_2_3.php"); … | |
Hello Good People I have this error message....Parse error: syntax error, unexpected T_STRING in on line 111 ($result = mysql_query(" insert into users_cv ) this is the script line wherei have it // SELECT DATABASE mysql_select_db($database_recruit) or die(mysql_error()); $result = mysql_query(" insert into users_cv SET title = '$title', firstname = … | |
Is it possible to copy a mysql database to an excel worksheet writting PHP code.. please help with code. | |
Hello All, am looking for an events script like (Upcoming.yahoo.com)... I found many but!! I want the same functions of upcoming.yahoo.com As much as possible ... Commercial or Free .... It will be used by some charity organizations. Please help | |
hi guys, just want to ask some question. i have two textboxes txt1 and txt2. these two possess jquery autocompletes within.. now, what i want to do is that this two are interconnected. Meaning, the values in autocomplete in txt2 will depend upon the values inputted in txt1. consider this … | |
Hello, I am working on a website where the user can fill out a long form. For simplicity reasons, a part asks them to list features they would like to see. For that I plugged in some javascript to make a "[more]" link to add more form fields. Each form … | |
hey, guys, why does this code keep output ArrayArrayArray instead of Dec 28 for $data[0], , Dec 27 for $data[7] and so on. i would like to output all the date get from that URL, but my code failed. [CODE] <?php $data = array(); require_once("simple_html_dom.php"); $html=file_get_html("http://finance.yahoo.com/q/hp?s=4707.KL+Historical+Prices"); foreach($html->find('td[class=yfnc_tabledata1]') as $e) { … ![]() |
The End.