albertlee
Senior Members-
Posts
1259 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Everything posted by albertlee
-
btw, I am abit lazy to dig this out, what's the difference between AS and A level?? ps, I know A level by the way, which is kinda extended version of GCSE.
-
POST /php/blah.php HTTP/1.1\r\n Host: chensh.loxa.edu.tw\r\n User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-TW;...\r\n Accept: text/xml,application/xml,application/xhtml+xml,text/html\r\n Accept-Language: zh-tw,en-us;q=0.7,en;q=0.3\r\n Accept-Encoding: gzip,deflate\r\n Accept-Charset:...\r\n Keep-Alive:...\r\n Connection: keep-alive\r\n Referer:...\r\n Cookie: PHPSESSID=183a044cd1be3f8a471a337c3474b6d3\r\n Content-Type: multipart/form-data; boundary=...\r\n Content-Length: 299\r\n \r\n thanks for your post, Matthew, and if you dont think it's obnoxious, may I ask you what you normally learn in Computing??? for me, my school does little teaching formal Computing course, generally art, like Photoshop, 3DS MAX... but never coding, I learn Java solely myself, you know, I learn in a hard way. *sigh* Any way, as you see from the above result, can you tell me which are HTTP requests that my computer sets before connecting to the server, and which are the responses??? thanks
-
When there's a Snack Gap, C*nd*m fits :-D
-
thanks Aeternus, I wonder whether you are computer science student.... but I dont feel convinced by the above quote. Why do you "POST" request property??? thx
-
and this, "The Martin Bars Are On Me!" for the word "Martin", and "He Who Thinks Albert Lee Drinks Albert Lee." for myself.
-
yes, literally, the below does not make sense, when i put the word "Prince Charles" The Non-Sticky Sticky Prince Charles
-
alright, thx Dave so, line feed is to move to the next line, and carriage return is?? by the way, I thought HTTP headers are set by the setRequestProperty()?? plz hellp. thanx
-
more over, what are those "\r\n", "\r\n\r", ...whatever, for?? thx
-
thanks Aerternus, you are great!! btw, how did you handle the Ethereal which gives out the HTTP request output result?? When I use that software, I got plenty of packets, and I can scarcely understand them... any help?? thanks
-
any java expert please help?????
-
Progressing in Physics (book recommendations)
albertlee replied to Royston's topic in Modern and Theoretical Physics
So, what degree are you studying then? why you need to improove your calibre in physics?? -
<form action="/php/X_24_demo.php" name="DemoForm" method="POST" enctype="multipart/form-data" onsubmit="return Final_Check();"> <input type="file" name="UserFile"> <input type="hidden" name="Original"> <input type="submit" value="Send File"> </form> the above is taken partially from: http://chensh.loxa.edu.tw/php/X_24_demo.php. It is the form part of an HTML file. Since my peer has made this simple php file, I would like to make a Java program which I could POST a small file and see the output, yes, without a browser. Since I knew what's the output should look like (via a browser of course), I can know whether my program works. But, I have no success of uploading the file, since output is the same as the original one (I can indicate by looking at the html code printed out), the correct result has an output message in addition to the original one. You can try that yourself via a browser of course. below is my java program: import java.io.*; import java.net.*; public class test1{ public static void main(String[] ad){ try{ URL u = new URL("http://chensh.loxa.edu.tw/php/X_24_demo.php"); URLConnection uc = u.openConnection(); uc.setUseCaches(false); uc.setDoOutput(true); uc.setRequestProperty("Content-type", "multipart/form-data"); PrintStream ps = new PrintStream(uc.getOutputStream()); ps.print(URLEncoder.encode("file=C:\\Documents and Settings\\Albert Lee\\桌面\\JAVA\\AWT\\progressiveupdate\\mona.jpg")); /*File pic = new File("C:/Documents and Settings/Albert Lee/桌面/JAVA/AWT/progressiveupdate/mona.jpg"); FileInputStream fis = new FileInputStream(pic); for(int i=fis.read(); i!=-1; i=fis.read()) ps.write(i); */ ps.flush(); ps.close(); InputStream is = uc.getInputStream(); for(int i=is.read(); i!=-1; i=is.read()) System.out.write(i); } catch(IOException ioe){ioe.printStackTrace();} } } As you see the commented lines, you probably know that I've tried POSTing a n actually file, or the uncommented, the text message urlencoded. Does any one know what am I lacking or doing wrong???? thanks
-
alright, thanks for the introductory exp.
-
thanks Aeternus
-
thanks... last question, how do know what extension is used for php under the terminal???
-
Sorry, I am not familar with php, but does any one give a shortcut distinction between these two??? because I am designing a server side communication program....
-
alright, you have said it is a porn site, so I am not going to click it. :-D Any way, it is coincidence that links to porn, but that does not matter as long as you dont click it. Does that make you very constrained from clicking it???? Just focus on my questions,please. thank you.
-
thaks Klaynos, yes, the server supports pHp. The server is Apache. However, I still have the same problem on another free webhosting supporting pHp. Does the server check the content of the pHp rather than its file extension?? I just typed a few characters which are non-related to pHp, but in pHp document, and I can see the content via a browser after I uploaded it. Secondly, why is cpanel a security risk?? Thirdly, my webhosting support SSL and SSH. How can they restrain hackers from obtaining data during transaction? saying the data is encrypted is too vague. thanks alot ps, xxx means something something something.
-
I have just bought a very good hosting which I could access via ftp and ssh. However, this is my first time experience, so I need some help. 1) when log in via ssh client program, I got this: bash$ what does that mean? 2) how do I configure a .htaccess?? 3) I have designed a little php file, but the bad thing is, I can actually see the content of it. eg, http://www.xxx.com/xxx.php. Why? Beside, I feel sick using terminal instead of something easier like cpanel. Does any one know a quick short guide to understand all this kinda stuff?? thanks
-
Hey, weird,,,,, after I restarted my laptop, the external drive is accessable again by Windows..... still, the partitionmagic can detect lots of errors as mentioned above... is there a reason?
-
Hi all, My external harddrive cannot be opened from "My Computer" any more... A popup window saying that the partition is not yet partitioned, which isn't apearing before.... I have run a check on it using Partition Magic 7.0 trial, and indeed there are errors... The errors are: 1) plenty of "File Record Mark used" 2) 1 "Internal File number does not match" 3) 1 "crossed linked files were found" 4) 1 "Error: %d" note: the error listed may have spelling error. However, since the soft is a trial, I cannot run "fix", so..... does any one know the fastest way for me to retrieve my files?? I think it is still a great chance since Partition Magic can still identify it as NTFS with number of volumes used, unlike Windows. Please help.. thanks
-
Java rules!!!!!!!!!!!!!!!!!!!!!!!!!!!
-
be familar with an OS, learn scripting language(like pHp, javascript), programming language(like Java), the nuts&bolts of network, assembly language....... after all, if you can master the above, you are a "computer" hacker. and lastly, go and learn electronics and you will be the ultimate hacker I guess.
-
hmm.. you mean they just compel you to pay compensation before any notice of your act that they consider illegal??
-
ok, After seeing the BT spec, it looks to me it is not all that hard to set up a BT tracker... so, if I have a tracker, and which in most context is misused, and the authority is upset about that, will they notice me first?? or just send people to catch me??