450 Posted Topics

Member Avatar for Ancient Dragon
Member Avatar for shilpamg

__sleep() and __wakeup() run prior to serialize() and unserialize() respectively. [URL="http://us.php.net/oop5.magic"]http://us.php.net/oop5.magic[/URL] __sleep() returns an array of all variables prior to serializing an object __wakeup() also runs prior to unserializing an object to reestablish any database connections etc... for that object prior to unserialization

Member Avatar for R0bb0b
0
89
Member Avatar for udaydesai

Not wanting to duplicate threads: [URL="http://www.daniweb.com/forums/thread133738.html"]http://www.daniweb.com/forums/thread133738.html[/URL]

Member Avatar for R0bb0b
0
51
Member Avatar for danno74

add a semicolon after this line [CODE=php] $message = '<html><head></head><body>$formresults</body></html>' [/CODE]

Member Avatar for R0bb0b
0
226
Member Avatar for Mylena
Member Avatar for R0bb0b
0
194
Member Avatar for jmasta

Usually when you see something like this: arrayName.item(0) it is referring to something in the DOM, for example: [URL="http://jacksleight.com/blog/2008/01/14/getelementsby/"]http://jacksleight.com/blog/2008/01/14/getelementsby/[/URL]

Member Avatar for jmasta
0
164
Member Avatar for veledrom

very basic version but it should get you started: [CODE=javascript] <!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"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> <script language="javascript" type="text/javascript"> function validateForm(inputID) { if(document.getElementById(inputID).value == "") { document.getElementById(inputID + "_error").style.display = "block"; } else { document.getElementById(inputID + "_error").style.display = …

Member Avatar for veledrom
0
103
Member Avatar for derekcpt

Total: [CODE=sql] select sum(`Amount`) as total from `sample`; [/CODE] Total Records: [CODE=sql] select count(`pmtID`) as total from `sample`; [/CODE]

Member Avatar for derekcpt
0
239
Member Avatar for derekcpt

[QUOTE=derekcpt;672572]I'm having a for where I can create invoices. Now I'm having the form fields where I have to fill it out with the customer's data. Well I don't want to fill out existing customer's data everytime. So I am having a link which opens up a page with a …

Member Avatar for derekcpt
0
101
Member Avatar for jynx_o7
Member Avatar for ZZucker

[QUOTE=jasimp;665306]Generation Y will be the downfall of America.[/QUOTE] They certainly are good at ruining music. [B]Gen X all the way baby.[/B] I feel sorry for Gen Z.

Member Avatar for R0bb0b
0
305
Member Avatar for tru's

There are several ways, here are just a few: mysql_fetch_assoc: [URL="http://us.php.net/manual/en/function.mysql-fetch-assoc.php"]http://us.php.net/manual/en/function.mysql-fetch-assoc.php[/URL] mysql_result: [URL="http://us.php.net/manual/en/function.mysql-result.php"]http://us.php.net/manual/en/function.mysql-result.php[/URL] mysql_fetch_array: [URL="http://us.php.net/manual/en/function.mysql-fetch-array.php"]http://us.php.net/manual/en/function.mysql-fetch-array.php[/URL]

Member Avatar for Shanti C
0
122
Member Avatar for AON07

try this [CODE=php] <?php $host=""; // Host name $username=""; // Mysql username $password=""; // Mysql password $db_name="images"; // Database name $tbl_name="categories"; // Table name // Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect"); mysql_select_db("$db_name")or die("cannot select DB"); $sql = "SELECT id,category_name FROM categories ORDER BY category_name"; echo …

Member Avatar for AON07
0
133
Member Avatar for Tootlol

do a find and replace in your script for the following: replace ‘ with ' replace ’ with '

Member Avatar for MVied
0
154
Member Avatar for derekcpt

[CODE=php] <? $mysql_date = "2008-08-17"; list($y, $m, $d) = explode("-", $mysql_date); echo date("m/d", mktime(0, 0, 0, $m, $d, $y)); ?> [/CODE]

Member Avatar for R0bb0b
0
207
Member Avatar for skinbug
Member Avatar for R0bb0b
0
131
Member Avatar for architact

One of the things that I have done in the past(some would prefer not to because it will change the primary keys) is to delete the values in the table pertaining to that user and then add the values as if it was the first time. This will readjust the …

Member Avatar for R0bb0b
0
218
Member Avatar for gpdrums

Also, you shouldn't be using session_register() as this is registering a global variable. You will find that in most hosts, register globals is turned off and in php 6.0 it is completely removed. You shouldn't be using register globals anyway. You only need to use $_SESSION[]. So, unless you really …

Member Avatar for MVied
0
201
Member Avatar for rko395

BRONCOS all the way man! You see what Favre is doing? What a baby.

Member Avatar for sittas87
0
91
Member Avatar for R0bb0b

I wonder if I'm going to be hearing that from my kids within the next 10 years? [url]http://www.newscientist.com/article/dn8826.html[/url] "But the neighbor kid has them!"

Member Avatar for sittas87
0
261
Member Avatar for Alex Edwards
Member Avatar for Salem

[QUOTE=Aia;659101]In Spain the working people are obligated by the state to contributed to the Roman Catholic Church whether they want or not. This is accomplished via income tax, but is not deductible. In fact, many even don't know that some of their money goes to the archives of the Catholic …

Member Avatar for sneekula
0
155
Member Avatar for Ancient Dragon

Some funny budweiser commercials [URL="http://www.youtube.com/watch?v=ywVnmQiCbPU"]http://www.youtube.com/watch?v=ywVnmQiCbPU[/URL] [URL="http://www.youtube.com/watch?v=z4m9k0c_lgU"]http://www.youtube.com/watch?v=z4m9k0c_lgU[/URL] [URL="http://www.youtube.com/watch?v=vQdgu-FvTog"]http://www.youtube.com/watch?v=vQdgu-FvTog[/URL]

Member Avatar for R0bb0b
0
145
Member Avatar for yasmena

[QUOTE=yasmena;671086]i need to know how to get the selected value from a drop down box in php for example : while($row=mysql_fetch_array($query)) { echo"<option value='category'>".$row["cat_name"]."</option>"; } i want in another page to get the selected value and perform some operation on it[/QUOTE] you just call it by the name of the …

Member Avatar for ramseswar
0
86
Member Avatar for derekcpt

This would be a javascript version [CODE=javascript] <!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"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> <script language="javascript" type="text/javascript"> function calcFields() { if(!IsNumeric(document.getElementById("txtVal1").value) || document.getElementById("txtVal1").value == "") { var val1 = 0; } else { var val1 = document.getElementById("txtVal1").value; } document.getElementById("txtVal1").value …

Member Avatar for R0bb0b
0
82
Member Avatar for blood08

What you are looking for is Curl [URL="http://us.php.net/manual/en/curl.examples.php"]http://us.php.net/manual/en/curl.examples.php[/URL] [URL="http://us.php.net/manual/en/ref.curl.php"]http://us.php.net/manual/en/ref.curl.php[/URL]

Member Avatar for langsor
0
157
Member Avatar for architact

What you are probably doing is setting the default action to shown when the default action should be hidden. Then if a user is logged in the hidden items are then shown rather than the other way around.

Member Avatar for R0bb0b
0
150
Member Avatar for bimaljr

if the user is viewing your form via https and you post relatively, the form will post https. You can test to see if the user is viewing your form via https by testing with: [CODE=php] if(!isset($_SERVER['HTTPS'])) { header("location: https://" . $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI']); } [/CODE]

Member Avatar for bimaljr
0
110
Member Avatar for Dani

Posters that whine for help, "Pleeeeeze oh Pleeeeze". If it's so urgent, why didn't they go to google first? People that say: "Can you help me, this doesn't work" [iCODE]Code Up The %^$@#[/iCODE] "thanks." oh and [iCODE]Code Up The %^$@#[/iCODE]

Member Avatar for William Hemsworth
0
997
Member Avatar for The Dude

If I could get over the temptation to chase animals with it then it would be great. Imagine the upgrades you could make to it, could probably even program it.

Member Avatar for maydhyam
0
127
Member Avatar for god_1896

I don't see an instantiation of any object into $input. Even if that is the reference you are sending into send_email(), you aren't going to be able to use that in createHeader() because it is out of scope.

Member Avatar for langsor
0
116
Member Avatar for justted

I'm sorry but I don't see where you are setting $hour. If $hour is not set then this will never fire. maybe you should include this somewhere: [CODE=php] $hour = date("G"); [/CODE]

Member Avatar for R0bb0b
0
118
Member Avatar for ficus

adjusted the onmouseout function [CODE=javascript] <td background="images/button_main.gif" class="hand" onMouseOver="getCity('getButtons.php?city=<?php echo $city;?>');" onMouseOut="setTimeout('getCity('getButtons.php?city=<?php echo $original_city;?>')', 3000);" onClick="">BUTTON</span></td> [/CODE]

Member Avatar for upside_down2000
0
347
Member Avatar for Scuppery

[QUOTE=ZZucker;665006]Let's put some bigotry on the other shoe: What is the difference between a man and a government bond? Bonds mature What did God say after creating man? I can do better What do you call a man with half a brain? Gifted What does a man consider as a …

Member Avatar for abetageek
-2
275
Member Avatar for predster

another option would be to escape any double quotes in the string, for example [CODE=php] "<script language = \"javascript\">" [/CODE] or [CODE=php] "<script language = 'javascript'>" [/CODE]

Member Avatar for Demiloy
0
139
Member Avatar for ryaninCO
Member Avatar for flaco

Personally, I think relationships and personalities can be represented by throwing 5 billion 300 sided dice on the ground. If one die tries to match itself to every die that it finds it will find the wrong combination 299 times before it finds the right one. You have to understand …

Member Avatar for steven woodman
0
674
Member Avatar for ramya_bugbuster

Step 1. Place both thumbs at center of cd while positioning index and middle fingers from both hands firmly around the cd on each side. Step 2. Now slowly apply pressure to both thumbs. It is normal to hear crackling noises so don't be alarmed. repeat step 2 until desired …

Member Avatar for ramya_bugbuster
0
146
Member Avatar for jasimp
Member Avatar for heni_pro

[CODE=sql] mysql> select count(vote) as total, vote from votes group by vote; [/CODE] will show you the total of votes per distinct vote entry.

Member Avatar for R0bb0b
0
106
Member Avatar for justted

Also what I will do many times is create a file to include which would be the top of my template and then a file that would be the bottom of my template and use a function called register_shutdown_function, you can find documentation at php.net, to include my bottom half. …

Member Avatar for R0bb0b
0
179
Member Avatar for andrew13d

[QUOTE=langsor;664304]If you are going to use a database you probably do want to use MySql or PostrgeSql since they are the most commonly supported on web servers.[/QUOTE] It is true that PostgreSql and MySql are both open source, but as much as I prefer Postgres over Mysql, for some reason …

Member Avatar for langsor
0
136
Member Avatar for loken

[QUOTE=GrimJack;649379]The problem lies between keyboard and chair[/QUOTE] meatware

Member Avatar for techbound
0
177
Member Avatar for dragonflyuk

I'm pretty sure that ‘ ’ are not valid quote characters in php so changed ‘HTTP_USER_AGENT’ to 'HTTP_USER_AGENT' [code=php] if (strpos(strtolower($_SERVER['HTTP_USER_AGENT']), "google") === FALSE) [/code]

Member Avatar for dragonflyuk
0
125
Member Avatar for fieldmedics

That's exactly how I learned php. I went line by line of applications that other people wrote, referring to php.net everytime I came across a function that I didn't know. At the time I also was aware of the basic concepts of programming. If you know those, then that's what …

Member Avatar for R0bb0b
0
78
Member Avatar for adelsin

we use eGroupWare at work and it seems to work well. I have written my own reports from it because the reporting isn't the best, also written an external form to submit tasks into it, the database is straight forward. I don't know if that is the type of application …

Member Avatar for R0bb0b
0
77
Member Avatar for veledrom

What this means is that something is wrong with the query. To find out what, you should connect a die statement to your mysql query function. [CODE=php] $run = mysql_query($sql) or die(mysql_error()); [/CODE] Keep in mind that an empty result set is still a result set so if mysql_num_rows($run) == …

Member Avatar for lordspace
0
165
Member Avatar for missaaliyah

You could do it on any file since you are accessing the same database either way. However, you need to know what columns and data types to assign to the table. Did you get a .sql file or a readme.txt file with the package that might give you this info?

Member Avatar for missaaliyah
0
113
Member Avatar for lydia21

this will give you everything you need to know [URL="http://www.w3schools.com/Ajax/Default.Asp"]http://www.w3schools.com/Ajax/Default.Asp[/URL]

Member Avatar for adnanahsan
0
119
Member Avatar for R0bb0b
Member Avatar for R0bb0b
0
532

The End.