Forum: PHP 34 Days Ago |
| Replies: 4 Views: 195 Is the select box preloaded with data? If so, this thread may be of help to you: http://stackoverflow.com/questions/147839/cognos-8-javascript-to-select-values-in-a-multi-select-list-box-prompt
If... |
Forum: MySQL 34 Days Ago |
| Replies: 2 Views: 356 This was a good exercise! This code will do what you want:
select #localizacao.*, #cliente.*, #dispositivo.*
FROM #dispositivo
join #localizacao on #localizacao.local_disp_id =... |
Forum: MySQL Oct 22nd, 2009 |
| Replies: 2 Views: 388 The INNER JOIN will only display data found in both the joined tables. Perhaps your staff_declare, staff_post and staff_department are sparse? |
Forum: MySQL Oct 22nd, 2009 |
| Replies: 1 Views: 348 I'm guessing you are executing the CREATE code over again. Be sure to DROP TABLE Job_Title before creating it again. |
Forum: MySQL Jul 24th, 2009 |
| Replies: 2 Views: 402 SELECT a.departure, a.arrival, 0 AS connections, price AS cost FROM flights AS a WHERE a.departure = 'Chicago' OR a.departure = 'New York'
UNION
SELECT r.departure, b.arrival, r.connections + 1,... |
Forum: MySQL Jul 24th, 2009 |
| Replies: 3 Views: 538 No workaround is available via PHP. That wouldn't make sense; allowing PHP to somehow override firewall settings would be somewhat dangerous. :-)
If you can't access the db server, the firewall... |
Forum: PHP Jul 24th, 2009 |
| Replies: 7 Views: 421 |
Forum: PHP Jul 24th, 2009 |
| Replies: 5 Views: 1,165 Hmmm. That's some kinda odd code there. Let's do a quick rewrite:
$sql = "SELECT prodMFG FROM productDetail WHERE prodMFG != '' GROUP BY prodMFG"; // (1)
$result = mysql_query($sql);
echo "<form... |
Forum: PHP Jul 23rd, 2009 |
| Replies: 9 Views: 304 Some random thoughts...
I'd recommend just getting in there and writing code! That's the fastest way to learn. Pick a project - even something that's been done many times before - and write it.... |
Forum: PHP Jul 23rd, 2009 |
| Replies: 9 Views: 12,209 Since your bug was a syntax one, you might consider an IDE. See http://www.ibm.com/developerworks/library/os-php-ide/index.html for a list of suggestions. However, there can be a tendency to rely on... |
Forum: PHP Jul 23rd, 2009 |
| Replies: 7 Views: 381 Looks like you're not properly connecting to the database. But I can't very well test that - looks like the db connection code is in your include file. |
Forum: PHP Jul 23rd, 2009 |
| Replies: 5 Views: 688 I think your logic's just reversed. I'd do something like this:
if (mysql_numrows($exist) > 0)
echo "There are ".mysql_numrows($exist)." users with that name."; |
Forum: PHP Jul 23rd, 2009 |
| Replies: 9 Views: 12,209 The following line has parenthesis issues:
if(mysql_num_rows(($wisher)<1)){
It should be:
if(mysql_num_rows($wisher)<1){ |
Forum: PHP Jul 23rd, 2009 |
| Replies: 8 Views: 358 The host should not make any difference!
Please give us the URL (put just this code in a file, if you like).
I put your code (simplified) in here - http://www.spthorn.dev/aaa.php - does that... |
Forum: PHP Jul 23rd, 2009 |
| Replies: 7 Views: 381 That's because you added a condition that if both the First and Last name are blank, just go to the original page. This condition is always true because you didn't give the "last" field a name:
... |
Forum: PHP Jul 22nd, 2009 |
| Replies: 9 Views: 12,209 Chand, your code is obviously NOT ok. :-) Please paste your code in this or another thread for us to review. |
Forum: PHP Jul 22nd, 2009 |
| Replies: 7 Views: 381 Go back to line 11 - there's an extra double-quote in there. |
Forum: PHP Jul 22nd, 2009 |
| Replies: 5 Views: 452 There's some logic missing in all this code. I'd suggest sitting down and writing out pseudocode to cover all the options and THEN coding. Something like this:
if (studentid doesn't exist)
add... |
Forum: PHP Jul 22nd, 2009 |
| Replies: 8 Views: 358 I suspect it's not an HTML marquee. Please post the relevent code. |
Forum: PHP Jul 22nd, 2009 |
| Replies: 5 Views: 718 Karin,
I see a couple problems.
First, you're not accessing the right column name for the color. The SELECT statement says it's 'colorinfo', but when you access it, it's as 'color'. Change the... |
Forum: PHP Jul 22nd, 2009 |
| Replies: 9 Views: 493 Here's the consensus:
if(isset($_GET['id']))
{
$con = mysql_connect("localhost","r","123456");
if (!$con)
{
die('Could not connect: ' . mysql_error());
} |