line

Add to any feed reader

Suhosin 0.9.21 - XSS Protection

It has been a very long time since the last Suhosin extension has been released, but today this has changed with the release of Suhosin 0.9.21. Among the changes are two new features that will protect applications that put too much trust into the SERVER variables from several XSS (and SQL injection) attacks. These features are suhosin.server.strip and suhosin.server.encode.

suhosin.server.strip (more…)

MySQL syntax error… Help!! :( (1 reply)

Hi all,

I’ve encounterd this error message when i want to create tables in a database called ‘alan1′. ( You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘ ‘ at line 1. I’ve read through the MySQL reference manual but i don’t have any idea where it gone wrong in the opening of the php tags. I’ll be grateful for your reply. Thanks.

<?

// indicate the database you want to use

$db_name = "alan1";

(more…)

syntax error (no replies)

Ok, i am kind of new to php and mysql. I am getting this error for quite a while now. I am assigning some value to a variable $query to preform a query:

$query = "SELECT * FROM subjects WHERE id=$subject_id";

//$query .= " LIMIT 1";

$subject_id holds a int value, however i am getting this error:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘’ at line 1

I leave LIMIT 1 comment off, if (more…)

End Query with \G instead of ;

You can use \G instead of ; for tables with lots of fields.

mysql> SHOW STATUS LIKE ‘Qcache%’;
+————————-+———–+
| Variable_name | Value |
+————————-+———–+
| Qcache_queries_in_cache | 6990 |
| Qcache_inserts | 6990 |
| Qcache_hits | 3987 |
| Qcache_lowmem_prunes | 0 |
| Qcache_not_cached | 621 |
| Qcache_free_memory | 176329432 |
| Qcache_free_blocks | 1 (more…)

Find All Elements By Class

A function that returns an array of elements based on DOM element, tag, and class name. For instance, getElementsByClassName(document, ‘tr’, ‘info’) will return an array of all “tr” tags under the document node having the “info” class. (more…)

Next Page »