41,412 Topics

Member Avatar for
Member Avatar for DealthRune

Well, I'm making this script that deals with numbers that can go up to some VERY large numbers. Like 1.0E+150 I have tried [CODE] <?php echo number_format(1.0E+10); ?> [/CODE] But that returns 10,000,000,000 I want a way to show that number, but without the comas. Can anyone help?

Member Avatar for DealthRune
0
163
Member Avatar for preetg

hi evryone... i have two tables first one is takeleave and the second one is leave...and when any employee take leave by filling the leave form then according to the no. of days leave taken the value should be deducted from another table i.e leave table. but m unable to …

Member Avatar for preetg
1
147
Member Avatar for michael123

I try to use PHP GD library to resize image to thumbnail size, however I found the small converted image has bad quality(distorted color), how can I improve the image quality by using PHP GD library: [code] $first=imagecreatefromjpeg($uploadfile); define(MAX_WIDTH, 180); define(MAX_HEIGHT, 135); $width = imagesx($first); $height = imagesy($first); $scale = …

Member Avatar for fahad.mahmood
0
168
Member Avatar for Exploded Fiber

hey all. Have a list of checkboxes with SQL data in table. Currently using echo to ensure I'm using the correct data, however, echo it returning the last checkbox data only. Here is a segment of what I've got. [CODE] echo "<table border='1'>"; echo "<tr><th>Last Name</th><th>First Name</th><th>Party</th><th>Description</th><th>Cast Vote</th>"; while($row = …

Member Avatar for hashinclude
0
109
Member Avatar for MDanz

this works, it echoes "worked". [code]<?php $url = "http://www.realgm.com"; $tags = (get_meta_tags($url)) ? get_meta_tags($url) : false; if($tags){ echo "worked"; }else{ echo "failed"; } ?>[/code] i've deliberately done this so it doesn't work. It fails to open stream. How do i make the error message invisible?... it should just say "failed". …

Member Avatar for hashinclude
0
97
Member Avatar for JRM

I have a situtation where I need to use the variables created during a session on another page. currently, I am doing the queries twice, which seems like such a waste! Is is possible to retrieve them via the session store? This is my first foray into the bowels of …

Member Avatar for hashinclude
0
140
Member Avatar for zeynokiz

I am putting together a database with users, items, and tags. I have three tables to support this structure. The first is the "items" table, which contains all of the details about each individual submitted item. The second is the "tags" table, which has two columns: tag_id and tag_text. The …

Member Avatar for hashinclude
0
136
Member Avatar for Exploded Fiber

Running a SQL query from the following code: [CODE] <php if(sizeof($_POST['addcandidate'])){ foreach($_POST['addcandidate'] as $id){ $name= mysql_query("SELECT LastName FROM candidate WHERE Candidate_ID= '$id'"); while($rowz= mysql_fetch_assoc($name)){ $candidatename= $rowz['LastName']; $alter= "ALTER TABLE '$votertable' ADD '$candidatename' int"; mysql_query($alter) or die(mysql_error()); } } } ?> [/CODE] I return Im getting: [COLOR="Red"]#1064 - You have an …

Member Avatar for Exploded Fiber
0
107
Member Avatar for BlueCharge

Please could someone find out why the website i have made for a client is completely screwed up in Internet Explorer but pretty much perfect in Mozilla Firefox. Problems in IE: 1. Cells in tables are centered 2. Footer is not in line and looks bad 3. On the contact …

Member Avatar for kevinwcaulfield
-1
88
Member Avatar for scorpio222

hello guys, i have a problem with a query. I have a table actions which has no primary key. any one particular record can be identified by the combination of actionID, taskID and ProjectID which are the other fields in actions table. Here is an example of the possible situations …

Member Avatar for Member #120589
0
108
Member Avatar for MavrickIT

If you click the below link u will find a form [url]http://lowcostwebbuilder.com/pablo/Craigslist/[/url] after filling the form you will see a template , basically I post those values on the template but my issue is How can I make this template into an image?? Help me please. I need the solution …

Member Avatar for samarudge
0
77
Member Avatar for niths

--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 'Resource id #10' at line 1-- [CODE]<html> <body> <form action="login.php" method="post"> <div> <table width="100%"> <tr> <td><img src="Logofinalcopy.gif"></td> </tr> <tr> <td bgcolor="aqua"><h2>Login</h2></td> </tr></table> <table align="right" style="width:40%"> …

Member Avatar for ko ko
0
119
Member Avatar for spectacularbob

Hi Everyone, I am having trouble developing a user registration form for my site. Here are the steps that I want to implement: Page 1: form page 1. the form where the user fills out their information into a form. 2. The form then posts the data back Page1 so …

Member Avatar for ko ko
0
167
Member Avatar for emhmk1

Hi everyone, i have a very basic pagination code for my site however i would like to adapt the links as they are displayed, so far the script just outputs numbered links but there is no such styling to the link. i would like the active link to be in …

Member Avatar for ko ko
0
99
Member Avatar for billmudry

Greetings fellow coders. I have a knowledge base on woods of the world stored in MySQL. There are over 6,500 records. Out of all the fields in use, one is simply called speciesname. The database is called taxa. All of the data in this field are two part strings (genus …

Member Avatar for darkagn
0
122
Member Avatar for CapFish

Hello all! I'm trying to restart a service in my fedora installation, from a php local file. So i discovered the shell_exec command, and tried: [CODE]shell_exec('service nagios restart')[/CODE] I also tried shell_exec('sudo restart.sh') where restart.sh has the line "service nagios restart" in it. The first time i did it, i …

Member Avatar for CapFish
0
353
Member Avatar for jamey8420

Hello, First a little background on my issue. I have two multi select boxes. The first select box (box1[]) is populated from a table. The second select box (box2[]) will be populated by "clicking over" options from box1. These options are rights to be assigned to a specific person. The …

Member Avatar for jamey8420
1
189
Member Avatar for fatcat2010

hi experts, always curious . why sometimes reference book use simple quotation mark. sometime switch to double quotation mark. Does it matter in php? e.g. define ([COLOR="Red"]'[/COLOR]SQL_HOST[COLOR="Red"]'[/COLOR],'localahost'); however, in same define function i see double quotation in another source define([COLOR="Red"][COLOR="Red"]"[/COLOR][/COLOR]CONSTANT[COLOR="Red"]"[/COLOR], "Hello world."); Thanks.

Member Avatar for fatcat2010
0
138
Member Avatar for Member #726089

Hi, I am trying to upload files with an upload.php program. This works fine on my localhost but not on my godaddy server. This is the code: <?php $target = "upload/"; $target = $target . basename( $_FILES['uploaded']['name']) ; $ok=1; if(move_uploaded_file($_FILES['uploaded']['tmp_name'], $target)) { echo "The file "; echo basename( $_FILES['uploaded']['name']) ; …

Member Avatar for Member #726089
0
63
Member Avatar for iandmac

Hi one and all, Have taken a look through the mass of other threads and whilst not covering what I need, certainly given me a dozen other ideas for other things, so definately not wasted hours but learning diversion, anyway sorry. I have been trying to utilize a pre existing …

Member Avatar for iandmac
0
247
Member Avatar for Kamboodle

Hey there, I'm having problems importing my sql file via phpmyadmin. It keeps throwing up the following error: #1064 - 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 'id`) ); CREATE TABLE `sessions`( …

Member Avatar for pritaeas
0
133
Member Avatar for prem2
Member Avatar for dandixon

I will probably get my hands slapped for posting here but I didn't know where else to put it, anyway i have some search php script in an iframe within the template of my html so that it appears on all pages. i want to be able to track the …

Member Avatar for pritaeas
0
82
Member Avatar for Raf99

Hi, I have a Word doc and a front page doc. I am looking to create a script that will look through the 1st document and take any text between two tags (ex: <h1>text text</h1> and then copy it to another file between two tags (say <tr>%text will go here%</tr>. …

Member Avatar for Raf99
0
113
Member Avatar for azegurb

hi there i have table consist of 5 columns it looks like this [CODE]id title theme image category 1 PHP tutorial tutorial self 1.jpg PHP 2 Javascript tutor tutorial self js.jpg Javascript 3 PHP tutorial 2 tutorial self ad.jpg PHP[/CODE] category here is changed for ex: how i can count …

Member Avatar for xylude
0
113
Member Avatar for tryingtofindout
Member Avatar for neha.khetan09

[QUOTE=nikesh.yadav;663969]hey, i think if u r using php session then it is clear automatically when browser closed. means when it user opens the browser it goes to login page.but u can add this code to every page except login page. [code] <?php if(!isset($_SESSION['sessionvalue'])){ ?> <script> window.location('loginpage.php'); </script <?php } ?> …

Member Avatar for cwarn23
0
77
Member Avatar for Exploded Fiber

Hey all, Im a little confused about taking the values of a 2D array and placing them into a query or string to use in query. I've done some homework but unfortunatly square eyes and a caffeine comedown just isn't helping. Essentially I have an array named $myarray. It looks …

Member Avatar for Exploded Fiber
0
143
Member Avatar for atrailm

Hi. I have the next problem: 1. I'm doing a select in a DB table and I'm displaying the result on a page 2. because one of this field is a comment and is too long, I display only the beginning of this folowed by "Read all" as a link. …

0
124
Member Avatar for niths

[code] ----Query was empty--- at ---$sql="SELECT * FROM users WHERE username='$username' AND password='$password'"; $result=@mysql_query($sql) or die(mysql_error()); --- <html> <body> <form action="login.php" method="post"> <div> <table width="100%"> <tr> <td><img src="Logofinalcopy.gif"></td> </tr> <tr> <td bgcolor="aqua"><h2>Login</h2></td> </tr></table> <table align="right" style="width:40%"> <br> <tr> <td>username:</td> <td><input type="text" name="username"></td> </tr> <tr> <td>password:</td> <td><input type="password" name="password"></td> </tr> <tr> …

Member Avatar for phpuser
0
305
Member Avatar for cane23

i have an issue with the include function. i want to use the include function on a file that is in another directory. can anyone offer any assistance on how i go about doing this??

Member Avatar for as.bhanuprakash
0
103
Member Avatar for Pooja J.

Hi to all, I have two listboxes, one is state and another is city. As user changes the state, the value of city listbox w.r.t state shuld changed. I do it with using, but I want to do it when user make a selction from state listbox. //two-list.php [code] <?php …

Member Avatar for manishmannan
0
109
Member Avatar for MDanz

i have a top frame named link_frame. the bottom frame is named menu.php how would i get the url of the top frame? i need this in php not javascript. [code] $url = $_SESSION['url']= $url;[/code]

Member Avatar for manishmannan
0
75
Member Avatar for futhonguy

Hi I am trying to write/modify a script to read from a spreadsheet into mysql database using php. I did a search on google and found phpExcelReader. However i wasnt able to use that to do so. ALso managed to find an open script to read from excel spreadsheet onto …

Member Avatar for futhonguy
0
123
Member Avatar for retareed

I have text in a MYSQL database like such: "2/22/10 - Called Lisa today. She emailed the app. 2/8/10 - No response to previous email. Forwarded again today. 1/27/10 - Emailed Lisa Gregory to see how soon we can start the application process." The thing I'd like to do is …

Member Avatar for retareed
0
157
Member Avatar for mvblhp

(I want to make free subscription area where members' info is deleted from mysql when 30 days old) I already have have a members login script.... but i have to manually delete users.....what i really need is to know how to make member expire after so many days with a …

Member Avatar for almostbob
0
186
Member Avatar for visualmonk

Hello, I'm just starting to use PHP after years of working with ASP, so pardon me if this sounds like a very basic question, but how do I get PHP to acknowledge zero (0) in a form field. Whenever the user enters "zero" and hits submit on the PHP form, …

Member Avatar for visualmonk
0
302
Member Avatar for bubbafunk1

Hi, I have a form with a field for an email address to be filled in and sent using a php script. i need help with the following 1: i want the an email to be sent to the email address that the user has just typed into the form …

Member Avatar for almostbob
0
131
Member Avatar for xwishmasterx

Hello I am not really good at php or programming and I need a llittle help: I need a value to be "converted" to an image; so if the value is "eg.3" it should show eg. "img3.gif" (the images are stored in a folder) The value is displayed with this …

Member Avatar for megan ellison
0
145
Member Avatar for jino

Dear, I am doing a site for chatting application. How can i detect the other person started typing for displaying he is typing... I also want to display an (alert) , what i mean is , if we typed a text and go to an another tab and if we …

Member Avatar for Fbody
0
79
Member Avatar for JuliaNell

Hi Guys Im developing an application and im inserting users to my database but i want to make sure that a username can only be one, no usernames are the same.. How wud i do that in PHP..

Member Avatar for liamfriel
0
77
Member Avatar for ageryckeh

please help out in figuring the code that opens a session for registered users after reading the input choices provided by the user and redirecting to a mysql query page that displays a list of data in check button options....my project intents to allow a user to select from a …

Member Avatar for manishmannan
0
89
Member Avatar for sting23

hi im still a beginner in PHP and this is the code i have so far and it only calculates value of two numbers put in manually. I want to generate two numbers and add the values. [code] <form name="form1" method="post" action=""> value1: <label> <input type="text" name="value1"> </label> <p>&nbsp;</p> <p> …

Member Avatar for manishmannan
0
1K
Member Avatar for prem2

Hi, I have large number of records in the database.Each page displays 5 records.I am using a query "select * from tablename limit 0,5";When ever user clicks next button the limit starting value increased by 5.When user click previous button the limit value decreased by 5.Now,my problem is i want …

Member Avatar for hashinclude
0
57
Member Avatar for manishmannan

Hello friends this is manish once again i am not new to php but i have got some problem in my code that is working on our previous server but now it is not working what should be the reason i have the following which work fine in our previous …

Member Avatar for manishmannan
0
133
Member Avatar for muralibobby2015

hello, i am doing check all checkboxes in a single click. i have multiple groups is there in one page. but first block is working. from second block onwords it is not working. plz help me. here is my code [CODE] <script type="text/javascript"> function checkstate(chkname,k) { //alert(chkname); //var chk="chkall"+k; //alert(document.getElementById("chkall"+k+"[]").checked) …

Member Avatar for muralibobby2015
0
96
Member Avatar for whiteyoh

Hi, I have installed NUSOAP and i get error messages 100% even from examples. My PHP knowledge is fair. Here is my situation (that cant be changed). A user on a 3rd party site clicks "BUY". The response to that is a URL to me containing a GUID and the …

0
60
Member Avatar for Ir$had

can any1 help me with my final year project :( plzzzzzzzzzzzzzz HELP EMAIL ME on <snipped>

Member Avatar for hashinclude
0
147
Member Avatar for masocha

l need to make the following which is a joomla result button open in a pop up window onclick="document.location.href='[php echo JRoute::_("index.php?option=com_poll&id=$poll->slug".$itemid); ]'" />

0
71
Member Avatar for taieb

hello I'm new to this I have not knowledge and I want to install a php script for classified web site but I can't find the connection string? some body help please, thank in advance TD.

Member Avatar for OS_dev
0
67

The End.