-
Posts
783 -
Joined
-
Last visited
Everything posted by ZulfadlyAshBurn
-
HAHA. No Prob. Thanks alot. It work great
-
use php session and store the username variable. then on the user comment, get the username session. you should really learn some basics of php...
-
how is that suppose to put the new data at the top of the file?
-
My code works but i need it to do something. the script add the data at the end of the document. what i would like is that, i want it to write at the top of the document without overwrite the actual document. <?php $text = $_GET['text']; $act = $_GET['do']; if ($act == "rst") { $fp = fopen('log.txt', 'w+'); fwrite($fp, ''); fclose($fp); } else { if ($act == "sub") { $text = "<img src='images/say.png' height='20px'/><a href='#'>ZulfadlyAshBurn</a> " . $text . "<p style='float:right; color:#C0C0C0' align='right'><img ALIGN=ABSMIDDLE src='images/clock.png' height='20px'> " . date("d/m/y : H:i:s", time()) . "</img></p><hr color='#F0F0F0' width='100%' size='1'/>"; $fp = fopen('log.txt', 'a+'); fwrite($fp, $text); fclose($fp); readfile('log.txt'); } else { if ($act == "setp") { $text = "<img src='images/set.png' height='20px'/><a href='#'>ZulfadlyAshBurn</a> " . $text. "<hr color='#F0F0F0' width='100%' size='1'/>"; $fp = fopen('log.txt', 'a+'); fwrite($fp, $text); fclose($fp); readfile('log.txt'); } else { echo "<title>Unauthorised</title>You are not authorised to view this page! Please leave."; } } } ?>
-
Why don't you just do redirection? Load Ads → User Click Ads [/size]→ Redirect to download links page. Use $_SESSION[]; for your username and stuffs.
-
For the side to side div, i have fixed it right. so its working properly. this is my script index.php <html> <head> <title>Anderson Infocomm Portal | Home</title> <meta name="description" content="Anderson Infocoom Club Portal where event & duties updates are posted and members contirbution points to the club." /> <meta name="keywords" content="Anderson, Secondary, School, Infocomm, Club, Andss, Portal, Social, Interactive" /> <meta name="author" content="ZulfadlyAshBurn" /> <meta name="generator" content="ZulfadlyAshBurn Codes" /> <link href="styles/reset.css" rel="stylesheet" type="text/css" /> <link href="styles/main.css" rel="stylesheet" type="text/css" /> </head> <body> <div class="top"><img src="images/logo.png" alt="logo"/><div style="background-color: #707070; height: 2px"><><> <div class="main"> <div class="sidebar"> <h1 align="center"> Hello<br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br> </h1> <> <div class="content"> Hello <> <> main.css body { background-color: #E0E0E0; } .top { position: fixed; top: 0px; height: 40px; width: 100%; background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0.82, rgb(248,248,248)), color-stop(0, rgb(232,232,232)) ); background-image: -moz-linear-gradient( center bottom, rgb(248,248,248) 82%, rgb(232,232,232) 0% ); } .main { width: 100%; height: 100%; } .sidebar, .content { top: 50px; float:left; position:relative; } .main .sidebar { width: 20%; border-style:solid; border-right-color: #A0A0A0; border-right-width: 1; } .main .content { width: 80%; } thhe problem i am having know, when i structure my top div to be at the top of the body section, when other elements are below the div, the content in that element will be over the top div when i scroll down.
-
somehow the page looks kinda weird. please see the attachment. im trying to achieve something like the orig one.. [attachment deleted by admin]
-
sorry for not posting the code. here you go. absolute position is position relatively to the parent div. index.php <body> <div class="top"> <ul id="nav"> <li><img src="images/logo.png"/></li><br><li class="moveBar"> </li> <li><a id="current" href="index.php">Home</a> </li> <li><a href="inbox.php">Inbox</a> </li> <li><a href="notification.php">Notification</a> </li> <li><a href="logout.php">Logout</a> </li> </ul> </div> <div class="clear"></div> <div class="main"> <div class="sidebar" align="center"> <p align="center"><?php echo $rank; ?></p> <hr color="#C0C0C0"> <img src="images/male_silhouette.png"/> <br><br> <p>Name: <?php echo $user; ?></p> <p>Contact: <?php echo $contact; ?></p> </div> </div> <div class="credits" align="right"> Created by Zulfadly AshBurn. All Rights Reserved!<div class="clear"/> </div> <body> main.css body { background-color: #E0E0E0 ; } .main { height: auto; width: 100%; background-color: #F8F8F8; padding-bottom: 10px; } div.top { position:fixed; height: 40px; width: 100%; border-style: solid; font-size: 16; border-bottom-color: #585858; border-bottom-width: 1px; background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0, rgb(240,240,240)), color-stop(0.74, rgb(255,255,255)) ); background-image: -moz-linear-gradient( center bottom, rgb(240,240,240) 0%, rgb(255,255,255) 74% ); } div.top li { float:left; color: #E0E0E0; } div.top a { color: #D0D0D0; text-decoration:none; padding: 2px; -moz-border-radius: 2px; border-radius: 5px; border-style: none; border-width: 1px; } div.top a:hover { color: #000000; padding: 2px; } #nav #current{ color: #000000; padding: 2px; -moz-border-radius: 2px; border-radius: 5px; border-style: solid; border-width: 1px; border-color: #C0C0C0; background-color: #C0C0C0; } .sidebar { width: 200px; height: 500px; -moz-box-shadow: 10px 10px 5px #E0E0E0 ; -webkit-box-shadow: 10px 10px 5px #E0E0E0 ; box-shadow: 10px 10px 5px #E0E0E0 ; background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0.09, rgb(248,248,248)), color-stop(0.4, rgb(243,243,243)) ); background-image: -moz-linear-gradient( center bottom, rgb(248,248,248) 9%, rgb(243,243,243) 40% ); } .credits { height: auto; background-image: -webkit-gradient( linear, left bottom, left top, color-stop(0.4, rgb(240,240,240)), color-stop(0.51, rgb(248,248,248)) ); background-image: -moz-linear-gradient( center bottom, rgb(240,240,240) 40%, rgb(248,248,248) 51% ); } .clear { height: 4px; } .moveBar { width: 90px; }
-
Im currently coding a social site for my cca. i want the div element to be side by side and one is fixed position another is absolute. When im using a higher res screen, the div is in diff place.
-
sorry, wrong forum.
-
Im currently coding a social site for my cca. i want the div element to be side by side and one is fixed position another is absolute. When im using a higher res screen, the div is in diff place.
-
I tried the forgot my password function and i was able to key in any data in it and i will still show this, maybe you want to fix that: Register Account[/size]Your password has been reset. Please check your email to retrieve your new password. Then you may login.Once you've logged in, please change your password.[/color]© 2011 optimuspi ( ! )[/size] Warning: mail() [function.mail]: SMTP server response: 550 Unknown user in C:\ROOT\wamp\www\IsleWar\forgotpassword-exec.php on line 67Call Stack#TimeMemoryFunctionLocation10.0012690720{main}( )..\forgotpassword-exec.php:020.0108709208mail ( )..\forgotpassword-exec.php:67
-
no prob. good luck. if you've got any prob, you can always come back here. but post it at the right forum section though
-
you can actually use ajax if you want.
-
maybe this might work? <script> function demote(){ <?php $userprofile=$_GET['user']; mysql_query("UPDATE users SET adlevel=adlevel-1 WHERE username='$userprofile'"); ?> } </script> <body><input type='button' value='Demote' onclick='demote()'/></body>
-
i never tried it before. if you know abt it, tell me
-
I am creating a interaction site for my cca and in on page there are too much lines of codes. It has too much Querying with MySQL Database and taking a long time too load. I have tried ajax but it still takes time to load too. Anyone have any idea to speed up the site?
-
how to make my database refresh in demo mode
ZulfadlyAshBurn replied to phpmady's topic in PHP Coding Help
user cron job to run the script which reset your database. -
In the authentication page, you should add this script <?php if (isset($_POST['ref'])) { $ref = $_POST['ref']; $query = mysql_query("UPDATE `table` SET `credit` = `credit` + 10 WHERE `ref` = '$ref'"); if (mysql_num_rows($query) !== false ) { echo "Thanks for registering. You were referred by" . $ref . ". He will be given 10 credits for it. Be a referral."; } else { echo "Thanks for registering!" } }
-
You should automatically add the points after the user have done registering. <input type="hidden" name="ref" value="<?php echo $_GET['ref']; ?>" />
-
Are you using cron jobs or something?
-
Bob Norris, are you trying to create a lightbox? Lightbox are easy to make. If that is wad you want, google it. It have a lot of tutorials abt it.
-
want to show a message on the same (form) page.
ZulfadlyAshBurn replied to nadeem14375's topic in PHP Coding Help
You may want to use ajax for you site? I used ajax for my site to check for the data -
Script to Read Contents of Website
ZulfadlyAshBurn replied to quantumdecipher's topic in PHP Coding Help
You might want to try learning ajax. Although sometimes, ajax might not be safe.