sunslayer

sunslayer

Joined
Oct 14, 2008

Activity Stream

sunslayer commented on a Page, Convert Height and Weight  -  Oct 08, 2012
Math.round(w*0.453*10)/10

the 10's will cancel out, and 5/11 is the inverse of 2.2

Math.round(w*(5/11))

will return a more precise answer

 Respond  
sunslayer   -  Sep 10, 2012

@Hawkee The link on the homepage to my script is broken, after messing around a bit i got http://www.hawkee.com/shop/prod/29274880/ to work

sunslayer commented on a PHP Script, MVC Framework  -  Sep 08, 2012

@Hawkee i made an example in MVC.zip but this is designed to require multiple files in different directories that would be difficult to demonstrate clearly in a couple of code tags

 Respond  
sunslayer created a PHP Script  -  Sep 07, 2012
sunslayer commented on a Page, calculator   -  Sep 06, 2012

@alimak96 > added [ ($3 == +) || ($3 == -) || ($3 == ) || ($3 == /) ] in ( if )
if the person didnt use on of these it will send a notice to him
You Can Only Use Numbers And ( +,-,
,/ )That's what I was talking about

 Respond  
sunslayer commented on a Page, calculator   -  Sep 06, 2012

There should be some sort of validation on $3 making sure its an operator

 Respond  
sunslayer commented on a Page, Pastebin Uploader  -  Aug 31, 2012

nice job, but you could use a binvar to increase the size limit of the uploads

 Respond  
sunslayer commented on a Page, Calendar Class  -  Aug 21, 2012

nice job. but you could simplify your code farther by using cal_days_in_month() to fill an array like this

function Calendar($month, $year)
{   
    $offSet = date("w",mktime(0, 0, 0, $month, 1, $year));

    for($i = 0; $i < $offSet; $i++)
        $cal[] = "";

    for($i = count($cal), $x = 1; $i < cal_days_in_month(CAL_GREGORIAN, $month, $year) + $offSet; $i++, $x++)
        $cal[] = $x;
}

then printing the calendar would just be a matter of creating a new table row after every 7 days

note that this method assumes Sunday to be the first day of the week

 Respond  
sunslayer commented on a Page, ASCII Battleship v0.2  -  Apr 10, 2012

@Spoof i sincerely hope you are kidding.

 Respond  
sunslayer commented on a Page, ASCII Battleship v0.2  -  Apr 09, 2012

Shouldn't it be called " v1.0 " seeing how 1.0 = 1 ? hmmmlol, dyslexic moment?

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 09, 2012

@Hawkee thanks that worked

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 09, 2012

@Hawkee the web hosting i'm using for the example add's them automatically probably as a security feature but it should run normally on other hosts

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 08, 2012

added the ability to delete your own comments and pastes, as well as added an admin functionality to delete other's. and replaced the geshi syntax highlighter with Google's Code Prettify that will automatically detect the language.

to upgrade open your mysql editor in the database for this file and type

ALTER TABLE users ADD COLUMN admin TINYINT(1) NOT NULL DEFAULT 0 AFTER email;
UPDATE users SET admin = 1 WHERE username = 'YOUR_USERNAME_HERE' LIMIT 1

to give yourself admin privileges

 Respond  
sunslayer commented on a Page, CSS treeview  -  Apr 06, 2012

I'm not sure about what gooshie meant but for me i preferred having a max height so when you had a snippet that was very long you wouldn't have to scroll that far to get to the comments section

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 06, 2012

@DarkOneMatter sorry i keep forgetting to silence notices :/ just put

error_reporting(E_ALL ^ E_NOTICE);

back in main.php

 Respond  
sunslayer commented on a Page, CSS treeview  -  Apr 06, 2012

^ agreed about the height of the main snippet section

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 06, 2012

I've added a user and paste class that should make creating your own files much easier. simply create them and they will automatically get all of their respective information and i've moved all the required files into a directory called core.

 Respond  
sunslayer commented on a Page, CSS treeview  -  Apr 06, 2012

that would be great

 Respond  
sunslayer commented on a Page, CSS treeview  -  Apr 06, 2012

added.

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

replace account.php with myaccount.php on the link that doesnt work and i'm currently working on cleaning up the CSS and forms so it will be easier to create new pages because its pretty sloppy right now

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

@DarkOneMatter it was actually the link that was incorrect, the filename should be myaccount.php although it doesn't really matter what you name it as long as your consistent

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

hmm where was it that you were clicking?

 Respond  
sunslayer commented on a Page, CSS treeview  -  Apr 05, 2012

images located herelol :)

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

@Hawkee thanks Geshi was the first one i came across that did what i needed

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

thanks, just remove the & after the =

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

sorry, put it above "session_start();"

 Respond  
sunslayer commented on a PHP Script, PasteBin  -  Apr 05, 2012

@DarkOneMatter try logging in that should remove the error, i forgot to suppress errors before i uploaded the script. adding

error_reporting(E_ALL ^ E_NOTICE);

to the beginning of main.php should fix that.

edit: thanks for the suggestions i've been contemplating adding a control panel so it might make it in the next update

 Respond  
sunslayer created a Page  -  Apr 05, 2012

this is an example of how to make a treeview without the use of javascript.

sunslayer commented on a PHP Script, PasteBin  -  Apr 04, 2012

thanks

 Respond  
sunslayer   -  Apr 04, 2012

@Hawkee deleting comments doesn't seem to work

Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.