MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
May 31, 2013, 06:49:26 PM Last edit: June 01, 2013, 09:08:46 PM by MoneypakTrader.com |
|
UPDATE: THIS WAS A VERY DIFFICULT TASK AND NONE OF THE SUBMISSIONS WORKED, but they gave me some ideas on how to do it and I eventually got the code written myself. (5/31/13) THE CONTEST IS OVER I need php code to allow selective display through a drop-down box with the contents of several mysql entries when the box is clicked. Specifically, The code: echo '<tr><td><div class="btn-group"> <button class="btn dropdown-toggle" data-toggle="dropdown"> '.$r['id'].' <span class="caret"></span></button> <ul class="dropdown-menu">'; echo '<li> '.$r['id'].' </li>'; echo '</ul> </div></td></tr>'; This code prints the correct 'id' variable from table 'a'. I need to change the code to instead print each and every (there are multiple) 'msg' variables from table 'b' if the table 'b' row has 'ID' matching the variable 'id' as printed above (remember that 'id' is from table 'a'). To rephrase, table 'b' has columns for 'ID' and 'msg', I need each 'msg' printed where that row's 'ID' = 'id' (from table 'a' as revealed with [echo '<li> '.$r['id'].' </li>';]) It should be pretty simple, but I don't know enough to do it atm. Value for partial or non-functional code: 0BTC Value for a completely working code substitution: $40 (in BTC). Just post the code here with your btc address. If it works, you get coin, if not, no coin.
|
|
|
|
|
|
|
The Bitcoin network protocol was designed to be extremely flexible. It can be used to create timed transactions, escrow transactions, multi-signature transactions, etc. The current features of the client only hint at what will be possible in the future.
|
|
|
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
|
|
|
Panchitoboy
Newbie
Offline
Activity: 41
Merit: 0
|
|
May 31, 2013, 07:03:55 PM |
|
pm sended
|
|
|
|
nzbmaster
Newbie
Offline
Activity: 19
Merit: 0
|
|
May 31, 2013, 09:38:46 PM |
|
You don't really provide enough code to do this (ie what variable is table b's data stored in, assuming its already been queried). However I would hazard it would be something like the following (assuming table b's data is already queried and stored in $tableB as an array): <?php
echo '<tr><td><div class="btn-group"> <button class="btn dropdown-toggle" data-toggle="dropdown"> '.$r['id'].' <span class="caret"></span></button> <ul class="dropdown-menu">';
foreach($tableB as $b) { if ($b['ID'] == $r['id']) { echo '<li> '.$b['msg'].' </li>'; } }
echo '</ul> </div></td></tr>';
?>
|
|
|
|
vit1988
|
|
May 31, 2013, 10:32:37 PM |
|
echo '<tr><td><div class="btn-group"> <button class="btn dropdown-toggle" data-toggle="dropdown"> '.$r['id'].' <span class="caret"></span></button> <ul class="dropdown-menu">'; $r = mysql_query('SELECT msg FROM b WHERE ID="' . mysql_real_escape_string($r['id']) . '"' ); while ($d = mysql_fetch_assoc($r)) { echo '<li> '. htmlspecialchars($d['msg']) .' </li>'; } echo '</ul> </div></td></tr>';
? 1PcvEYS54SggtN49n57T2K3cpss3D7xpWp
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 01, 2013, 04:55:01 AM |
|
echo '<tr><td><div class="btn-group"> <button class="btn dropdown-toggle" data-toggle="dropdown"> '.$r['id'].' <span class="caret"></span></button> <ul class="dropdown-menu">'; $r = mysql_query('SELECT msg FROM b WHERE ID="' . mysql_real_escape_string($r['id']) . '"' ); while ($d = mysql_fetch_assoc($r)) { echo '<li> '. htmlspecialchars($d['msg']) .' </li>'; } echo '</ul> </div></td></tr>';
? 1PcvEYS54SggtN49n57T2K3cpss3D7xpWp This yields a dash-like block with no text (dash block is too narrow vertically to display text). Also, I had to correct for r which was already used as a variable.
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 01, 2013, 05:59:35 AM |
|
You don't really provide enough code to do this (ie what variable is table b's data stored in, assuming its already been queried). However I would hazard it would be something like the following (assuming table b's data is already queried and stored in $tableB as an array): <?php
echo '<tr><td><div class="btn-group"> <button class="btn dropdown-toggle" data-toggle="dropdown"> '.$r['id'].' <span class="caret"></span></button> <ul class="dropdown-menu">';
foreach($tableB as $b) { if ($b['ID'] == $r['id']) { echo '<li> '.$b['msg'].' </li>'; } }
echo '</ul> </div></td></tr>';
?>
This did not work either. Contest is over. I have created a solution. I might send you 2 a little something for the effort to encourage people helping with my next task.
|
|
|
|
MPOE-PR
|
|
June 01, 2013, 10:16:09 AM |
|
This is probably the best thread of the day.
For my own curiosity, will this be a new Bitcoin/fiat exchange, a Bitcoin forex or a new ASIC miner?
|
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 01, 2013, 03:41:32 PM |
|
Post *YOUR* code if I'm really using it dumass, you gave me shit, I paid another programmer to actually code the site since your code was non-functional. Your ARE a scammer unless you can post your functional code, which you obviously can't b/c it doesn't exist.
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 01, 2013, 03:42:39 PM |
|
This is probably the best thread of the day.
For my own curiosity, will this be a new Bitcoin/fiat exchange, a Bitcoin forex or a new ASIC miner?
work is related to upgrading my site (link is below and also to left of this message)
|
|
|
|
Panchitoboy
Newbie
Offline
Activity: 41
Merit: 0
|
|
June 01, 2013, 06:20:03 PM |
|
anyone win the bitcoin?
|
|
|
|
MPOE-PR
|
|
June 01, 2013, 08:49:38 PM |
|
work is related to upgrading my site (link is below and also to left of this message)
I see.
|
|
|
|
🏰 TradeFortress 🏰
Bitcoin Veteran
VIP
Legendary
Offline
Activity: 1316
Merit: 1043
👻
|
|
June 02, 2013, 02:54:05 AM |
|
Post *YOUR* code if I'm really using it dumass, you gave me shit, I paid another programmer to actually code the site since your code was non-functional. Your ARE a scammer unless you can post your functional code, which you obviously can't b/c it doesn't exist. Which programmer did you pay? His changes introduced a new security vulnerability: 70% or so of the code is mine from what I see. I thought you said that the coder was going to redo it in scratch?
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 02, 2013, 07:09:55 AM |
|
Post *YOUR* code if I'm really using it dumass, you gave me shit, I paid another programmer to actually code the site since your code was non-functional. Your ARE a scammer unless you can post your functional code, which you obviously can't b/c it doesn't exist. Which programmer did you pay? His changes introduced a new security vulnerability: 70% or so of the code is mine from what I see. I thought you said that the coder was going to redo it in scratch? What's the extent of the vulnerability? I'll credit the discoveries against what you owe me. You're a lying piece of shit, your code doesn't exist or you would have revealed it by now. You could easily host it somewhere using all those scammed coins, but then people would see and compare for themselves to figure out you're a scamming scumbag.
|
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 02, 2013, 06:04:14 PM |
|
|
|
|
|
RavinTavin
Full Member
Offline
Activity: 126
Merit: 100
RavinTavin from MyFreeCams
|
|
June 02, 2013, 08:40:07 PM |
|
Post *YOUR* code if I'm really using it dumass, you gave me shit, I paid another programmer to actually code the site since your code was non-functional. Your ARE a scammer unless you can post your functional code, which you obviously can't b/c it doesn't exist. Which programmer did you pay? His changes introduced a new security vulnerability: 70% or so of the code is mine from what I see. I thought you said that the coder was going to redo it in scratch? "Boom Baby!" lol
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 02, 2013, 09:25:57 PM |
|
He didn't get anything except data (potentially). But he's such a shitty programmer, even that is doubtful how much he got.
|
|
|
|
RavinTavin
Full Member
Offline
Activity: 126
Merit: 100
RavinTavin from MyFreeCams
|
|
June 02, 2013, 09:30:24 PM |
|
He didn't get anything except data (potentially). But he's such a shitty programmer, even that is doubtful how much he got.
I mean this in the best way possible, but you're kinda being the drunk guy who just got beat up and won't shut up. Resulting in getting beat up further! Just leave it alone and walk away!
|
|
|
|
MoneypakTrader.com (OP)
Sr. Member
Offline
Activity: 472
Merit: 250
Never spend your money before you have it.
|
|
June 02, 2013, 09:42:46 PM |
|
He didn't get anything except data (potentially). But he's such a shitty programmer, even that is doubtful how much he got.
I mean this in the best way possible, but you're kinda being the drunk guy who just got beat up and won't shut up. Resulting in getting beat up further! Just leave it alone and walk away! Huh? It's my fault trolls are beating me up and publicizing the scammer's action is bad? Really, this is a good thing I found the fault in the programmers code and now they are still claiming credit for coding my site, so it really shows how scammy some of the make-pretend programmers on this forum are. Just to clarify: Site got hacked once. I'm taking steps to fix it with the $100 bounty. I appreciate other people penetration testing *IF* they check with me first and explain the methods used.
|
|
|
|
|