Mike
Members-
Content Count
175 -
Joined
-
Last visited
About Mike
-
Rank
Owner of Sub-Zero
- Birthday 11/14/1990
Contact Methods
-
Website URL
http://subzero.trap17.com
-
Just About Completed My Own Message Board Source. This one looks nice
Mike replied to Mike's topic in Programming
lol, thanks man. I think when I re-code some of the files and fix everything up after I finish the whole thing, I'll put it up for download on sourceforge.net. -
Just About Completed My Own Message Board Source. This one looks nice
Mike replied to Mike's topic in Programming
There is a selection of themes.. And thank you very much for registering! Since you are registered, you can make a custom theme or switch to a different premade theme (there are only 3 ._.). http://forums.xisto.com/no_longer_exists/ Also, we encourage you to refer new users. You will be rewarded by using your referral link! Just send people this link and edit the bolded part and you will gain Crystal ( the currency ) and increase your referral count: http://forums.xisto.com/no_longer_exists/=YOUR USER ID -
Like OpaQue said, you would use the substr() function. The only thing that I am not sure about in what OpaQue posted, is the $variable{n}. Unless that is another way to use the substr function, quickly of course. Basically the substr() function works like substr($variable, nlettertostartat); <?php$string = 'Testing';$substr = substr($string,3);echo $substr; // Result: 'ting'?> Actually, if you want to just get a certain character/characters, do what OpaQue said. $variable{n characetr [1,2,3,4,etc]}.
-
Well, on my site I use XHTML, CSS, PHP, and some JavaScript. JavaScript is for the little counter thingies that make it go '10 [1 second later] 9 [1 second later] 8' etc. PHP is the base of the site because that is my best programming language. I use it to add new features to my web site, and I am coding my own message boards source code using PHP. XHTML and CSS are what the pages run on, CSS makes the pages look beautiful, and XHTML is just cleaner. It's always nice to have an XHTML and CSS valid web site!
-
Alright, so I'm 14 and I don't have much money. My mother refused to purchase me anything else, so I'm stuck in a hole. I need money to pay for my domain (subzer0.net) and I plan on buying a new domain because I am currently working on a message board source code that I want to host there. With this domain, I want some Bihira hosting. The total yearly cost would be 39 dollars, which isn't that much, however I don't have any money in my PayPal account. How can I make some money fast?
-
Php Login Script Removing the login field once the user logs in
Mike replied to fffanatics's topic in Programming
Why not just use cookies to keep your users logged in? It's a lot easier using sessions, in my opinion. All you would have to do is add a new variable to the config file that is something like this: $username = (isset($_COOKIE['user']) ? $_COOKIE['user'] : Guest); login.php <?php# Include all the needed filesif (isset($_POST['login'])) { $uname = $_POST['username']; $pword = $_POST['password']; $check = mysql_query("SELECT username FROM users WHERE username='$uname' AND password='$pword'") or die(mysql_error()); if (mysql_num_rows($check) == 0) { echo 'Invalid username or password'; exit; } else { setcookie('user', $uname, time()+999999); setcookie('pword', $pword, time()+999999); echo 'You have successfully logged in! Return to the <a href="/">index</a>.'; }} else { echo ''; }?> -
Are the people on your site posting things that makes them have to post the date of the their post. If so you could just add this to the post page: $time = date(); And you would insert '$time' into the date field instead of what the user would type, like '{$_POST['date']}'. Then where you would fetch the dates from the database to show them to everyone else, you would put this code: $query = mysql_query("SELECT date FROM db") or die(mysql_error());$fetch = mysql_fetch_row($query);$gotit = $fetch[0];$date = date('m-d-y g:i:s',$gotit);
-
Create a function named censor with the parameter string. Below you will find the function and an example. function censor($string) {$banned_words = array();$banned_words[] = 'BANNED WORD';$banned_words[] = 'BANNED WORD';$banned_words[] = 'BANNED WORD';foreach ($banned_words AS $banned_word) {str_replace('$banned_word','-censored-',$string);}} --Example-- $message = 'What the *BANNED WORD* is your problem?!';$message = censor($message); --New Message-- 'What the -censored- is your problem?!'
-
That would be kinda strange, why would somebody pay for something to download off of the Internet? I could probably make a script using PHP and MySQL, except I'm feeling pretty lazy right about now. >_>; Just make something involving users with tables holding the downloads and stuff. Then make a field named 'purchased' and make it insert the peoples usernames as they buy it. Then put something like: $purchased = mysql_query("SELECT purchased FROM items WHERE itemid='{$_GET['itemid']}'") or die(mysql_error());$purchasedby = explode('|',$purchased);if (in_array('$username',$purchasedby)) { $file = '/home/[b]CPANELUSERNAME[/b]/public_html/[b]FILENAME[/b].[b]FILEEXTENSION[/b]'; header('Content-Description: File Transfer'); header('Content-Type: application/force-download'); header('Content-Length: ' . filesize($file)); header('Content-Disposition: attachment; filename=' . basename($file)); } else { echo 'You must purchase this item before downloading!'; exit; }?> >_______>
-
Interesting... All this stuff makes my head explode! Anyways, I like the window.print() function the best with JavaScript because it's so simple and you basically cannot forget it. But are you sure that you add the semi-colon ( at the end of a function in JavaScript?
-
Mike started following Any One Been Warned Beyond Me? :)any one would employ me? and Button To Print Current Web Page
-
Any One Been Warned Beyond Me? :)any one would employ me?
Mike replied to guangdian's topic in General Discussion
Hmm... Do the warnings get reviewed before your warn percent goes up? Because if they don't, then the whole system is totally bogus. Anyways, I feel bad for you man. If I had any money, I'd hire you for your CMS skills and I'd pay you for each file you created. But sadly I'm broke and cannot help you out. :-( Meh, just try to get by with what you have. -
There are a couple ways that you can re-direct a page to another page using PHP. Both ways, however, would be done by using the header() function at the top of your page before the HTML's <head> tag. Like the above posters said, you could use header('Location: $URL');. However, I do not use that way. The way I use the header() function allows you to control how much time until the page refreshes and where it refreshes to. Here is my way: <?phpheader('Refresh: NUMSECONDSTILREFRESH; url=URLOFPAGETOREDIRECTTO');?> Then you would continue with the rest of the page. Obviously you'd edit the NUMSECONDSTILREFRESH and URLOFPAGETOREDIRECTTO thingers.
-
Or you could simply add an extra field to the code used to produce the submit button. Your submit button is probably <input type="submit" name="blah" value="Blah" />, but you can add an extra field that makes it so the user could click ALT then another letter or number to get it to work. For example: <input type="submit" name="blah" value="blah" accesskey="r" /> would make it so if the user pressed down on ALT + 4, the button would b e clicked.
-
^ That's a nice script right there! You could also use PHP to make sure it is all numbers, but I'm not really sure how... It would probably be something like this though: <?php$zipcode = $_POST['zipcode'];if(!preg_match([0-9],$zipcode)){echo '<b>Your zip code is only numbers!</b>';exit;}if(strlen($zipcode) > 6 || strlen($zipcode) < 6){echo '<b>Your zip code is 6 characters long!</b>';exit;}?>