Skip to content

Instantly share code, notes, and snippets.

@julianwachholz
Last active December 15, 2015 23:59
Show Gist options
  • Save julianwachholz/5343871 to your computer and use it in GitHub Desktop.
Save julianwachholz/5343871 to your computer and use it in GitHub Desktop.
<?php
$SQL = "INSERT INTO `productgroups` ";
$SQL .= "( ";
$SQL .= "`xmlid`,";
$SQL .= "`lang`,";
$SQL .= "`title`";
$SQL .= ") ";
$SQL .= "VALUES ( ";
$SQL .= "'".mysql_real_escape_string($_POST['group']['xmlid'])."', ";
$SQL .= "'".mysql_real_escape_string($_POST['group']['lang'])."', ";
$SQL .= "'".mysql_real_escape_string($_POST['group']['title'])."'";
$SQL .= ");";
mysql_query($SQL);
$group_id = mysql_insert_id();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment