Sponsored:   [Largest VC Funded] TEMCO, millions sold out in seconds. Join TEMCO's last presale at CoinBene!
Contract Overview
Balance: 0.027 Ether
Ether Value: $2.22 (@ $82.17/ETH)
Transactions: 56 txns
Misc:
Address Watch: Add To Watch List
Contract Creator: 0x7e8fc8b3145e8bf15683b1bad9ec39223826cf56at txn 0xd68384c306a16c2427d251ff7ea217e1676a7944588a3efde3d93e884ac90624
 Latest 25 transactions from a total of 56 transactions

TxHash Age From To Value [TxFee]
0x7c11152e3aa4659d55ec1a58f9683ece55016104a388565c449ac689ea383b92126 days 16 hrs ago0x84d96968235a6a60d4f7bfaa77112bcf02e739ca  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.00099546
0x6c4e835601cc074d6fd98072ce381c69333d889fcbbbeb4dfd1e8fe8b1d5183c128 days 17 hrs ago0x84d96968235a6a60d4f7bfaa77112bcf02e739ca  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.00222999
0x95727d027618804d8fcac793d3b6efb647fd612143e3c66a264ed9133ab11964148 days 10 hrs ago0x429dc9d3197ef46439510a3d23363c6f84266b7a  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000605517
0x0e598255134b77f55aa4dd566475d150aa8653dd29960b95d1fd8c14003b8908267 days 12 hrs ago0xeba8efab4ffba2becaa6027f8f5b55aa8d274bd1  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000262878
0x3a9860ce7aebdb09a3f5d23b91913991f91a4dfbf14b5059b99682ad58b6b287286 days 14 hrs ago0x2e933dd349f63fa9f71163f4a2d0a1f00abed643  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000424248
0xc76eebd770537195bc75681410ab289ad2d4f68aa00d7afa56ee2adf4265ab2a286 days 14 hrs ago0x2e933dd349f63fa9f71163f4a2d0a1f00abed643  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000684525
0xeca5100981161a654d64b5abfdd9ad031722e8bff2c503b5d845f1b935166668306 days 17 hrs ago0x2e933dd349f63fa9f71163f4a2d0a1f00abed643  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000147026
0xe024727bf0f69b6d6f5e6653891f015f01bcf0b0be6ea00ec51afdc0d66a5a91306 days 20 hrs ago0xb70db045618d3fe9b70736ce3b484bcaa897168e  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000099491
0x48cf6fc4c6ed2e070a0ae90a53a9c0d16ac1fd190f00296686276cc546fc0e09307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000861432
0x20443f5d1b24c066a21c0cc0591c468b94d990a68cc991d192493315ac468925307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000395853
0x32e72f6302523fae04c27d4770b0763203368f97a6405bd521329629a2c917cd307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000618516
0x67571ededbe1f0074e3f245ae94b4bc9901aa3e4db5fca8536e8497c6e7b2b0d307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000378146
0xd29750eb14e853175cc8dee811f3a9fee1019f492174c78331b5350285ee3740307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000480543
0x2a9ae7a342cd415abb6a1ef1af06928e954420809cbcd610c8574329dff3a1b1307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.0005393752
0xf594ab37be9740a43d226c89e7fec7755721d817298e83af2bf0f3886242b380307 days 21 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000188724
0x4e02dc7cb6a138d2fd60218dc9d333fd206cccddcc07e9129b6f353427d908c2307 days 22 hrs ago0xf373b4a25fc2ccf1a54d7ce6b8326d5d15d99080  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000116604
0xa90abdf3dae8973725410c5ad3f69c6f25204ae69080f61414e36d7d62a42088319 days 4 hrs ago0x58bdb9f6fe4c6d16bca607fa803001c1c2b96745  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.000269448
0xa2216de4dfa391f142f9410b03a515a3aa9f28534b9d9b92a73374e922826517341 days 2 hrs ago0x46d9112533ef677059c430e515775e358888e38b  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.00540981
0x1efc13c350567e202ef0a1abec6cfa22f27e9aa2a98f8aef99d9bbddfe4ffc13349 days 15 hrs ago0x03c6a60c9072f8edfffb62e1ca52062e3cd53f40  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.0000495855
0x9779a97fe8e9ba0b27cc02e324457b34d18053c119241ebc05a1ba5a13fce46e351 days 16 hrs ago0x1d43cb4771a73eb0aa83786e0cc4b4980e4172e1  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.00720898
0xa3b9872137099a53bbe8609f9cd387bb7c08eae73863e370226eece0fc0f7c59364 days 18 hrs ago0x58bdb9f6fe4c6d16bca607fa803001c1c2b96745  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.0006664174
0x81bc6095b3eae25769f4bf2e37b1a71b299d63e3a5bf90f719799b4aaf448d91393 days 9 hrs ago0x561cbb53ba4d7912dbf9969759725bd79d920e2c  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.001
0x3063aa9d02e3b5cf3563de3173841682184a8ad4cf185255e440397eee2c14b4408 days 23 hrs ago0x79dc75c2e8bd552d848cd44ac2762486538880f7  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.003394908
0x5b583b2be8782c63a0f8f91496c4fff0ec6f3433a318cd99ef741c1c93767c93412 days 2 hrs ago0x4da2e85d64bece663ccab06e89b970b6b077f22f  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.001 Ether0.0009546
0x8a25a6afadb5ad986757170ce5c65e6ffea06ccd4d4fa2a72a52c13e0ae99e7a412 days 2 hrs ago0x4da2e85d64bece663ccab06e89b970b6b077f22f  IN   0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0.0005 Ether0.000787708
[ Download CSV Export  ] 
 Internal Transactions as a result of Contract Execution
 Latest 1 Internal Transaction

ParentTxHash Block Age From To Value
0x2867454e59f84e478c13b63e980b5169b71d0db7de0581e616fa60c748da54d44440163414 days 3 mins ago0x470fb19d08c3d2eb8923a31d1408c393dab09ccf0x7e8fc8b3145e8bf15683b1bad9ec39223826cf560.009 Ether
[ Download CSV Export  ] 
Warning: The Compiled Contract might be susceptible to ExpExponentCleanup (medium/high-severity), NestedArrayFunctionCallDecoder (medium-severity), ZeroFunctionSelector (very low-severity) SolidityCompiler Bugs.

Contract Source Code Verified (Exact Match)
Contract Name: FiveMedium
Compiler Text: v0.4.16+commit.d7661dd9
Optimization Enabled: Yes
Runs (Optimiser):  200



  Contract Source Code   Find Similiar Contracts

pragma solidity 0.4.16;

contract FiveMedium {
	
	// owner
	address private owner;

	// fees
	uint256 public feeNewThread;
	uint256 public feeReplyThread;

	//
	// Database
	//

	// the threads
	struct thread {
		string text;
		string imageUrl;

		uint256 indexLastReply;
		uint256 indexFirstReply;

		uint256 timestamp;
	}
	mapping (uint256 => thread) public threads;
	uint256 public indexThreads = 1;

	// the replies
	struct reply {
		string text;
		string imageUrl;

		uint256 replyTo;
		uint256 nextReply;

		uint256 timestamp;
	}
	mapping (uint256 => reply) public replies;
	uint256 public indexReplies = 1;

	// last 20 active threads 
	uint256[20] public lastThreads;
	uint256 public indexLastThreads = 0; // the index of the thread that was added last in lastThreads

	// 
	// Events
	//

	event newThreadEvent(uint256 threadId, string text, string imageUrl, uint256 timestamp);

	event newReplyEvent(uint256 replyId, uint256 replyTo, string text, string imageUrl, uint256 timestamp);

	//
	// Meta
	//

	// constructor
	function FiveMedium(uint256 _feeNewThread, uint256 _feeReplyThread) public {
		owner = msg.sender;
		feeNewThread = _feeNewThread;
		feeReplyThread = _feeReplyThread;
	}
	
	// modifying the fees
	function SetFees(uint256 _feeNewThread, uint256 _feeReplyThread) public {
		require(owner == msg.sender);
		feeNewThread = _feeNewThread;
		feeReplyThread = _feeReplyThread;
	}

	// To get the money back
	function withdraw(uint256 amount) public {
		owner.transfer(amount);
	}

	//
	// Core
	//

	// To create a Thread
	function createThread(string _text, string _imageUrl) payable public {
		// collect the fees
		require(msg.value >= feeNewThread); 
		// calculate a new thread ID and post
		threads[indexThreads] = thread(_text, _imageUrl, 0, 0, now);
		// add it to our last active threads array
		lastThreads[indexLastThreads] = indexThreads;
		indexLastThreads = addmod(indexLastThreads, 1, 20); // increment index
		// log!
		newThreadEvent(indexThreads, _text, _imageUrl, now);
		// increment index for next thread
		indexThreads += 1;
	}

	// To reply to a thread
	function replyThread(uint256 _replyTo, string _text, string _imageUrl)  payable public {
		// collect the fees
		require(msg.value >= feeReplyThread);
		// make sure you can't reply to an inexistant thread
		require(_replyTo < indexThreads && _replyTo > 0);
		// post the reply with nextReply = 0 (this is the last message in the chain)
		replies[indexReplies] = reply(_text, _imageUrl, _replyTo, 0, now);
		// update the thread 
		if(threads[_replyTo].indexFirstReply == 0){// we're first
			threads[_replyTo].indexFirstReply = indexReplies;
			threads[_replyTo].indexLastReply = indexReplies;
		}
		else { // we're not first so we update the previous reply as well
			replies[threads[_replyTo].indexLastReply].nextReply = indexReplies;
			threads[_replyTo].indexLastReply = indexReplies;
		}
		// update the last active threads 
		for (uint8 i = 0; i < 20; i++) { 
			if(lastThreads[i] == _replyTo) {
				break; // already in the list
			}
			if(i == 19) {
				lastThreads[indexLastThreads] = _replyTo;
				indexLastThreads = addmod(indexLastThreads, 1, 20);
			}
		} 
		// log!
		newReplyEvent(indexReplies, _replyTo, _text, _imageUrl, now);
		// increment index for next reply
		indexReplies += 1;
	}
}

    Contract ABI  
[{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"lastThreads","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"amount","type":"uint256"}],"name":"withdraw","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"_feeNewThread","type":"uint256"},{"name":"_feeReplyThread","type":"uint256"}],"name":"SetFees","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[],"name":"feeNewThread","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"replies","outputs":[{"name":"text","type":"string"},{"name":"imageUrl","type":"string"},{"name":"replyTo","type":"uint256"},{"name":"nextReply","type":"uint256"},{"name":"timestamp","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_replyTo","type":"uint256"},{"name":"_text","type":"string"},{"name":"_imageUrl","type":"string"}],"name":"replyThread","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"feeReplyThread","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"indexReplies","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[],"name":"indexLastThreads","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"_text","type":"string"},{"name":"_imageUrl","type":"string"}],"name":"createThread","outputs":[],"payable":true,"stateMutability":"payable","type":"function"},{"constant":true,"inputs":[],"name":"indexThreads","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"","type":"uint256"}],"name":"threads","outputs":[{"name":"text","type":"string"},{"name":"imageUrl","type":"string"},{"name":"indexLastReply","type":"uint256"},{"name":"indexFirstReply","type":"uint256"},{"name":"timestamp","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"inputs":[{"name":"_feeNewThread","type":"uint256"},{"name":"_feeReplyThread","type":"uint256"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":false,"name":"threadId","type":"uint256"},{"indexed":false,"name":"text","type":"string"},{"indexed":false,"name":"imageUrl","type":"string"},{"indexed":false,"name":"timestamp","type":"uint256"}],"name":"newThreadEvent","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"replyId","type":"uint256"},{"indexed":false,"name":"replyTo","type":"uint256"},{"indexed":false,"name":"text","type":"string"},{"indexed":false,"name":"imageUrl","type":"string"},{"indexed":false,"name":"timestamp","type":"uint256"}],"name":"newReplyEvent","type":"event"}]

  Contract Creation Code Switch To Opcodes View
6060604052600160045560016006556000601b55341561001e57600080fd5b604051604080610c2e83398101604052808051919060200180519150505b60008054600160a060020a03191633600160a060020a0316179055600182905560028190555b50505b610bba806100746000396000f300606060405236156100b75763ffffffff7c01000000000000000000000000000000000000000000000000000000006000350416631707599281146100bc5780632e1a7d4d146100e45780633be6e637146100fc57806358c0bde0146101175780635c7c366d1461013c5780637cdcc5141461026d5780638783d407146102fc578063c37d8a7e14610321578063c3c6e20214610346578063cb1650b41461036b578063d9a7556f146103f5578063f552b2ba1461041a575b600080fd5b34156100c757600080fd5b6100d260043561054b565b60405190815260200160405180910390f35b34156100ef57600080fd5b6100fa600435610563565b005b341561010757600080fd5b6100fa6004356024356105a7565b005b341561012257600080fd5b6100d26105de565b60405190815260200160405180910390f35b341561014757600080fd5b6101526004356105e4565b60405160408101849052606081018390526080810182905260a08082528654600260001961010060018416150201909116049082018190528190602082019060c0830190899080156101e55780601f106101ba576101008083540402835291602001916101e5565b820191906000526020600020905b8154815290600101906020018083116101c857829003601f168201915b50508381038252875460026000196101006001841615020190911604808252602090910190889080156102595780601f1061022e57610100808354040283529160200191610259565b820191906000526020600020905b81548152906001019060200180831161023c57829003601f168201915b505097505050505050505060405180910390f35b6100fa600480359060446024803590810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284378201915050505050509190803590602001908201803590602001908080601f01602080910402602001604051908101604052818152929190602084018383808284375094965061060b95505050505050565b005b341561030757600080fd5b6100d26108c7565b60405190815260200160405180910390f35b341561032c57600080fd5b6100d26108cd565b60405190815260200160405180910390f35b341561035157600080fd5b6100d26108d3565b60405190815260200160405180910390f35b6100fa60046024813581810190830135806020601f8201819004810201604051908101604052818152929190602084018383808284378201915050505050509190803590602001908201803590602001908080601f0160208091040260200160405190810160405281815292919060208401838380828437509496506108d995505050505050565b005b341561040057600080fd5b6100d2610abc565b60405190815260200160405180910390f35b341561042557600080fd5b610152600435610ac2565b60405160408101849052606081018390526080810182905260a08082528654600260001961010060018416150201909116049082018190528190602082019060c0830190899080156101e55780601f106101ba576101008083540402835291602001916101e5565b820191906000526020600020905b8154815290600101906020018083116101c857829003601f168201915b50508381038252875460026000196101006001841615020190911604808252602090910190889080156102595780601f1061022e57610100808354040283529160200191610259565b820191906000526020600020905b81548152906001019060200180831161023c57829003601f168201915b505097505050505050505060405180910390f35b6007816014811061055857fe5b0160005b5054905081565b60005473ffffffffffffffffffffffffffffffffffffffff1681156108fc0282604051600060405180830381858888f1935050505015156105a357600080fd5b5b50565b6000543373ffffffffffffffffffffffffffffffffffffffff9081169116146105cf57600080fd5b600182905560028190555b5050565b60015481565b60056020526000908152604090206002810154600382015460048301546001840192919085565b60025460009034101561061d57600080fd5b6004548410801561062e5750600084115b151561063957600080fd5b60a0604051908101604090815284825260208083018590528183018790526000606084018190524260808501526006548152600590915220815181908051610685929160200190610aee565b506020820151816001019080516106a0929160200190610aee565b5060408201518160020155606082015181600301556080820151600490910155506000848152600360208190526040909120015415156106fd5760065460008581526003602081905260409091209081018290556002015561072b565b6006546000858152600360208181526040808420600201805485526005835290842083018590559288905252555b5060005b60148160ff1610156107985783600760ff83166014811061074c57fe5b0160005b5054141561075d57610798565b8060ff166013141561078f57836007601b5460148110151561077b57fe5b0160005b5055601b5460149060019008601b555b5b60010161072f565b7f0a10376fec2af3cfd7b84cf2d443bc3479c71cc96b6523d20fc876f4cdce745160065485858542604051808681526020018581526020018060200180602001848152602001838103835286818151815260200191508051906020019080838360005b838110156108145780820151818401525b6020016107fb565b50505050905090810190601f1680156108415780820380516001836020036101000a031916815260200191505b50838103825285818151815260200191508051906020019080838360005b838110156108785780820151818401525b60200161085f565b50505050905090810190601f1680156108a55780820380516001836020036101000a031916815260200191505b5097505050505050505060405180910390a16006805460010190555b50505050565b60025481565b60065481565b601b5481565b6001543410156108e857600080fd5b60a0604051908101604090815283825260208083018490526000828401819052606084018190524260808501526004548152600390915220815181908051610934929160200190610aee565b5060208201518160010190805161094f929160200190610aee565b506040820151816002015560608201518160030155608082015160049182015554601b549091506007906014811061098357fe5b0160005b5055601b5460149060019008601b556004547f19aec6a975c3906841d0bc9754286c99d208604b3e71f08a017e331f45b9a31390838342604051808581526020018060200180602001848152602001838103835286818151815260200191508051906020019080838360005b83811015610a0c5780820151818401525b6020016109f3565b50505050905090810190601f168015610a395780820380516001836020036101000a031916815260200191505b50838103825285818151815260200191508051906020019080838360005b83811015610a705780820151818401525b602001610a57565b50505050905090810190601f168015610a9d5780820380516001836020036101000a031916815260200191505b50965050505050505060405180910390a16004805460010190555b5050565b60045481565b600360208190526000918252604090912060028101549181015460048201549192600184019290919085565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10610b2f57805160ff1916838001178555610b5c565b82800160010185558215610b5c579182015b82811115610b5c578251825591602001919060010190610b41565b5b50610b69929150610b6d565b5090565b610b8b91905b80821115610b695760008155600101610b73565b5090565b905600a165627a7a7230582034bfc0bbf8f654cce801143e7a31d2011e6c4b208cd5f35577cd15e2f7e5dd680029000000000000000000000000000000000000000000000000000e35fa931a000000000000000000000000000000000000000000000000000000038d7ea4c68000

    Constructor Arguments (ABI-Encoded and is the last bytes of the Contract Creation Code above)
000000000000000000000000000000000000000000000000000e35fa931a000000000000000000000000000000000000000000000000000000038d7ea4c68000

-----Encoded View---------------
2 Constructor Arguments found :
Arg [0] : 000000000000000000000000000000000000000000000000000e35fa931a0000
Arg [1] : 00000000000000000000000000000000000000000000000000038d7ea4c68000


   Swarm Source:
bzzr://34bfc0bbf8f654cce801143e7a31d2011e6c4b208cd5f35577cd15e2f7e5dd68

 

View All
Block Age transaction Difficulty GasUsed Reward
View All
Block Age UncleNumber Difficulty GasUsed Reward
Make sure to use the "Vote Down" button for any spammy posts, and the "Vote Up" for interesting conversations.