Felix Ker's blog

PHP - What did I learn?

Lately I touched more PHP than felixker.com. (Notice that I blog less!)

I’ll keep this entry short and simple since it’s 12am and I should be in bed by now.

Some in-built functions I found very useful.

urlencode

This is a must-use function if you’re going to use query strings ($_GET) to pass variable to another page! Remember to use urldecode when using the variable!

Example:
$string = “i have a cute & tiny dog!”
header(”Location: http://felixker.com/foo?bar=));

htmlentities

Wonderful function to use if you’ve got a page with form submission. Prevents users from playing tricks!

Example:
$str = “A ‘quote’ is <b>bold</b>”;

// Outputs: A ‘quote’ is &lt;b&gt;bold&lt;/b&gt;
echo htmlentities($str);

Conclusion

I must end this entry. I need to sleep.

There are many more functions I used, but I just cannot remember them. Most of them are functions that I cannot find built into VB.net. (Correct me if I’m wrong.)

Good night.

Category: So random!, Technology

Tagged: , , ,

Related entries:


Bookmark and Share

RSS feed | Trackback URI

2 Comments »

2007-10-13 03:16:34

[...] Felix Ker is sharing with us what he learned about php. [...]

 
Comment by Jalaj
2007-10-15 23:54:58

In PHP I like GD, mail functions and every thing that performs actions that require external components in ASP (and those too are mostly commercial and not available on free hosts)

 
Name (required)
E-mail (required - never shown publicly)
URI
Your Comment (smaller size | larger size)
You may use <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> in your comment.

MyBlogLog

Miscellaneous





web tracker