Skip to content
MPGHThe Dark Arts
/
RegisterLog in
Forum
Community
What's NewLatest posts across the boardTrendingHottest threads right nowSubscribedThreads you follow
Discussion
GeneralIntroductionsEntertainmentDebate FortFlaming & Rage
Board
News & AnnouncementsMPGH TimesSuggestions & HelpGiveaways
More Sections
Art & Graphic DesignProgrammingHackingCryptocurrency
Hacks & Cheats
Games
ValorantCS2 / CS:GOCall of Duty / WarzoneFortniteApex LegendsEscape From Tarkov
+14 moreLeague of LegendsGTA VMinecraftRustROTMGBattlefieldTroveBattleOnCombat ArmsCrossFireBlackshotRuneScapeDayZDead by Daylight
Resources
Game Hacking TutorialsReverse EngineeringGeneral Game HackingAnti-CheatConsole Game Hacking
Tools
Game Hacking ToolsTrainers & CheatsHack/Release NewsNew
Submit a release →Share your cheat, tool, or config with the community.
AINEW
AI Tools
General & DiscussionPrompt EngineeringLLM JailbreaksHotAI Agents & AutomationLocal / Open Models
AI × Gaming
AI Aimbots & VisionML Anti-CheatGame Bots & Automation
Create
AI Coding / Vibe CodingAI Art & MediaAI Voice & TTS
The AI frontier →Where game hacking meets modern machine learning. Jump in.
Marketplace
Buy & Sell
SellingBuyingTradingUser Services
Trust & Safety
Middleman LoungeMarketplace TalkVouch Copy Profiles
Money
Cryptocurrency TalkCurrency ExchangeWork & Job Offers
Start selling →List accounts, services, and goods. Use the middleman to trade safe.
MPGH The Dark Arts

A community for offensive security research, reverse engineering, and AI.

Community

ForumMarketplaceSearch

Account

RegisterLog in

Legal

Privacy PolicyForum RulesHelp & FAQ
© 2026 MPGH · All rights reserved.Built by the community, for the community. For educational purposes onlyContent is shared for security research and education — we don't condone illegal use. You're responsible for complying with applicable laws. Use at your own risk.
Home › Forum › Programming › Other Programming › PHP Programming › Counting PHP

Counting PHP

Posts 1–8 of 8 · Page 1 of 1
BGS. flameboy
BGS. flameboy
Counting PHP
Heey guys, I just got eveloved in PHP but, something I don't understand and I googled it but could not find it.
How can I count, $toshiba["prijs"] + $acer["prijs"] + $HP["prijs"] ?

Virusscans
[1],[2]

This is my code:

Code:
<html>
	<head>
		<title>LAB 2, les 4</title>
	</head>
	<body>
		<header><b>HASH-arrays</b></header>
		<?php
			$toshiba["merk"] = " Toshiba Satellite ";
			$toshiba["model"] = " A100 ";
			$toshiba["OS"] = " Windows 8 ";	
			$toshiba["voorraad"] = 80;
			$toshiba["prijs"] = 999;
			$totaal = $toshiba["prijs"];
			$acer["merk"] = " Acer Aspire ";
			$acer["model"] = " 5732Z ";
			$acer["OS"] = " Linux ";	
			$acer["voorraad"] = 0;
			$acer["prijs"] = 888;
			$HP["merk"] = " HP ";
			$HP["model"] = " 200X ";
			$HP["OS"] = " Windows Vista ";	
			$HP["voorraad"] = 50;
			$HP["prijs"] = 777;
		echo("<table border='1'> " . "
			<caption>
			<strong>SML laptops</strong>
			</caption>
			<thead>
				<tr>
					<th>Merk</th><th>Model</th><th>Operating System</th><th>Voorraad</th><th>Prijs</th> 
				</tr>
			</thead>
			<tbody>
			<tr>
				<td>" . $toshiba["merk"] . "</td>" . "
				<td>" . $toshiba["model"]. "</td>" . "
				<td>" . $toshiba["OS"] . "</td>" . "
				<td>" . $toshiba["voorraad"] . "</td>" . "
				<td>" . $toshiba["prijs"] . "</td>" . "
			</tr>
			<tr>
				<td>" . $acer["merk"] . "</td>" . "
				<td>" . $acer["model"]. "</td>" . "
				<td>" . $acer["OS"] . "</td>" . "
				<td>" . $acer["voorraad"] . "</td>" . "
				<td>" . $acer["prijs"] . "</td>" . "
			</tr>
			<tr>
				<td>" . $HP["merk"] . "</td>" . "
				<td>" . $HP["model"]. "</td>" . "
				<td>" . $HP["OS"] . "</td>" . "
				<td>" . $HP["voorraad"] . "</td>" . "
				<td>" . $HP["prijs"] . "</td>" . "
			</tr>
				<tfoot>
					<tr> 
						<td colspan='4'>Totaal</td> <td> " . $totaal . "</td>
					</tr>
				</tfoot>
			</tbody>
		</table>");
		?>
	</body>
</html>
index_mpgh.net.rar
#1 · 12y ago
abuckau907
abuckau907
<?php
$toshiba["merk"] = " Toshiba Satellite ";
$toshiba["model"] = " A100 ";
$toshiba["OS"] = " Windows 8 ";
$toshiba["voorraad"] = 80;
$toshiba["prijs"] = 999;
$acer["merk"] = " Acer Aspire ";
$acer["model"] = " 5732Z ";
$acer["OS"] = " Linux ";
$acer["voorraad"] = 0;
$acer["prijs"] = 888;
$HP["merk"] = " HP ";
$HP["model"] = " 200X ";
$HP["OS"] = " Windows Vista ";
$HP["voorraad"] = 50;
$HP["prijs"] = 777;
$totaal = $toshiba["prijs"] + $acer["prijs"] + $HP["prijs"];

maybe?

 
or


<?php
$toshiba["merk"] = " Toshiba Satellite ";
$toshiba["model"] = " A100 ";
$toshiba["OS"] = " Windows 8 ";
$toshiba["voorraad"] = 80;
$toshiba["prijs"] = 999;
$totaal = $toshiba["prijs"];
$acer["merk"] = " Acer Aspire ";
$acer["model"] = " 5732Z ";
$acer["OS"] = " Linux ";
$acer["voorraad"] = 0;
$acer["prijs"] = 888;
$totaal += $acer["prijs"];
$HP["merk"] = " HP ";
$HP["model"] = " 200X ";
$HP["OS"] = " Windows Vista ";
$HP["voorraad"] = 50;
$HP["prijs"] = 777;
$totaal += $HP["prijs"];
#2 · edited 12y ago · 12y ago
BGS. flameboy
BGS. flameboy
Yes, Thank you. That worked
#3 · 12y ago
abuckau907
abuckau907
Np, you posted the answer in your question : )

Quote Originally Posted by BGS. flameboy View Post
...
How can I count, $toshiba["prijs"] + $acer["prijs"] + $HP["prijs"] ?
...
$totaal = $toshiba["prijs"] + $acer["prijs"] + $HP["prijs"]

: p

w3schools is good for leaning the basics.
PHP Operators
#4 · edited 12y ago · 12y ago
NeneDelFLow
NeneDelFLow
any other questions tellme (y)
#5 · 12y ago
rchayne
rchayne
I laughed hard at this xD
#6 · 12y ago
BGS. flameboy
BGS. flameboy
Quote Originally Posted by rchayne View Post
I laughed hard at this xD
wauw thanks...
#7 · 12y ago
IW
IWillNeverUnderstand
you can ask me if you need anything. :P this is toooo basic
#8 · 12y ago
Posts 1–8 of 8 · Page 1 of 1

Post a Reply

Similar Threads

  • obligitary count to a bagalion threadBy i eat trees in Spammers Corner
    166Last post 14y ago
  • COUNT DOWN :oBy i eat trees in WarRock - International Hacks
    42Last post 19y ago
  • Aid Counts JapaneseBy ariano in WarRock Korea Hacks
    0Last post 19y ago
  • Attention: New Post Count RuleBy Bull3t in Help & Requests
    0Last post 20y ago
  • User CountBy ilove2 in Visual Basic Programming
    8Last post 19y ago

Tags for this Thread

None